From a3fc9a4e0560591e6b3fa9da921544fc2bf09677 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 7 May 2024 02:55:02 +0000 Subject: [PATCH 1/2] feat: add `CreateReportTask`, `QueryReportTask`, `GetReportTask`, `ListReportTasks` methods to the Data API v1alpha feat: add `ReportTask`, `Metric`, `OrderBy`, `Cohort`, `CohortsRange`, `CohortReportSettings`, `ResponseMetaData`, `MetricAggregation`, `RestrictedMetricType` types to the Data API v1alpha PiperOrigin-RevId: 631240474 Source-Link: https://github.com/googleapis/googleapis/commit/2df3336aee75aae207bfc60281dee2916021a0e4 Source-Link: https://github.com/googleapis/googleapis-gen/commit/4dee394d2c20b69a7b0177e83548992d70bf2d73 Copy-Tag: eyJwIjoiQW5hbHl0aWNzRGF0YS8uT3dsQm90LnlhbWwiLCJoIjoiNGRlZTM5NGQyYzIwYjY5YTdiMDE3N2U4MzU0ODk5MmQ3MGJmMmQ3MyJ9 --- .../Data/V1Alpha/AnalyticsDataApi.php | Bin 0 -> 11945 bytes .../Google/Analytics/Data/V1Alpha/Data.php | Bin 0 -> 15349 bytes .../Data/V1alpha/AudienceDimension.php | 76 + .../Data/V1alpha/AudienceDimensionValue.php | 75 + .../Analytics/Data/V1alpha/AudienceList.php | 621 +++++++ .../Data/V1alpha/AudienceList/State.php | 75 + .../Data/V1alpha/AudienceListMetadata.php | 33 + .../Analytics/Data/V1alpha/AudienceRow.php | 71 + .../Analytics/Data/V1alpha/BetweenFilter.php | 121 ++ .../Google/Analytics/Data/V1alpha/Cohort.php | 215 +++ .../Data/V1alpha/CohortReportSettings.php | 71 + .../Analytics/Data/V1alpha/CohortSpec.php | 179 ++ .../Analytics/Data/V1alpha/CohortsRange.php | 208 +++ .../Data/V1alpha/CohortsRange/Granularity.php | 76 + .../V1alpha/CreateAudienceListRequest.php | 132 ++ .../CreateRecurringAudienceListRequest.php | 132 ++ .../Data/V1alpha/CreateReportTaskRequest.php | 132 ++ .../Analytics/Data/V1alpha/DateRange.php | 172 ++ .../Analytics/Data/V1alpha/Dimension.php | 189 +++ .../Data/V1alpha/DimensionExpression.php | 147 ++ .../DimensionExpression/CaseExpression.php | 74 + .../ConcatenateExpression.php | 128 ++ .../Data/V1alpha/DimensionHeader.php | 70 + .../Analytics/Data/V1alpha/DimensionValue.php | 75 + .../Data/V1alpha/EventCriteriaScoping.php | 56 + .../Data/V1alpha/EventExclusionDuration.php | 56 + .../Analytics/Data/V1alpha/EventSegment.php | 123 ++ .../V1alpha/EventSegmentConditionGroup.php | 128 ++ .../Data/V1alpha/EventSegmentCriteria.php | 72 + .../Data/V1alpha/EventSegmentExclusion.php | 123 ++ .../Google/Analytics/Data/V1alpha/Filter.php | 212 +++ .../Data/V1alpha/FilterExpression.php | 178 ++ .../Data/V1alpha/FilterExpressionList.php | 67 + .../Google/Analytics/Data/V1alpha/Funnel.php | 115 ++ .../Data/V1alpha/FunnelBreakdown.php | 137 ++ .../Data/V1alpha/FunnelEventFilter.php | 140 ++ .../Data/V1alpha/FunnelFieldFilter.php | 208 +++ .../Data/V1alpha/FunnelFilterExpression.php | 216 +++ .../V1alpha/FunnelFilterExpressionList.php | 67 + .../Data/V1alpha/FunnelNextAction.php | 154 ++ .../Data/V1alpha/FunnelParameterFilter.php | 291 ++++ .../FunnelParameterFilterExpression.php | 180 ++ .../FunnelParameterFilterExpressionList.php | 67 + .../Data/V1alpha/FunnelResponseMetadata.php | 92 + .../Analytics/Data/V1alpha/FunnelStep.php | 243 +++ .../Data/V1alpha/FunnelSubReport.php | 196 +++ .../Data/V1alpha/GetAudienceListRequest.php | 86 + .../GetRecurringAudienceListRequest.php | 92 + .../Data/V1alpha/GetReportTaskRequest.php | 86 + .../Analytics/Data/V1alpha/InListFilter.php | 105 ++ .../Data/V1alpha/ListAudienceListsRequest.php | 178 ++ .../V1alpha/ListAudienceListsResponse.php | 115 ++ .../ListRecurringAudienceListsRequest.php | 186 +++ .../ListRecurringAudienceListsResponse.php | 115 ++ .../Data/V1alpha/ListReportTasksRequest.php | 158 ++ .../Data/V1alpha/ListReportTasksResponse.php | 115 ++ .../Google/Analytics/Data/V1alpha/Metric.php | 221 +++ .../Data/V1alpha/MetricAggregation.php | 75 + .../Analytics/Data/V1alpha/MetricHeader.php | 104 ++ .../Analytics/Data/V1alpha/MetricType.php | 131 ++ .../Analytics/Data/V1alpha/MetricValue.php | 75 + .../Analytics/Data/V1alpha/NumericFilter.php | 111 ++ .../Data/V1alpha/NumericFilter/Operation.php | 85 + .../Analytics/Data/V1alpha/NumericValue.php | 108 ++ .../Google/Analytics/Data/V1alpha/OrderBy.php | 144 ++ .../Data/V1alpha/OrderBy/DimensionOrderBy.php | 104 ++ .../OrderBy/DimensionOrderBy/OrderType.php | 76 + .../Data/V1alpha/OrderBy/MetricOrderBy.php | 70 + .../Analytics/Data/V1alpha/PropertyQuota.php | 363 ++++ .../Data/V1alpha/QueryAudienceListRequest.php | 205 +++ .../V1alpha/QueryAudienceListResponse.php | 191 +++ .../Data/V1alpha/QueryReportTaskRequest.php | 225 +++ .../Data/V1alpha/QueryReportTaskResponse.php | 323 ++++ .../Analytics/Data/V1alpha/QuotaStatus.php | 101 ++ .../Data/V1alpha/RecurringAudienceList.php | 410 +++++ .../Analytics/Data/V1alpha/ReportTask.php | 183 ++ .../V1alpha/ReportTask/ReportDefinition.php | 614 +++++++ .../V1alpha/ReportTask/ReportMetadata.php | 374 +++++ .../ReportTask/ReportMetadata/State.php | 72 + .../Data/V1alpha/ReportTaskMetadata.php | 34 + .../Data/V1alpha/ResponseMetaData.php | 407 +++++ .../SchemaRestrictionResponse.php | 84 + .../ActiveMetricRestriction.php | 114 ++ .../Data/V1alpha/RestrictedMetricType.php | 62 + .../src/Google/Analytics/Data/V1alpha/Row.php | 138 ++ .../Data/V1alpha/RunFunnelReportRequest.php | 557 +++++++ .../FunnelVisualizationType.php | 67 + .../Data/V1alpha/RunFunnelReportResponse.php | 248 +++ .../Data/V1alpha/SamplingMetadata.php | 134 ++ .../Google/Analytics/Data/V1alpha/Segment.php | 198 +++ .../Data/V1alpha/SegmentEventFilter.php | 140 ++ .../Analytics/Data/V1alpha/SegmentFilter.php | 252 +++ .../Data/V1alpha/SegmentFilterExpression.php | 216 +++ .../V1alpha/SegmentFilterExpressionList.php | 67 + .../Data/V1alpha/SegmentFilterScoping.php | 118 ++ .../Data/V1alpha/SegmentParameterFilter.php | 335 ++++ .../SegmentParameterFilterExpression.php | 180 ++ .../SegmentParameterFilterExpressionList.php | 67 + .../V1alpha/SegmentParameterFilterScoping.php | 158 ++ .../Data/V1alpha/SessionCriteriaScoping.php | 64 + .../Data/V1alpha/SessionExclusionDuration.php | 64 + .../Analytics/Data/V1alpha/SessionSegment.php | 123 ++ .../V1alpha/SessionSegmentConditionGroup.php | 164 ++ .../Data/V1alpha/SessionSegmentCriteria.php | 72 + .../Data/V1alpha/SessionSegmentExclusion.php | 127 ++ .../SheetExportAudienceListRequest.php | 206 +++ .../SheetExportAudienceListResponse.php | 253 +++ .../Analytics/Data/V1alpha/StringFilter.php | 135 ++ .../Data/V1alpha/StringFilter/MatchType.php | 92 + .../Data/V1alpha/UserCriteriaScoping.php | 72 + .../Data/V1alpha/UserExclusionDuration.php | 64 + .../Analytics/Data/V1alpha/UserSegment.php | 123 ++ .../V1alpha/UserSegmentConditionGroup.php | 164 ++ .../Data/V1alpha/UserSegmentCriteria.php | 118 ++ .../Data/V1alpha/UserSegmentExclusion.php | 127 ++ .../Data/V1alpha/UserSegmentSequenceGroup.php | 202 +++ .../Data/V1alpha/UserSequenceStep.php | 198 +++ .../Data/V1alpha/WebhookNotification.php | 258 +++ .../create_audience_list.php | 119 ++ .../create_recurring_audience_list.php | 103 ++ .../create_report_task.php | 89 + .../get_audience_list.php | 83 + .../get_recurring_audience_list.php | 86 + .../get_report_task.php | 74 + .../list_audience_lists.php | 90 + .../list_recurring_audience_lists.php | 88 + .../list_report_tasks.php | 77 + .../query_audience_list.php | 88 + .../query_report_task.php | 75 + .../run_funnel_report.php | 72 + .../sheet_export_audience_list.php | 90 + .../src/V1alpha/AlphaAnalyticsDataClient.php | 36 + .../Client/AlphaAnalyticsDataClient.php | 867 ++++++++++ .../Gapic/AlphaAnalyticsDataGapicClient.php | 1477 +++++++++++++++++ .../v1alpha/src/V1alpha/gapic_metadata.json | 83 + .../alpha_analytics_data_client_config.json | 109 ++ ...alpha_analytics_data_descriptor_config.php | 228 +++ ...lpha_analytics_data_rest_client_config.php | 179 ++ .../V1alpha/AlphaAnalyticsDataClientTest.php | 1062 ++++++++++++ .../Client/AlphaAnalyticsDataClientTest.php | 1219 ++++++++++++++ .../Data/V1Beta/AnalyticsDataApi.php | Bin 0 -> 10331 bytes .../Google/Analytics/Data/V1Beta/Data.php | Bin 0 -> 8211 bytes .../Data/V1beta/AudienceDimension.php | 76 + .../Data/V1beta/AudienceDimensionValue.php | 75 + .../Analytics/Data/V1beta/AudienceExport.php | 473 ++++++ .../Data/V1beta/AudienceExport/State.php | 75 + .../Data/V1beta/AudienceExportMetadata.php | 33 + .../Analytics/Data/V1beta/AudienceRow.php | 71 + .../V1beta/BatchRunPivotReportsRequest.php | 133 ++ .../V1beta/BatchRunPivotReportsResponse.php | 109 ++ .../Data/V1beta/BatchRunReportsRequest.php | 133 ++ .../Data/V1beta/BatchRunReportsResponse.php | 109 ++ .../Data/V1beta/CheckCompatibilityRequest.php | 300 ++++ .../V1beta/CheckCompatibilityResponse.php | 101 ++ .../Google/Analytics/Data/V1beta/Cohort.php | 215 +++ .../Data/V1beta/CohortReportSettings.php | 71 + .../Analytics/Data/V1beta/CohortSpec.php | 179 ++ .../Analytics/Data/V1beta/CohortsRange.php | 208 +++ .../Data/V1beta/CohortsRange/Granularity.php | 76 + .../Analytics/Data/V1beta/Compatibility.php | 63 + .../V1beta/CreateAudienceExportRequest.php | 132 ++ .../Analytics/Data/V1beta/DateRange.php | 172 ++ .../Analytics/Data/V1beta/Dimension.php | 190 +++ .../Data/V1beta/DimensionCompatibility.php | 133 ++ .../Data/V1beta/DimensionExpression.php | 147 ++ .../DimensionExpression/CaseExpression.php | 74 + .../ConcatenateExpression.php | 128 ++ .../Analytics/Data/V1beta/DimensionHeader.php | 70 + .../Data/V1beta/DimensionMetadata.php | 261 +++ .../Analytics/Data/V1beta/DimensionValue.php | 75 + .../Google/Analytics/Data/V1beta/Filter.php | 224 +++ .../Data/V1beta/Filter/BetweenFilter.php | 124 ++ .../Data/V1beta/Filter/InListFilter.php | 108 ++ .../Data/V1beta/Filter/NumericFilter.php | 114 ++ .../V1beta/Filter/NumericFilter/Operation.php | 85 + .../Data/V1beta/Filter/StringFilter.php | 138 ++ .../V1beta/Filter/StringFilter/MatchType.php | 92 + .../Data/V1beta/FilterExpression.php | 178 ++ .../Data/V1beta/FilterExpressionList.php | 67 + .../Data/V1beta/GetAudienceExportRequest.php | 87 + .../Data/V1beta/GetMetadataRequest.php | 123 ++ .../V1beta/ListAudienceExportsRequest.php | 178 ++ .../V1beta/ListAudienceExportsResponse.php | 115 ++ .../Google/Analytics/Data/V1beta/Metadata.php | 136 ++ .../Google/Analytics/Data/V1beta/Metric.php | 221 +++ .../Data/V1beta/MetricAggregation.php | 75 + .../Data/V1beta/MetricCompatibility.php | 133 ++ .../Analytics/Data/V1beta/MetricHeader.php | 104 ++ .../Analytics/Data/V1beta/MetricMetadata.php | 395 +++++ .../V1beta/MetricMetadata/BlockedReason.php | 66 + .../Analytics/Data/V1beta/MetricType.php | 131 ++ .../Analytics/Data/V1beta/MetricValue.php | 75 + .../Analytics/Data/V1beta/MinuteRange.php | 220 +++ .../Analytics/Data/V1beta/NumericValue.php | 108 ++ .../Google/Analytics/Data/V1beta/OrderBy.php | 177 ++ .../Data/V1beta/OrderBy/DimensionOrderBy.php | 104 ++ .../OrderBy/DimensionOrderBy/OrderType.php | 76 + .../Data/V1beta/OrderBy/MetricOrderBy.php | 70 + .../Data/V1beta/OrderBy/PivotOrderBy.php | 120 ++ .../OrderBy/PivotOrderBy/PivotSelection.php | 117 ++ .../Google/Analytics/Data/V1beta/Pivot.php | 255 +++ .../Data/V1beta/PivotDimensionHeader.php | 67 + .../Analytics/Data/V1beta/PivotHeader.php | 113 ++ .../Analytics/Data/V1beta/PropertyQuota.php | 363 ++++ .../V1beta/QueryAudienceExportRequest.php | 205 +++ .../V1beta/QueryAudienceExportResponse.php | 191 +++ .../Analytics/Data/V1beta/QuotaStatus.php | 121 ++ .../Data/V1beta/ResponseMetaData.php | 457 +++++ .../SchemaRestrictionResponse.php | 84 + .../ActiveMetricRestriction.php | 114 ++ .../Data/V1beta/RestrictedMetricType.php | 62 + .../src/Google/Analytics/Data/V1beta/Row.php | 138 ++ .../Data/V1beta/RunPivotReportRequest.php | 553 ++++++ .../Data/V1beta/RunPivotReportResponse.php | 481 ++++++ .../Data/V1beta/RunRealtimeReportRequest.php | 465 ++++++ .../Data/V1beta/RunRealtimeReportResponse.php | 381 +++++ .../Data/V1beta/RunReportRequest.php | 699 ++++++++ .../Data/V1beta/RunReportResponse.php | 433 +++++ .../Data/V1beta/SamplingMetadata.php | 133 ++ .../batch_run_pivot_reports.php | 58 + .../batch_run_reports.php | 58 + .../check_compatibility.php | 66 + .../create_audience_export.php | 122 ++ .../get_audience_export.php | 83 + .../BetaAnalyticsDataClient/get_metadata.php | 90 + .../list_audience_exports.php | 91 + .../query_audience_export.php | 89 + .../run_pivot_report.php | 61 + .../run_realtime_report.php | 65 + .../BetaAnalyticsDataClient/run_report.php | 67 + .../src/V1beta/BetaAnalyticsDataClient.php | 36 + .../V1beta/Client/BetaAnalyticsDataClient.php | 749 +++++++++ .../Gapic/BetaAnalyticsDataGapicClient.php | 1431 ++++++++++++++++ .../v1beta/src/V1beta/gapic_metadata.json | 73 + .../beta_analytics_data_client_config.json | 99 ++ .../beta_analytics_data_descriptor_config.php | 180 ++ ...beta_analytics_data_rest_client_config.php | 158 ++ .../V1beta/BetaAnalyticsDataClientTest.php | 803 +++++++++ .../Client/BetaAnalyticsDataClientTest.php | 872 ++++++++++ 239 files changed, 42799 insertions(+) create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Client/AlphaAnalyticsDataClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php create mode 100644 owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimension.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Client/BetaAnalyticsDataClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php create mode 100644 owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php new file mode 100644 index 0000000000000000000000000000000000000000..fce3ba97b7179fb6a742b0c8508cc93e69987adf GIT binary patch literal 11945 zcmd5COK%&;IV(!C^ikGhtp}q#yxu%4D=uj>Z@P-R6eU}!BP)`uAcoMziX2f3QM=6U z(h3_0Xo?<+qG*Bk2eh{W4bT8R7U-csivmF}ZGj$qNf6}H^wevC0R3iWXSqu*wWOQ^ z)k)l$@0;)an)&9<`avC@QEm~7IEF_m%3f3P4v12BY|k#+HD#}{zfT;cY#-Il8ga6U zQo5_G-`!SLN^9Gf5Y)9BPMH*xs%=+mBxhJgt?8L%H&-z{BlqCCQL7&qtoBj3eUKjWSVgZ4}=koOAR)@LrmLHl>6u2&{4R31r0g3tmmrePz55NT?3uQuP=LEunJipUI8M6v z*}9DqSyBXb8&pUrpxrggBMy?fTOw}RG3%b~Y~a>Hp-Q|!wDilu75`X@&fHfPIE{ru z2a!vP=QK$8bVYH9*Kn*GjBbkHB=~Q)XW219778u?TIgbt)J;@^Wm8ewmfIiTa?K=` z*B{KPNotiMIWQiWw$mTzCh={tXYTIUR@G@(mT6UY@7AdY^v7gi0NW-Sv1c6B<0)o_ z^Nlx5-%PYhC9sNB^s0qGk5sFd;m`Nrm9x2%{1k`F25y+8?v(Z2aQ;bwwr-+J25RNL zI6oI!Ei>Ku3l~ER`&2>tp06Q)!{eb1j;{uP=^1~i){=G34rJYS0E-FeQ8`Ztly6Y~ zB7wT>5DZb9q}*^E)R@+&pm~+a9nPpNaim%)qQ3E7al~%;<4~ zQmb$wMha*osfJ_vmebP3ML1tRKxZd4-Lnsg)iNOIHkDa%7zT9&EKb6>9@(iL!o^zz zo$C~jyB)Dt-`~z6fAyCVT;jeQbDaCX@bFm}ts7OMyI2=6sc;jP=K$DuF0R0rB=t8K zg-#>Ut)q_-c?U9quA|oBqIReQo+)(5Pr`&n-uLtnaWoQ*GM_8TFsZjKtM9@rDllw^ zLXI~hdb`fzFj)=rH z@j^nl3A1+w1^fz$;(05KNGRcJ5YsI0Zzs^K&!Vs;T2}?ZV z`RjcsF}p0*-WR!2PQ0<F+hLSmu$|rQy`6l1k>B$d4&ZjiZizte5QuRw*>)v7nQ>JwOp*tR{|QJ35w=E{3Me zDD`iCQi^VP9;Puzm9fI1fs1x!HG*whCXM?fzHgB3yVAXQ8Ec^&qFcMAr`n~n7jg{rK)wPw<X?;NmB%=}r~{KVr-IF|ka47Dr%MXBJnS zg=wsQJM5)62A~IuWw|t>NtVsyR9Bpb3|3Np&Womt?j-;R>-fj@58D138 zW-1c$(E$eJ3ovZ&@4JMTv?*#pk}She%{(%_49$G}oBAonu^7aDaP0^}wE9lx`w2qA z7XvL&VY--=X}Vk#UKpgONL!N?+-};(G;aiIU>pqbDu-4#LZwXOQH`lTlHlpB146u& z_v^M3NozuYkD4=k7xxba;9^%|e4%4C;MOr@Ra{Cnt>Ad+7gXTkRkOm&J|>Ge8L{xw zp~u1g^+>}Mt3|@c)ADi(CiL((vl7(+^O=Z-)bBt#tlGOUSrHwH{=leV%jefqFZXC5 zB>}!eq19_JCGZC;w0CKp66(dMZ>X=pYzG9xB~QQ*BS|Qsn1)f?BAib3t09=(Y*?!} zY#_BwLM=>K74~+b+u*R=3yYA(UX|#MVO5b&?g$GBeBvC8Y*GM@qX5G=(ZUm%Bc$`s zC4h7CIP6<6$zk<9G_u2reQaU(NZmTy8x{e@(QSb2qhmEH?Rad9rSEh;*Av2ZEPXWw z#xXYFaUbIY({0e<9&00YuUY5Wdp!SE0^)d$WVsl2!dSNvDL-}zMqE3#MFC+_hbKti4$p>G3#?Ls%q@%7LLRPF}ejCnnhIHS{d6RKA zFK^Xuw7Y1p-Dqdwf7^r${;5W_>X0g*a${?eS{P3p1#*#UEkG{aH!!(572@c7O&4Po zRZdbEyi4~Nn;d=~hf+Ak#rbU$yO;`L4Ge2^BzYOqW%~f_7s~}wWHZ(l?&3~GLac;55AG>jq-w`b(tzF0SZzP<@p{XPL&L$A` z+Fx>?{+jwr8k~3^DJwAUAyutjghiiIn@nob;U@DEOn4Z+Y9SodP<4y9c}BGRkvZ5 zb$G2MLH46Gj(<(TTnAb|@vp&DtI|HePKG$5piinXgL3^g1H+gxe#C;mF7WV-lhlGD z_n0w!B-db&HJv=!s7Vn3o6S57Gs6=XE4{$H1S3br`{q&O$i@1XM$TTLupD4e^e&}0 zsHt!>%!W{ymq$=iEav$)E=lPJ?^W4cn_3Ds7>0TerrEWC@C{)nOOXMCZ`{2*A#K5D z>9nO~fx$re(LJZ{dGe3ZkvpjIE%zpjIlM}v!ATfx?|#_-Bsu@DIgr`w2Ti<*pt_KM zFTq4xVJ#Mk5QYfr0o)nxYhJv&x z|62l?hfC2{Q<=+26=^4k;NmI4Md-pg8(i+IA4;ES&$dsx!$(sqr^(`>HqEb+uNvX` zI^%Uoy&B?`T{uTM%?TLFj9X|8wQ7_(yv&~J7^cau3c`b&6&-SQKnRYLWEBJGYp(QA zW4FzWsaMr}izzzyh_DppD2K{?kIosX3co-{=`yU6mlBxj0w-8Ys=~U0`wYGrW^hS; ztuF=%8w9c=D4V}UPiwnOOZ2q1{erEetQ59K^+uS7tQ@kuWF^UeLQ|tQ7{=%(npy{h zAUw&`VgP+jEIrixry0!HB7AT^izwB4DlJi8|up~+l%ElfR3oD(CrP1{13c;Wmz~*97%rD4e-%q5e+ADh~rL6jb|6* ziu_Lr=BXWRiaU{rK;&;FXu3P7U@pm4PQ&0^^J>(ZUk&rxhj!)9C72YZDXJ+sDG#>; z2)+_B-|;7!5*a|nGyxAaIWXp+*=B;qVkI>)6M*>>szrr%@$)FI5Y2N>)J(LbSukIFdx#Qzw zUlYNTKBM6sv>qK_?RjUGUZ~ktt(gc?aqt~nZ@aQM?MvPox*Kzgf5693c)NePffZ*W zy#PLd#__XfZ%Fqw|7Bv;uHkJ^)^@77DzUH__v~Ej@ncIsk;mFMsJOq>Zo>0{0*uO$ zX|>B352Nqpn(|Dj$`4Balf7Yf-iw!m*R5Cio956HXnLh?mSdhjvz`2D@(G*({1=W? B(fj}a literal 0 HcmV?d00001 diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php new file mode 100644 index 0000000000000000000000000000000000000000..281b7c696ed61165745b56ae7630f657304ff057 GIT binary patch literal 15349 zcmeHO&2J;el^=?dhI*7Js`WV~yVkPTjWlxMI)gv(@ku*PMMu`@U7TJ;* zlif^rbH;LFVE3?qFF}y3FN*|w-#u)Q9QL|Eg20C$hd4lzOa6cWd)!k_dG*!ZY?5kf zG|4GCshd^5dSCUcSFftydAEDkg*%yD!!&H&HJX{@^Nf3DWV*KHS`Dk6IqsdD7S)s%6xjLhTjo>R3IyVQgnkE$g&x+|y0HeeSjz&b_AY>i3?$skggl zI(^7ePykc!7*1Dj7@6I2?!a($((-7R_CHcY|Dzr9_R*UP>HjuBqpdqmhP;IDKnDN1 zz2kPPk#Srdhs)e;IaP8HP#P z-tAhb_x+5Js7y?OW;iOCu3@8iM>~eouv=Z%vdh?Xd;8RIJp+4vL34H^_2fJ4vRzHOOFBC)-%J_8oFbwO;UX2^7z?2cK3(dyGDR}-L3$hdU3!S zBpa65Ks%en*3%Su?|DS_QG$}MZ$PSF8)*enzB{M~shigGu$&(TBCW!Fe+LI+B91Y! z05eUa-RiV(%2995La{&rTjtZ2(>iXmxJt-Boq#k3 zKaSw5CGEkCj=^|pTfHug&*avZB5W4M*l#&5I(8Qlmd$}!JU%B-0aB*r1{A0BBDr<% zl5(L;UxDcpsxgn?SI2_byOx`VNn%p@=m?gE=_~C((ziMD;^ifjKb?SS22Yscq-C_5 znjc3v$ee@zHcvIK1+(ktBDAQ|J`5L)phBu;YHjqAfFV4S+=_xJn8dRl%mZ{wuVY~N z2^hu-pO28H$T|gajt%#jVVDAkkw6qqj&%|^xmf@*KTfEB<&P&|HmJ8$0O;s$<4kkU zyNr2LTmKLtY7iiMKzi4(vor@&PxW@sU=x$fdP0htLnzv9Jr(ooUt=)icUp&)1ErSV z(`tuhRjU`PWi?-TP*8W$*Q6PkQlBXKS~@1pLo%oC7K&BvaiO-Cp1{Fo)Zz|*jN?pC zntUQ)Ye-OChP;qmPBu9J7~k`*yAvdh}mUgSRd&IESJh^MX41^ z#UXZmudeK)UD1sDYPG7>_LL%8bp<5vQ7ct6l{SmxT0Fa3QI(onVJ#;mgb%*)8&Aof z#o>C%ZW?y(TzUZ09m>U=G`}2S7v3++2%JCR)* zxfIM2+F)87pUdBm!CW7;Nbe#O+g3+obDpf|my1{FJ|tX=cOQ?j`@;R}FdKZ9mLZ9G z>|0+B2o%T2S%KN6g?j=cFj5Sct|U%cRFFz9|1k!Tx6Ulvt#*xu^cGxi&?m8CMJ3EG9)m#{mKodSPHM4pn1kPLRb39GvmoDTa+rBFK@3lfAHDwPU;_@ae4YMp6TW>Ua9aNC-ToUrHryyOyy{u(A1~Q9|=Fz1Ltf5_X zt!+7uMkkJiJ8E0At!LD;3CV$*PUFnz=;(Qp&(O^%`JV#u)T|KUitxDEDuu+?0#UTs zyY_J`Caq)0_H5fQ8|PZXY8q=K%b3}Vk>6He#>ME+KE#PaHwrU*6Xg93m^C_G_Z(%@ z9o$x3r(NRYr@OG~^p3w}G+YhmwtI%spIPlD#_w7JTP5};vDNzjPQZBG+M-$vW&;++9o({pn;)ZM_lUIA3Y`2Qi3OtY^4oN_#BD2wOzK7b3ts zv1x`RDKOWe*@!?P9!YL(MxZc}Sdx{6R0wolq-=Ck8(vvH2gyKp%uIQXOg05G;l_W8 z!yHy_FdKBw-|Jb(8aYV0*87-2Yor#?)ER?Di%ff0u?E(2q&&@Vlqy`D_}}i~oD^%)Wq=-m>=^b_)W)!F%VvsU36OFIQIZPC_Dq+-{U>;%Yhh7? zl=|A|KK0-v6w*=~Qh2tNx(s{?ZU&4vATKMUTmn$uf@ILXSnWdlI=BgJ(nWHL)H-Zj z46tm695w->cH&HW zw%7NoRXG_lT7+!!k0(ShReQ%QUBr#-f)_&C8D)CGv{|9V@N%wSH04V`9#WiY1rFod zs9czlB?tK;Ok#ROSccHF93cW*DiSy>Jv!hC(|9JtMb}H$NSY@9R}7MMB&w=$iZy0e zs={gyAMr4u(e9CAvWB&OtP!?!KG&kE$^o!E?}@wP8RG+v$2mDFI|#t2qO1Ii7%T>U z@bDkO5~*4uu{5y)gEG_lrEuw2BkUPO6bQSd04mjBk>EOH6~J>60n0obmD~qls~mu$ z%D;@kjlhps8fH?nF%MwD*TZR8T|$dw$xTHT^a-f2NtN}K4&jEwT+2&i!O6#Vqfs>+ z9vb1Y7;JUoS&%++1gRauy2IX# z=CvsP?1vPik(#I{J&(j_>(f&@E}Ul-*@2Z2gB)JSZ*NENTL`p|ZscFZ;H8TiNVsZ` z;-fK5CT#ULprqg6R<>Uo&%Dw%{UGo>77pVmPUqMjs29nB2=l>1!91q9!twmySZY$A z;@T{txejXvc^)0hQHyI3PIw3Nyn#rLn$ zqxPRC;JOId{!0rvnC-FEm}Z=uG^4hZfn^Dc-Fq^hmc~v_p)kIdyl@c(r0$g>Y@7s6<8Y93Xd0; zbgTuL=UUgoQ#f3LX|b7=XjnOE6_&MOZRFp_K;oc*@WV?$z~b1y>A~tH--bI5-@0{m z8>`{C4IjCQdw0CJFAE^%3_rl>Nl0!ElA13}?lrjUaoPnU$p03H4A*Sr0Me5|%FAC- zXwH3)2e|JA0UwSa!7Cg48t%*2MmcxPg3fS*2iWYpaCdkc-|LjtYQt#lsw&D@MnON2}b zvj&^UKf^E@Uj4JdsI3F($%k-fXp>NO zQXR$?S5!~_VH}o+4*vJtfZbB~OT$Du^VxELpSp7!0rBK4f(xU$0cuV*W5aL%vO50;p;& z4IT)NhM-CEkp~-HMJB1HXYtzpJbm%7uwOz&$;-J-4VH#osFW~jDr%J&yr%AGqwRu1 zwxiS(GzuD_LVR0S*_(;nciPbFFgh8w&pn@ziSL zW$~ho&PxGNmoqr=TCf HM*x2TC(@{l literal 0 HcmV?d00001 diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php new file mode 100644 index 00000000000..52ad212cf8c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php @@ -0,0 +1,76 @@ +google.analytics.data.v1alpha.AudienceDimension + */ +class AudienceDimension extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $dimension_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php new file mode 100644 index 00000000000..e34a79a37b1 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1alpha.AudienceDimensionValue + */ +class AudienceDimensionValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Value as a string if the dimension type is a string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->readOneof(1); + } + + public function hasValue() + { + return $this->hasOneof(1); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php new file mode 100644 index 00000000000..f365d873b01 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php @@ -0,0 +1,621 @@ +google.analytics.data.v1alpha.AudienceList + */ +class AudienceList extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The audience list resource name assigned during + * creation. This resource name identifies this `AudienceList`. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $audience = ''; + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $audience_display_name = ''; + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + private $dimensions; + /** + * Output only. The current state for this AudienceList. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = null; + /** + * Output only. The time when CreateAudienceList was called and the + * AudienceList began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $begin_creating_time = null; + /** + * Output only. The total quota tokens charged during creation of the + * AudienceList. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceList + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $creation_quota_tokens_charged = 0; + /** + * Output only. The total number of rows in the AudienceList result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $row_count = null; + /** + * Output only. Error message is populated when an audience list fails during + * creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $error_message = null; + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $percentage_completed = null; + /** + * Output only. The recurring audience list that created this audience list. + * Recurring audience lists create audience lists daily. + * If audience lists are created directly, they will have no associated + * recurring audience list, and this field will be blank. + * + * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $recurring_audience_list = null; + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when an audience list is + * ready to be used. Webhooks allow a notification to be sent to your servers + * & avoid the need for polling. + * Either one or two POST requests will be sent to the webhook. The first POST + * request will be sent immediately showing the newly created audience list in + * its CREATING state. The second POST request will be sent after the audience + * list completes creation (either the ACTIVE or FAILED state). + * If identical audience lists are requested in quick succession, the second & + * subsequent audience lists can be served from cache. In that case, the + * audience list create method can return an audience list is already ACTIVE. + * In this scenario, only one POST request will be sent to the webhook. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $webhook_notification = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The audience list resource name assigned during + * creation. This resource name identifies this `AudienceList`. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @type string $audience + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * @type string $audience_display_name + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * @type array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * Required. The dimensions requested and displayed in the query response. + * @type int $state + * Output only. The current state for this AudienceList. + * @type \Google\Protobuf\Timestamp $begin_creating_time + * Output only. The time when CreateAudienceList was called and the + * AudienceList began the `CREATING` state. + * @type int $creation_quota_tokens_charged + * Output only. The total quota tokens charged during creation of the + * AudienceList. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceList + * enters the `ACTIVE` or `FAILED` states. + * @type int $row_count + * Output only. The total number of rows in the AudienceList result. + * @type string $error_message + * Output only. Error message is populated when an audience list fails during + * creation. A common reason for such a failure is quota exhaustion. + * @type float $percentage_completed + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * @type string $recurring_audience_list + * Output only. The recurring audience list that created this audience list. + * Recurring audience lists create audience lists daily. + * If audience lists are created directly, they will have no associated + * recurring audience list, and this field will be blank. + * @type \Google\Analytics\Data\V1alpha\WebhookNotification $webhook_notification + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when an audience list is + * ready to be used. Webhooks allow a notification to be sent to your servers + * & avoid the need for polling. + * Either one or two POST requests will be sent to the webhook. The first POST + * request will be sent immediately showing the newly created audience list in + * its CREATING state. The second POST request will be sent after the audience + * list completes creation (either the ACTIVE or FAILED state). + * If identical audience lists are requested in quick succession, the second & + * subsequent audience lists can be served from cache. In that case, the + * audience list create method can return an audience list is already ACTIVE. + * In this scenario, only one POST request will be sent to the webhook. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The audience list resource name assigned during + * creation. This resource name identifies this `AudienceList`. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The audience list resource name assigned during + * creation. This resource name identifies this `AudienceList`. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getAudience() + { + return $this->audience; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setAudience($var) + { + GPBUtil::checkString($var, True); + $this->audience = $var; + + return $this; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getAudienceDisplayName() + { + return $this->audience_display_name; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setAudienceDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->audience_display_name = $var; + + return $this; + } + + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * Output only. The current state for this AudienceList. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return isset($this->state) ? $this->state : 0; + } + + public function hasState() + { + return isset($this->state); + } + + public function clearState() + { + unset($this->state); + } + + /** + * Output only. The current state for this AudienceList. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\AudienceList\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. The time when CreateAudienceList was called and the + * AudienceList began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBeginCreatingTime() + { + return $this->begin_creating_time; + } + + public function hasBeginCreatingTime() + { + return isset($this->begin_creating_time); + } + + public function clearBeginCreatingTime() + { + unset($this->begin_creating_time); + } + + /** + * Output only. The time when CreateAudienceList was called and the + * AudienceList began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBeginCreatingTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->begin_creating_time = $var; + + return $this; + } + + /** + * Output only. The total quota tokens charged during creation of the + * AudienceList. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceList + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getCreationQuotaTokensCharged() + { + return $this->creation_quota_tokens_charged; + } + + /** + * Output only. The total quota tokens charged during creation of the + * AudienceList. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceList + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setCreationQuotaTokensCharged($var) + { + GPBUtil::checkInt32($var); + $this->creation_quota_tokens_charged = $var; + + return $this; + } + + /** + * Output only. The total number of rows in the AudienceList result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getRowCount() + { + return isset($this->row_count) ? $this->row_count : 0; + } + + public function hasRowCount() + { + return isset($this->row_count); + } + + public function clearRowCount() + { + unset($this->row_count); + } + + /** + * Output only. The total number of rows in the AudienceList result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * Output only. Error message is populated when an audience list fails during + * creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getErrorMessage() + { + return isset($this->error_message) ? $this->error_message : ''; + } + + public function hasErrorMessage() + { + return isset($this->error_message); + } + + public function clearErrorMessage() + { + unset($this->error_message); + } + + /** + * Output only. Error message is populated when an audience list fails during + * creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setErrorMessage($var) + { + GPBUtil::checkString($var, True); + $this->error_message = $var; + + return $this; + } + + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return float + */ + public function getPercentageCompleted() + { + return isset($this->percentage_completed) ? $this->percentage_completed : 0.0; + } + + public function hasPercentageCompleted() + { + return isset($this->percentage_completed); + } + + public function clearPercentageCompleted() + { + unset($this->percentage_completed); + } + + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param float $var + * @return $this + */ + public function setPercentageCompleted($var) + { + GPBUtil::checkDouble($var); + $this->percentage_completed = $var; + + return $this; + } + + /** + * Output only. The recurring audience list that created this audience list. + * Recurring audience lists create audience lists daily. + * If audience lists are created directly, they will have no associated + * recurring audience list, and this field will be blank. + * + * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getRecurringAudienceList() + { + return isset($this->recurring_audience_list) ? $this->recurring_audience_list : ''; + } + + public function hasRecurringAudienceList() + { + return isset($this->recurring_audience_list); + } + + public function clearRecurringAudienceList() + { + unset($this->recurring_audience_list); + } + + /** + * Output only. The recurring audience list that created this audience list. + * Recurring audience lists create audience lists daily. + * If audience lists are created directly, they will have no associated + * recurring audience list, and this field will be blank. + * + * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setRecurringAudienceList($var) + { + GPBUtil::checkString($var, True); + $this->recurring_audience_list = $var; + + return $this; + } + + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when an audience list is + * ready to be used. Webhooks allow a notification to be sent to your servers + * & avoid the need for polling. + * Either one or two POST requests will be sent to the webhook. The first POST + * request will be sent immediately showing the newly created audience list in + * its CREATING state. The second POST request will be sent after the audience + * list completes creation (either the ACTIVE or FAILED state). + * If identical audience lists are requested in quick succession, the second & + * subsequent audience lists can be served from cache. In that case, the + * audience list create method can return an audience list is already ACTIVE. + * In this scenario, only one POST request will be sent to the webhook. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\WebhookNotification|null + */ + public function getWebhookNotification() + { + return $this->webhook_notification; + } + + public function hasWebhookNotification() + { + return isset($this->webhook_notification); + } + + public function clearWebhookNotification() + { + unset($this->webhook_notification); + } + + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when an audience list is + * ready to be used. Webhooks allow a notification to be sent to your servers + * & avoid the need for polling. + * Either one or two POST requests will be sent to the webhook. The first POST + * request will be sent immediately showing the newly created audience list in + * its CREATING state. The second POST request will be sent after the audience + * list completes creation (either the ACTIVE or FAILED state). + * If identical audience lists are requested in quick succession, the second & + * subsequent audience lists can be served from cache. In that case, the + * audience list create method can return an audience list is already ACTIVE. + * In this scenario, only one POST request will be sent to the webhook. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\WebhookNotification $var + * @return $this + */ + public function setWebhookNotification($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\WebhookNotification::class); + $this->webhook_notification = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php new file mode 100644 index 00000000000..abef9023454 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php @@ -0,0 +1,75 @@ +google.analytics.data.v1alpha.AudienceList.State + */ +class State +{ + /** + * Unspecified state will never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The AudienceList is currently creating and will be available in the + * future. Creating occurs immediately after the CreateAudienceList call. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * The AudienceList is fully created and ready for querying. An AudienceList + * is updated to active asynchronously from a request; this occurs some + * time (for example 15 minutes) after the initial create call. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The AudienceList failed to be created. It is possible that re-requesting + * this audience list will succeed. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + self::FAILED => 'FAILED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Analytics\Data\V1alpha\AudienceList_State::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php new file mode 100644 index 00000000000..5c620b9dd85 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php @@ -0,0 +1,33 @@ +google.analytics.data.v1alpha.AudienceListMetadata + */ +class AudienceListMetadata extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php new file mode 100644 index 00000000000..2047788e653 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php @@ -0,0 +1,71 @@ +google.analytics.data.v1alpha.AudienceRow + */ +class AudienceRow extends \Google\Protobuf\Internal\Message +{ + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; + */ + private $dimension_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionValues() + { + return $this->dimension_values; + } + + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; + * @param array<\Google\Analytics\Data\V1alpha\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimensionValue::class); + $this->dimension_values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php new file mode 100644 index 00000000000..1a3c30dd571 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php @@ -0,0 +1,121 @@ +google.analytics.data.v1alpha.BetweenFilter + */ +class BetweenFilter extends \Google\Protobuf\Internal\Message +{ + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; + */ + protected $from_value = null; + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; + */ + protected $to_value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\NumericValue $from_value + * Begins with this number. + * @type \Google\Analytics\Data\V1alpha\NumericValue $to_value + * Ends with this number. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; + * @return \Google\Analytics\Data\V1alpha\NumericValue|null + */ + public function getFromValue() + { + return $this->from_value; + } + + public function hasFromValue() + { + return isset($this->from_value); + } + + public function clearFromValue() + { + unset($this->from_value); + } + + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; + * @param \Google\Analytics\Data\V1alpha\NumericValue $var + * @return $this + */ + public function setFromValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); + $this->from_value = $var; + + return $this; + } + + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; + * @return \Google\Analytics\Data\V1alpha\NumericValue|null + */ + public function getToValue() + { + return $this->to_value; + } + + public function hasToValue() + { + return isset($this->to_value); + } + + public function clearToValue() + { + unset($this->to_value); + } + + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; + * @param \Google\Analytics\Data\V1alpha\NumericValue $var + * @return $this + */ + public function setToValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); + $this->to_value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php new file mode 100644 index 00000000000..ad2a39a6847 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php @@ -0,0 +1,215 @@ +google.analytics.data.v1alpha.Cohort + */ +class Cohort extends \Google\Protobuf\Internal\Message +{ + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + */ + protected $dimension = ''; + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; + */ + protected $date_range = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * @type string $dimension + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * @type \Google\Analytics\Data\V1alpha\DateRange $date_range + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + * @return string + */ + public function getDimension() + { + return $this->dimension; + } + + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + * @param string $var + * @return $this + */ + public function setDimension($var) + { + GPBUtil::checkString($var, True); + $this->dimension = $var; + + return $this; + } + + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; + * @return \Google\Analytics\Data\V1alpha\DateRange|null + */ + public function getDateRange() + { + return $this->date_range; + } + + public function hasDateRange() + { + return isset($this->date_range); + } + + public function clearDateRange() + { + unset($this->date_range); + } + + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; + * @param \Google\Analytics\Data\V1alpha\DateRange $var + * @return $this + */ + public function setDateRange($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DateRange::class); + $this->date_range = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php new file mode 100644 index 00000000000..4364a0b9c5a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php @@ -0,0 +1,71 @@ +google.analytics.data.v1alpha.CohortReportSettings + */ +class CohortReportSettings extends \Google\Protobuf\Internal\Message +{ + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + */ + protected $accumulate = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $accumulate + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + * @return bool + */ + public function getAccumulate() + { + return $this->accumulate; + } + + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + * @param bool $var + * @return $this + */ + public function setAccumulate($var) + { + GPBUtil::checkBool($var); + $this->accumulate = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php new file mode 100644 index 00000000000..6de328bb2e3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php @@ -0,0 +1,179 @@ +google.analytics.data.v1alpha.CohortSpec + */ +class CohortSpec extends \Google\Protobuf\Internal\Message +{ + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; + */ + private $cohorts; + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; + */ + protected $cohorts_range = null; + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; + */ + protected $cohort_report_settings = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $cohorts + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * @type \Google\Analytics\Data\V1alpha\CohortsRange $cohorts_range + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * @type \Google\Analytics\Data\V1alpha\CohortReportSettings $cohort_report_settings + * Optional settings for a cohort report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCohorts() + { + return $this->cohorts; + } + + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; + * @param array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCohorts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Cohort::class); + $this->cohorts = $arr; + + return $this; + } + + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; + * @return \Google\Analytics\Data\V1alpha\CohortsRange|null + */ + public function getCohortsRange() + { + return $this->cohorts_range; + } + + public function hasCohortsRange() + { + return isset($this->cohorts_range); + } + + public function clearCohortsRange() + { + unset($this->cohorts_range); + } + + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; + * @param \Google\Analytics\Data\V1alpha\CohortsRange $var + * @return $this + */ + public function setCohortsRange($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\CohortsRange::class); + $this->cohorts_range = $var; + + return $this; + } + + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; + * @return \Google\Analytics\Data\V1alpha\CohortReportSettings|null + */ + public function getCohortReportSettings() + { + return $this->cohort_report_settings; + } + + public function hasCohortReportSettings() + { + return isset($this->cohort_report_settings); + } + + public function clearCohortReportSettings() + { + unset($this->cohort_report_settings); + } + + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; + * @param \Google\Analytics\Data\V1alpha\CohortReportSettings $var + * @return $this + */ + public function setCohortReportSettings($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\CohortReportSettings::class); + $this->cohort_report_settings = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php new file mode 100644 index 00000000000..3133c9ca748 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php @@ -0,0 +1,208 @@ +google.analytics.data.v1alpha.CohortsRange + */ +class CohortsRange extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; + */ + protected $granularity = 0; + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + */ + protected $start_offset = 0; + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + */ + protected $end_offset = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $granularity + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * @type int $start_offset + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * @type int $end_offset + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; + * @return int + */ + public function getGranularity() + { + return $this->granularity; + } + + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; + * @param int $var + * @return $this + */ + public function setGranularity($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\CohortsRange\Granularity::class); + $this->granularity = $var; + + return $this; + } + + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + * @return int + */ + public function getStartOffset() + { + return $this->start_offset; + } + + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + * @param int $var + * @return $this + */ + public function setStartOffset($var) + { + GPBUtil::checkInt32($var); + $this->start_offset = $var; + + return $this; + } + + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + * @return int + */ + public function getEndOffset() + { + return $this->end_offset; + } + + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + * @param int $var + * @return $this + */ + public function setEndOffset($var) + { + GPBUtil::checkInt32($var); + $this->end_offset = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php new file mode 100644 index 00000000000..d5c75924d4b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php @@ -0,0 +1,76 @@ +google.analytics.data.v1alpha.CohortsRange.Granularity + */ +class Granularity +{ + /** + * Should never be specified. + * + * Generated from protobuf enum GRANULARITY_UNSPECIFIED = 0; + */ + const GRANULARITY_UNSPECIFIED = 0; + /** + * Daily granularity. Commonly used if the cohort's `dateRange` is a single + * day and the request contains `cohortNthDay`. + * + * Generated from protobuf enum DAILY = 1; + */ + const DAILY = 1; + /** + * Weekly granularity. Commonly used if the cohort's `dateRange` is a week + * in duration (starting on Sunday and ending on Saturday) and the request + * contains `cohortNthWeek`. + * + * Generated from protobuf enum WEEKLY = 2; + */ + const WEEKLY = 2; + /** + * Monthly granularity. Commonly used if the cohort's `dateRange` is a month + * in duration and the request contains `cohortNthMonth`. + * + * Generated from protobuf enum MONTHLY = 3; + */ + const MONTHLY = 3; + + private static $valueToName = [ + self::GRANULARITY_UNSPECIFIED => 'GRANULARITY_UNSPECIFIED', + self::DAILY => 'DAILY', + self::WEEKLY => 'WEEKLY', + self::MONTHLY => 'MONTHLY', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Granularity::class, \Google\Analytics\Data\V1alpha\CohortsRange_Granularity::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php new file mode 100644 index 00000000000..3f2845a201c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php @@ -0,0 +1,132 @@ +google.analytics.data.v1alpha.CreateAudienceListRequest + */ +class CreateAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $audience_list = null; + + /** + * @param string $parent Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * @param \Google\Analytics\Data\V1alpha\AudienceList $audienceList Required. The audience list to create. + * + * @return \Google\Analytics\Data\V1alpha\CreateAudienceListRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Analytics\Data\V1alpha\AudienceList $audienceList): self + { + return (new self()) + ->setParent($parent) + ->setAudienceList($audienceList); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list + * Required. The audience list to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Analytics\Data\V1alpha\AudienceList|null + */ + public function getAudienceList() + { + return $this->audience_list; + } + + public function hasAudienceList() + { + return isset($this->audience_list); + } + + public function clearAudienceList() + { + unset($this->audience_list); + } + + /** + * Required. The audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Analytics\Data\V1alpha\AudienceList $var + * @return $this + */ + public function setAudienceList($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); + $this->audience_list = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php new file mode 100644 index 00000000000..597ed8af253 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php @@ -0,0 +1,132 @@ +google.analytics.data.v1alpha.CreateRecurringAudienceListRequest + */ +class CreateRecurringAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The recurring audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $recurring_audience_list = null; + + /** + * @param string $parent Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * @param \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurringAudienceList Required. The recurring audience list to create. + * + * @return \Google\Analytics\Data\V1alpha\CreateRecurringAudienceListRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurringAudienceList): self + { + return (new self()) + ->setParent($parent) + ->setRecurringAudienceList($recurringAudienceList); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * @type \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurring_audience_list + * Required. The recurring audience list to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The recurring audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList|null + */ + public function getRecurringAudienceList() + { + return $this->recurring_audience_list; + } + + public function hasRecurringAudienceList() + { + return isset($this->recurring_audience_list); + } + + public function clearRecurringAudienceList() + { + unset($this->recurring_audience_list); + } + + /** + * Required. The recurring audience list to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Analytics\Data\V1alpha\RecurringAudienceList $var + * @return $this + */ + public function setRecurringAudienceList($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\RecurringAudienceList::class); + $this->recurring_audience_list = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php new file mode 100644 index 00000000000..7c87d8ddfb7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php @@ -0,0 +1,132 @@ +google.analytics.data.v1alpha.CreateReportTaskRequest + */ +class CreateReportTaskRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The report task configuration to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask report_task = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $report_task = null; + + /** + * @param string $parent Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * @param \Google\Analytics\Data\V1alpha\ReportTask $reportTask Required. The report task configuration to create. + * + * @return \Google\Analytics\Data\V1alpha\CreateReportTaskRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Analytics\Data\V1alpha\ReportTask $reportTask): self + { + return (new self()) + ->setParent($parent) + ->setReportTask($reportTask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * @type \Google\Analytics\Data\V1alpha\ReportTask $report_task + * Required. The report task configuration to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The report task configuration to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask report_task = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Analytics\Data\V1alpha\ReportTask|null + */ + public function getReportTask() + { + return $this->report_task; + } + + public function hasReportTask() + { + return isset($this->report_task); + } + + public function clearReportTask() + { + unset($this->report_task); + } + + /** + * Required. The report task configuration to create. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask report_task = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Analytics\Data\V1alpha\ReportTask $var + * @return $this + */ + public function setReportTask($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ReportTask::class); + $this->report_task = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php new file mode 100644 index 00000000000..0d7a4291b97 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php @@ -0,0 +1,172 @@ +google.analytics.data.v1alpha.DateRange + */ +class DateRange extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + */ + protected $start_date = ''; + /** + * 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. + * + * Generated from protobuf field string end_date = 2; + */ + protected $end_date = ''; + /** + * 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. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $start_date + * 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. + * @type string $end_date + * 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. + * @type string $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + * @return string + */ + public function getStartDate() + { + return $this->start_date; + } + + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + * @param string $var + * @return $this + */ + public function setStartDate($var) + { + GPBUtil::checkString($var, True); + $this->start_date = $var; + + 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. + * + * Generated from protobuf field string end_date = 2; + * @return string + */ + public function getEndDate() + { + return $this->end_date; + } + + /** + * 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. + * + * Generated from protobuf field string end_date = 2; + * @param string $var + * @return $this + */ + public function setEndDate($var) + { + GPBUtil::checkString($var, True); + $this->end_date = $var; + + 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. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->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. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php new file mode 100644 index 00000000000..b1deaf99406 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php @@ -0,0 +1,189 @@ +google.analytics.data.v1alpha.Dimension + */ +class Dimension extends \Google\Protobuf\Internal\Message +{ + /** + * 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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + */ + protected $dimension_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * @type \Google\Analytics\Data\V1alpha\DimensionExpression $dimension_expression + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * @return \Google\Analytics\Data\V1alpha\DimensionExpression|null + */ + public function getDimensionExpression() + { + return $this->dimension_expression; + } + + public function hasDimensionExpression() + { + return isset($this->dimension_expression); + } + + public function clearDimensionExpression() + { + unset($this->dimension_expression); + } + + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; + * @param \Google\Analytics\Data\V1alpha\DimensionExpression $var + * @return $this + */ + public function setDimensionExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression::class); + $this->dimension_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php new file mode 100644 index 00000000000..95d5d64ceb7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php @@ -0,0 +1,147 @@ +google.analytics.data.v1alpha.DimensionExpression + */ +class DimensionExpression extends \Google\Protobuf\Internal\Message +{ + protected $one_expression; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $lower_case + * Used to convert a dimension value to lower case. + * @type \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $upper_case + * Used to convert a dimension value to upper case. + * @type \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression $concatenate + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Used to convert a dimension value to lower case. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * @return \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression|null + */ + public function getLowerCase() + { + return $this->readOneof(4); + } + + public function hasLowerCase() + { + return $this->hasOneof(4); + } + + /** + * Used to convert a dimension value to lower case. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; + * @param \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $var + * @return $this + */ + public function setLowerCase($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Used to convert a dimension value to upper case. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * @return \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression|null + */ + public function getUpperCase() + { + return $this->readOneof(5); + } + + public function hasUpperCase() + { + return $this->hasOneof(5); + } + + /** + * Used to convert a dimension value to upper case. + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; + * @param \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $var + * @return $this + */ + public function setUpperCase($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * @return \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression|null + */ + public function getConcatenate() + { + return $this->readOneof(6); + } + + public function hasConcatenate() + { + return $this->hasOneof(6); + } + + /** + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; + * @param \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression $var + * @return $this + */ + public function setConcatenate($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneExpression() + { + return $this->whichOneof("one_expression"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php new file mode 100644 index 00000000000..da9ca59bb91 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php @@ -0,0 +1,74 @@ +google.analytics.data.v1alpha.DimensionExpression.CaseExpression + */ +class CaseExpression extends \Google\Protobuf\Internal\Message +{ + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + */ + protected $dimension_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CaseExpression::class, \Google\Analytics\Data\V1alpha\DimensionExpression_CaseExpression::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php new file mode 100644 index 00000000000..22367f8c52d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php @@ -0,0 +1,128 @@ +google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression + */ +class ConcatenateExpression extends \Google\Protobuf\Internal\Message +{ + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + */ + private $dimension_names; + /** + * 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". + * + * Generated from protobuf field string delimiter = 2; + */ + protected $delimiter = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $dimension_names + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * @type string $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". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionNames() + { + return $this->dimension_names; + } + + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->dimension_names = $arr; + + 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". + * + * Generated from protobuf field string delimiter = 2; + * @return string + */ + public function getDelimiter() + { + return $this->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". + * + * Generated from protobuf field string delimiter = 2; + * @param string $var + * @return $this + */ + public function setDelimiter($var) + { + GPBUtil::checkString($var, True); + $this->delimiter = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ConcatenateExpression::class, \Google\Analytics\Data\V1alpha\DimensionExpression_ConcatenateExpression::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php new file mode 100644 index 00000000000..3d84d708eee --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php @@ -0,0 +1,70 @@ +google.analytics.data.v1alpha.DimensionHeader + */ +class DimensionHeader extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The dimension's name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php new file mode 100644 index 00000000000..b73fad0eaf8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1alpha.DimensionValue + */ +class DimensionValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Value as a string if the dimension type is a string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->readOneof(1); + } + + public function hasValue() + { + return $this->hasOneof(1); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php new file mode 100644 index 00000000000..760528e9a04 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php @@ -0,0 +1,56 @@ +google.analytics.data.v1alpha.EventCriteriaScoping + */ +class EventCriteriaScoping +{ + /** + * Unspecified criteria scoping. Do not specify. + * + * Generated from protobuf enum EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + const EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; + /** + * If the criteria is satisfied within one event, the event matches the + * criteria. + * + * Generated from protobuf enum EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + const EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; + + private static $valueToName = [ + self::EVENT_CRITERIA_SCOPING_UNSPECIFIED => 'EVENT_CRITERIA_SCOPING_UNSPECIFIED', + self::EVENT_CRITERIA_WITHIN_SAME_EVENT => 'EVENT_CRITERIA_WITHIN_SAME_EVENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php new file mode 100644 index 00000000000..9a97210c923 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php @@ -0,0 +1,56 @@ +google.analytics.data.v1alpha.EventExclusionDuration + */ +class EventExclusionDuration +{ + /** + * Unspecified exclusion duration. Do not specify. + * + * Generated from protobuf enum EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + const EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; + /** + * Permanently exclude events from the segment if the event ever meets + * the `eventExclusionCriteria` condition. + * + * Generated from protobuf enum EVENT_EXCLUSION_PERMANENT = 1; + */ + const EVENT_EXCLUSION_PERMANENT = 1; + + private static $valueToName = [ + self::EVENT_EXCLUSION_DURATION_UNSPECIFIED => 'EVENT_EXCLUSION_DURATION_UNSPECIFIED', + self::EVENT_EXCLUSION_PERMANENT => 'EVENT_EXCLUSION_PERMANENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php new file mode 100644 index 00000000000..1a9340fde93 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php @@ -0,0 +1,123 @@ +google.analytics.data.v1alpha.EventSegment + */ +class EventSegment extends \Google\Protobuf\Internal\Message +{ + /** + * Defines which events are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + */ + protected $event_inclusion_criteria = null; + /** + * Defines which events are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + */ + protected $exclusion = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\EventSegmentCriteria $event_inclusion_criteria + * Defines which events are included in this segment. Optional. + * @type \Google\Analytics\Data\V1alpha\EventSegmentExclusion $exclusion + * Defines which events are excluded in this segment. Optional. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Defines which events are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * @return \Google\Analytics\Data\V1alpha\EventSegmentCriteria|null + */ + public function getEventInclusionCriteria() + { + return $this->event_inclusion_criteria; + } + + public function hasEventInclusionCriteria() + { + return isset($this->event_inclusion_criteria); + } + + public function clearEventInclusionCriteria() + { + unset($this->event_inclusion_criteria); + } + + /** + * Defines which events are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; + * @param \Google\Analytics\Data\V1alpha\EventSegmentCriteria $var + * @return $this + */ + public function setEventInclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentCriteria::class); + $this->event_inclusion_criteria = $var; + + return $this; + } + + /** + * Defines which events are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * @return \Google\Analytics\Data\V1alpha\EventSegmentExclusion|null + */ + public function getExclusion() + { + return $this->exclusion; + } + + public function hasExclusion() + { + return isset($this->exclusion); + } + + public function clearExclusion() + { + unset($this->exclusion); + } + + /** + * Defines which events are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; + * @param \Google\Analytics\Data\V1alpha\EventSegmentExclusion $var + * @return $this + */ + public function setExclusion($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentExclusion::class); + $this->exclusion = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php new file mode 100644 index 00000000000..6ff4974e6ae --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php @@ -0,0 +1,128 @@ +google.analytics.data.v1alpha.EventSegmentConditionGroup + */ +class EventSegmentConditionGroup extends \Google\Protobuf\Internal\Message +{ + /** + * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. + * Optional. If unspecified, a `conditionScoping` of + * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + */ + protected $condition_scoping = 0; + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + */ + protected $segment_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $condition_scoping + * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. + * Optional. If unspecified, a `conditionScoping` of + * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. + * Optional. If unspecified, a `conditionScoping` of + * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * @return int + */ + public function getConditionScoping() + { + return $this->condition_scoping; + } + + /** + * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. + * Optional. If unspecified, a `conditionScoping` of + * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; + * @param int $var + * @return $this + */ + public function setConditionScoping($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\EventCriteriaScoping::class); + $this->condition_scoping = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null + */ + public function getSegmentFilterExpression() + { + return $this->segment_filter_expression; + } + + public function hasSegmentFilterExpression() + { + return isset($this->segment_filter_expression); + } + + public function clearSegmentFilterExpression() + { + unset($this->segment_filter_expression); + } + + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var + * @return $this + */ + public function setSegmentFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->segment_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php new file mode 100644 index 00000000000..d0770b39d84 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php @@ -0,0 +1,72 @@ +google.analytics.data.v1alpha.EventSegmentCriteria + */ +class EventSegmentCriteria extends \Google\Protobuf\Internal\Message +{ + /** + * An event matches this criteria if the event matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + */ + private $and_condition_groups; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\EventSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups + * An event matches this criteria if the event matches each of these + * `andConditionGroups`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * An event matches this criteria if the event matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAndConditionGroups() + { + return $this->and_condition_groups; + } + + /** + * An event matches this criteria if the event matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; + * @param array<\Google\Analytics\Data\V1alpha\EventSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAndConditionGroups($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\EventSegmentConditionGroup::class); + $this->and_condition_groups = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php new file mode 100644 index 00000000000..8c4db8412dd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php @@ -0,0 +1,123 @@ +google.analytics.data.v1alpha.EventSegmentExclusion + */ +class EventSegmentExclusion extends \Google\Protobuf\Internal\Message +{ + /** + * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. + * Optional. If unspecified, an `eventExclusionDuration` of + * `EVENT_EXCLUSION_PERMANENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + */ + protected $event_exclusion_duration = 0; + /** + * If an event meets this condition, the event is excluded from membership + * in the segment for the `eventExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + */ + protected $event_exclusion_criteria = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $event_exclusion_duration + * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. + * Optional. If unspecified, an `eventExclusionDuration` of + * `EVENT_EXCLUSION_PERMANENT` is used. + * @type \Google\Analytics\Data\V1alpha\EventSegmentCriteria $event_exclusion_criteria + * If an event meets this condition, the event is excluded from membership + * in the segment for the `eventExclusionDuration`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. + * Optional. If unspecified, an `eventExclusionDuration` of + * `EVENT_EXCLUSION_PERMANENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * @return int + */ + public function getEventExclusionDuration() + { + return $this->event_exclusion_duration; + } + + /** + * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. + * Optional. If unspecified, an `eventExclusionDuration` of + * `EVENT_EXCLUSION_PERMANENT` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; + * @param int $var + * @return $this + */ + public function setEventExclusionDuration($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\EventExclusionDuration::class); + $this->event_exclusion_duration = $var; + + return $this; + } + + /** + * If an event meets this condition, the event is excluded from membership + * in the segment for the `eventExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * @return \Google\Analytics\Data\V1alpha\EventSegmentCriteria|null + */ + public function getEventExclusionCriteria() + { + return $this->event_exclusion_criteria; + } + + public function hasEventExclusionCriteria() + { + return isset($this->event_exclusion_criteria); + } + + public function clearEventExclusionCriteria() + { + unset($this->event_exclusion_criteria); + } + + /** + * If an event meets this condition, the event is excluded from membership + * in the segment for the `eventExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; + * @param \Google\Analytics\Data\V1alpha\EventSegmentCriteria $var + * @return $this + */ + public function setEventExclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentCriteria::class); + $this->event_exclusion_criteria = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php new file mode 100644 index 00000000000..1a4a786517f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php @@ -0,0 +1,212 @@ +google.analytics.data.v1alpha.Filter + */ +class Filter extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension name or metric name. Must be a name defined in dimensions + * or metrics. + * + * Generated from protobuf field string field_name = 1; + */ + protected $field_name = ''; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field_name + * The dimension name or metric name. Must be a name defined in dimensions + * or metrics. + * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter + * A filter for between two values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension name or metric name. Must be a name defined in dimensions + * or metrics. + * + * Generated from protobuf field string field_name = 1; + * @return string + */ + public function getFieldName() + { + return $this->field_name; + } + + /** + * The dimension name or metric name. Must be a name defined in dimensions + * or metrics. + * + * Generated from protobuf field string field_name = 1; + * @param string $var + * @return $this + */ + public function setFieldName($var) + { + GPBUtil::checkString($var, True); + $this->field_name = $var; + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * @return \Google\Analytics\Data\V1alpha\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(2); + } + + public function hasStringFilter() + { + return $this->hasOneof(2); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 2; + * @param \Google\Analytics\Data\V1alpha\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * @return \Google\Analytics\Data\V1alpha\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(3); + } + + public function hasInListFilter() + { + return $this->hasOneof(3); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; + * @param \Google\Analytics\Data\V1alpha\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * @return \Google\Analytics\Data\V1alpha\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(4); + } + + public function hasNumericFilter() + { + return $this->hasOneof(4); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; + * @param \Google\Analytics\Data\V1alpha\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(5); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; + * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php new file mode 100644 index 00000000000..16c59dd4950 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php @@ -0,0 +1,178 @@ +google.analytics.data.v1alpha.FilterExpression + */ +class FilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\FilterExpressionList $and_group + * The FilterExpressions in and_group have an AND relationship. + * @type \Google\Analytics\Data\V1alpha\FilterExpressionList $or_group + * The FilterExpressions in or_group have an OR relationship. + * @type \Google\Analytics\Data\V1alpha\FilterExpression $not_expression + * The FilterExpression is NOT of not_expression. + * @type \Google\Analytics\Data\V1alpha\Filter $filter + * A primitive filter. In the same FilterExpression, all of the filter's + * field names need to be either all dimensions or all metrics. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The FilterExpressions in and_group have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1alpha\FilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The FilterExpressions in and_group have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1alpha\FilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The FilterExpressions in or_group have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1alpha\FilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The FilterExpressions in or_group have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1alpha\FilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The FilterExpression is NOT of not_expression. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1alpha\FilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The FilterExpression is NOT of not_expression. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1alpha\FilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); + $this->writeOneof(3, $var); + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Filter filter = 4; + * @return \Google\Analytics\Data\V1alpha\Filter|null + */ + public function getFilter() + { + return $this->readOneof(4); + } + + public function hasFilter() + { + return $this->hasOneof(4); + } + + /** + * A primitive filter. In the same FilterExpression, all of the filter's + * field names need to be either all dimensions or all metrics. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Filter filter = 4; + * @param \Google\Analytics\Data\V1alpha\Filter $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Filter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php new file mode 100644 index 00000000000..d570c1b614d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.FilterExpressionList + */ +class FilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * A list of filter expressions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1alpha\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php new file mode 100644 index 00000000000..44df64bb900 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php @@ -0,0 +1,115 @@ +google.analytics.data.v1alpha.Funnel + */ +class Funnel extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field bool is_open_funnel = 1; + */ + protected $is_open_funnel = false; + /** + * The sequential steps of this funnel. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + */ + private $steps; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $is_open_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. + * @type array<\Google\Analytics\Data\V1alpha\FunnelStep>|\Google\Protobuf\Internal\RepeatedField $steps + * The sequential steps of this funnel. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field bool is_open_funnel = 1; + * @return bool + */ + public function getIsOpenFunnel() + { + return $this->is_open_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. + * + * Generated from protobuf field bool is_open_funnel = 1; + * @param bool $var + * @return $this + */ + public function setIsOpenFunnel($var) + { + GPBUtil::checkBool($var); + $this->is_open_funnel = $var; + + return $this; + } + + /** + * The sequential steps of this funnel. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSteps() + { + return $this->steps; + } + + /** + * The sequential steps of this funnel. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; + * @param array<\Google\Analytics\Data\V1alpha\FunnelStep>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSteps($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelStep::class); + $this->steps = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php new file mode 100644 index 00000000000..0500c7956bd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php @@ -0,0 +1,137 @@ +google.analytics.data.v1alpha.FunnelBreakdown + */ +class FunnelBreakdown extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + */ + protected $breakdown_dimension = null; + /** + * 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. + * + * Generated from protobuf field optional int64 limit = 2; + */ + protected $limit = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\Dimension $breakdown_dimension + * 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. + * @type int|string $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * @return \Google\Analytics\Data\V1alpha\Dimension|null + */ + public function getBreakdownDimension() + { + return $this->breakdown_dimension; + } + + public function hasBreakdownDimension() + { + return isset($this->breakdown_dimension); + } + + public function clearBreakdownDimension() + { + unset($this->breakdown_dimension); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; + * @param \Google\Analytics\Data\V1alpha\Dimension $var + * @return $this + */ + public function setBreakdownDimension($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Dimension::class); + $this->breakdown_dimension = $var; + + 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. + * + * Generated from protobuf field optional int64 limit = 2; + * @return int|string + */ + public function getLimit() + { + return isset($this->limit) ? $this->limit : 0; + } + + public function hasLimit() + { + return isset($this->limit); + } + + public function clearLimit() + { + unset($this->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. + * + * Generated from protobuf field optional int64 limit = 2; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php new file mode 100644 index 00000000000..bd0a9458b38 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php @@ -0,0 +1,140 @@ +google.analytics.data.v1alpha.FunnelEventFilter + */ +class FunnelEventFilter extends \Google\Protobuf\Internal\Message +{ + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + */ + protected $event_name = null; + /** + * 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + */ + protected $funnel_parameter_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $event_name + * This filter matches events of this single event name. Event name is + * required. + * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $funnel_parameter_filter_expression + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + * @return string + */ + public function getEventName() + { + return isset($this->event_name) ? $this->event_name : ''; + } + + public function hasEventName() + { + return isset($this->event_name); + } + + public function clearEventName() + { + unset($this->event_name); + } + + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + * @param string $var + * @return $this + */ + public function setEventName($var) + { + GPBUtil::checkString($var, True); + $this->event_name = $var; + + 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression|null + */ + public function getFunnelParameterFilterExpression() + { + return $this->funnel_parameter_filter_expression; + } + + public function hasFunnelParameterFilterExpression() + { + return isset($this->funnel_parameter_filter_expression); + } + + public function clearFunnelParameterFilterExpression() + { + unset($this->funnel_parameter_filter_expression); + } + + /** + * 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; + * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $var + * @return $this + */ + public function setFunnelParameterFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); + $this->funnel_parameter_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php new file mode 100644 index 00000000000..2b3cf703f56 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php @@ -0,0 +1,208 @@ +google.analytics.data.v1alpha.FunnelFieldFilter + */ +class FunnelFieldFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + */ + protected $field_name = ''; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field_name + * The dimension name or metric name. + * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter + * A filter for between two values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + * @return string + */ + public function getFieldName() + { + return $this->field_name; + } + + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + * @param string $var + * @return $this + */ + public function setFieldName($var) + { + GPBUtil::checkString($var, True); + $this->field_name = $var; + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @return \Google\Analytics\Data\V1alpha\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(4); + } + + public function hasStringFilter() + { + return $this->hasOneof(4); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @param \Google\Analytics\Data\V1alpha\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @return \Google\Analytics\Data\V1alpha\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(5); + } + + public function hasInListFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @param \Google\Analytics\Data\V1alpha\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @return \Google\Analytics\Data\V1alpha\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(6); + } + + public function hasNumericFilter() + { + return $this->hasOneof(6); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @param \Google\Analytics\Data\V1alpha\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(7); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(7); + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php new file mode 100644 index 00000000000..0bd5a29dcb3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php @@ -0,0 +1,216 @@ +google.analytics.data.v1alpha.FunnelFilterExpression + */ +class FunnelFilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $and_group + * The FunnelFilterExpression in `andGroup` have an AND relationship. + * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $or_group + * The FunnelFilterExpression in `orGroup` have an OR relationship. + * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpression $not_expression + * The FunnelFilterExpression is NOT of `notExpression`. + * @type \Google\Analytics\Data\V1alpha\FunnelFieldFilter $funnel_field_filter + * A funnel filter for a dimension or metric. + * @type \Google\Analytics\Data\V1alpha\FunnelEventFilter $funnel_event_filter + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The FunnelFilterExpression in `andGroup` have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The FunnelFilterExpression in `andGroup` have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The FunnelFilterExpression in `orGroup` have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The FunnelFilterExpression in `orGroup` have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The FunnelFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The FunnelFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A funnel filter for a dimension or metric. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFieldFilter funnel_field_filter = 4; + * @return \Google\Analytics\Data\V1alpha\FunnelFieldFilter|null + */ + public function getFunnelFieldFilter() + { + return $this->readOneof(4); + } + + public function hasFunnelFieldFilter() + { + return $this->hasOneof(4); + } + + /** + * A funnel filter for a dimension or metric. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFieldFilter funnel_field_filter = 4; + * @param \Google\Analytics\Data\V1alpha\FunnelFieldFilter $var + * @return $this + */ + public function setFunnelFieldFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFieldFilter::class); + $this->writeOneof(4, $var); + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * @return \Google\Analytics\Data\V1alpha\FunnelEventFilter|null + */ + public function getFunnelEventFilter() + { + return $this->readOneof(5); + } + + public function hasFunnelEventFilter() + { + return $this->hasOneof(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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; + * @param \Google\Analytics\Data\V1alpha\FunnelEventFilter $var + * @return $this + */ + public function setFunnelEventFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelEventFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php new file mode 100644 index 00000000000..5e3753f3b65 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.FunnelFilterExpressionList + */ +class FunnelFilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * The list of funnel filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\FunnelFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * The list of funnel filter expressions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of funnel filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * The list of funnel filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1alpha\FunnelFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php new file mode 100644 index 00000000000..0292b72b3d9 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php @@ -0,0 +1,154 @@ +google.analytics.data.v1alpha.FunnelNextAction + */ +class FunnelNextAction extends \Google\Protobuf\Internal\Message +{ + /** + * 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 `eventName` and most Page / + * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` + * cannot be a dimension expression. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + */ + protected $next_action_dimension = null; + /** + * 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. + * + * Generated from protobuf field optional int64 limit = 2; + */ + protected $limit = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\Dimension $next_action_dimension + * 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 `eventName` and most Page / + * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` + * cannot be a dimension expression. + * @type int|string $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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 `eventName` and most Page / + * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` + * cannot be a dimension expression. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * @return \Google\Analytics\Data\V1alpha\Dimension|null + */ + public function getNextActionDimension() + { + return $this->next_action_dimension; + } + + public function hasNextActionDimension() + { + return isset($this->next_action_dimension); + } + + public function clearNextActionDimension() + { + unset($this->next_action_dimension); + } + + /** + * 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 `eventName` and most Page / + * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` + * cannot be a dimension expression. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; + * @param \Google\Analytics\Data\V1alpha\Dimension $var + * @return $this + */ + public function setNextActionDimension($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Dimension::class); + $this->next_action_dimension = $var; + + 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. + * + * Generated from protobuf field optional int64 limit = 2; + * @return int|string + */ + public function getLimit() + { + return isset($this->limit) ? $this->limit : 0; + } + + public function hasLimit() + { + return isset($this->limit); + } + + public function clearLimit() + { + unset($this->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. + * + * Generated from protobuf field optional int64 limit = 2; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php new file mode 100644 index 00000000000..154ec61a260 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php @@ -0,0 +1,291 @@ +google.analytics.data.v1alpha.FunnelParameterFilter + */ +class FunnelParameterFilter extends \Google\Protobuf\Internal\Message +{ + protected $one_parameter; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $event_parameter_name + * 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. + * @type string $item_parameter_name + * 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. + * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter + * A filter for between two values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field string event_parameter_name = 1; + * @return string + */ + public function getEventParameterName() + { + return $this->readOneof(1); + } + + public function hasEventParameterName() + { + return $this->hasOneof(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. + * + * Generated from protobuf field string event_parameter_name = 1; + * @param string $var + * @return $this + */ + public function setEventParameterName($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + 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. + * + * Generated from protobuf field string item_parameter_name = 2; + * @return string + */ + public function getItemParameterName() + { + return $this->readOneof(2); + } + + public function hasItemParameterName() + { + return $this->hasOneof(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. + * + * Generated from protobuf field string item_parameter_name = 2; + * @param string $var + * @return $this + */ + public function setItemParameterName($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @return \Google\Analytics\Data\V1alpha\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(4); + } + + public function hasStringFilter() + { + return $this->hasOneof(4); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @param \Google\Analytics\Data\V1alpha\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @return \Google\Analytics\Data\V1alpha\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(5); + } + + public function hasInListFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @param \Google\Analytics\Data\V1alpha\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @return \Google\Analytics\Data\V1alpha\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(6); + } + + public function hasNumericFilter() + { + return $this->hasOneof(6); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @param \Google\Analytics\Data\V1alpha\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(7); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(7); + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneParameter() + { + return $this->whichOneof("one_parameter"); + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php new file mode 100644 index 00000000000..dfc32d8c01a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php @@ -0,0 +1,180 @@ +google.analytics.data.v1alpha.FunnelParameterFilterExpression + */ +class FunnelParameterFilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $and_group + * The FunnelParameterFilterExpression in `andGroup` have an AND + * relationship. + * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $or_group + * The FunnelParameterFilterExpression in `orGroup` have an OR + * relationship. + * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $not_expression + * The FunnelParameterFilterExpression is NOT of `notExpression`. + * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilter $funnel_parameter_filter + * A primitive funnel parameter filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The FunnelParameterFilterExpression in `andGroup` have an AND + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The FunnelParameterFilterExpression in `andGroup` have an AND + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The FunnelParameterFilterExpression in `orGroup` have an OR + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The FunnelParameterFilterExpression in `orGroup` have an OR + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The FunnelParameterFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The FunnelParameterFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A primitive funnel parameter filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilter|null + */ + public function getFunnelParameterFilter() + { + return $this->readOneof(4); + } + + public function hasFunnelParameterFilter() + { + return $this->hasOneof(4); + } + + /** + * A primitive funnel parameter filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; + * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilter $var + * @return $this + */ + public function setFunnelParameterFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php new file mode 100644 index 00000000000..4ef706a4067 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.FunnelParameterFilterExpressionList + */ +class FunnelParameterFilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * The list of funnel parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * The list of funnel parameter filter expressions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of funnel parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * The list of funnel parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php new file mode 100644 index 00000000000..78714d6506c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php @@ -0,0 +1,92 @@ +google.analytics.data.v1alpha.FunnelResponseMetadata + */ +class FunnelResponseMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * If funnel report results are + * [sampled](https://support.google.com/analytics/answer/13331292), 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + */ + private $sampling_metadatas; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $sampling_metadatas + * If funnel report results are + * [sampled](https://support.google.com/analytics/answer/13331292), 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * If funnel report results are + * [sampled](https://support.google.com/analytics/answer/13331292), 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSamplingMetadatas() + { + return $this->sampling_metadatas; + } + + /** + * If funnel report results are + * [sampled](https://support.google.com/analytics/answer/13331292), 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; + * @param array<\Google\Analytics\Data\V1alpha\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSamplingMetadatas($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SamplingMetadata::class); + $this->sampling_metadatas = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php new file mode 100644 index 00000000000..bdb78764bf0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php @@ -0,0 +1,243 @@ +google.analytics.data.v1alpha.FunnelStep + */ +class FunnelStep extends \Google\Protobuf\Internal\Message +{ + /** + * The distinctive name for this step. If unspecified, steps will be named + * by a 1 based indexed name (for example "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. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * 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. + * + * Generated from protobuf field bool is_directly_followed_by = 2; + */ + protected $is_directly_followed_by = false; + /** + * 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. + * + * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; + */ + protected $within_duration_from_prior_step = null; + /** + * The condition that your users must meet to be included in this step of + * the funnel journey. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + */ + protected $filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The distinctive name for this step. If unspecified, steps will be named + * by a 1 based indexed name (for example "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. + * @type bool $is_directly_followed_by + * 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. + * @type \Google\Protobuf\Duration $within_duration_from_prior_step + * 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. + * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpression $filter_expression + * The condition that your users must meet to be included in this step of + * the funnel journey. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The distinctive name for this step. If unspecified, steps will be named + * by a 1 based indexed name (for example "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. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The distinctive name for this step. If unspecified, steps will be named + * by a 1 based indexed name (for example "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. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + 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. + * + * Generated from protobuf field bool is_directly_followed_by = 2; + * @return bool + */ + public function getIsDirectlyFollowedBy() + { + return $this->is_directly_followed_by; + } + + /** + * 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. + * + * Generated from protobuf field bool is_directly_followed_by = 2; + * @param bool $var + * @return $this + */ + public function setIsDirectlyFollowedBy($var) + { + GPBUtil::checkBool($var); + $this->is_directly_followed_by = $var; + + 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. + * + * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * @return \Google\Protobuf\Duration|null + */ + public function getWithinDurationFromPriorStep() + { + return $this->within_duration_from_prior_step; + } + + public function hasWithinDurationFromPriorStep() + { + return isset($this->within_duration_from_prior_step); + } + + public function clearWithinDurationFromPriorStep() + { + unset($this->within_duration_from_prior_step); + } + + /** + * 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. + * + * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setWithinDurationFromPriorStep($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->within_duration_from_prior_step = $var; + + return $this; + } + + /** + * The condition that your users must meet to be included in this step of + * the funnel journey. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpression|null + */ + public function getFilterExpression() + { + return $this->filter_expression; + } + + public function hasFilterExpression() + { + return isset($this->filter_expression); + } + + public function clearFilterExpression() + { + unset($this->filter_expression); + } + + /** + * The condition that your users must meet to be included in this step of + * the funnel journey. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; + * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpression $var + * @return $this + */ + public function setFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); + $this->filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php new file mode 100644 index 00000000000..917e5746235 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php @@ -0,0 +1,196 @@ +google.analytics.data.v1alpha.FunnelSubReport + */ +class FunnelSubReport extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + private $dimension_headers; + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + private $metric_headers; + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + private $rows; + /** + * Metadata for the funnel report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + */ + protected $metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers + * 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. + * @type array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers + * 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. + * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of dimension value combinations and metric values in the report. + * @type \Google\Analytics\Data\V1alpha\FunnelResponseMetadata $metadata + * Metadata for the funnel report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionHeaders() + { + return $this->dimension_headers; + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + * @param array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DimensionHeader::class); + $this->dimension_headers = $arr; + + 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricHeaders() + { + return $this->metric_headers; + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + * @param array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\MetricHeader::class); + $this->metric_headers = $arr; + + return $this; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); + $this->rows = $arr; + + return $this; + } + + /** + * Metadata for the funnel report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * @return \Google\Analytics\Data\V1alpha\FunnelResponseMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata for the funnel report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; + * @param \Google\Analytics\Data\V1alpha\FunnelResponseMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelResponseMetadata::class); + $this->metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php new file mode 100644 index 00000000000..b0b4e994fe0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php @@ -0,0 +1,86 @@ +google.analytics.data.v1alpha.GetAudienceListRequest + */ +class GetAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * Please see {@see AlphaAnalyticsDataClient::audienceListName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\GetAudienceListRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php new file mode 100644 index 00000000000..62483c22faa --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php @@ -0,0 +1,92 @@ +google.analytics.data.v1alpha.GetRecurringAudienceListRequest + */ +class GetRecurringAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * Please see {@see AlphaAnalyticsDataClient::recurringAudienceListName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\GetRecurringAudienceListRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php new file mode 100644 index 00000000000..b0bbbd7685c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php @@ -0,0 +1,86 @@ +google.analytics.data.v1alpha.GetReportTaskRequest + */ +class GetReportTaskRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * Please see {@see AlphaAnalyticsDataClient::reportTaskName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\GetReportTaskRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php new file mode 100644 index 00000000000..6a21d6edf15 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php @@ -0,0 +1,105 @@ +google.analytics.data.v1alpha.InListFilter + */ +class InListFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + */ + private $values; + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + */ + protected $case_sensitive = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $values + * The list of string values. + * Must be non-empty. + * @type bool $case_sensitive + * If true, the string value is case sensitive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getValues() + { + return $this->values; + } + + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->values = $arr; + + return $this; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + * @return bool + */ + public function getCaseSensitive() + { + return $this->case_sensitive; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + * @param bool $var + * @return $this + */ + public function setCaseSensitive($var) + { + GPBUtil::checkBool($var); + $this->case_sensitive = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php new file mode 100644 index 00000000000..f5a915fcf45 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php @@ -0,0 +1,178 @@ +google.analytics.data.v1alpha.ListAudienceListsRequest + */ +class ListAudienceListsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. The maximum number of audience lists to return. The service may + * return fewer than this value. If unspecified, at most 200 audience lists + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. A page token, received from a previous `ListAudienceLists` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceLists` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\ListAudienceListsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * @type int $page_size + * Optional. The maximum number of audience lists to return. The service may + * return fewer than this value. If unspecified, at most 200 audience lists + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * @type string $page_token + * Optional. A page token, received from a previous `ListAudienceLists` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceLists` must + * match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Optional. The maximum number of audience lists to return. The service may + * return fewer than this value. If unspecified, at most 200 audience lists + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The maximum number of audience lists to return. The service may + * return fewer than this value. If unspecified, at most 200 audience lists + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. A page token, received from a previous `ListAudienceLists` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceLists` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. A page token, received from a previous `ListAudienceLists` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceLists` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php new file mode 100644 index 00000000000..af435a8bb38 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php @@ -0,0 +1,115 @@ +google.analytics.data.v1alpha.ListAudienceListsResponse + */ +class ListAudienceListsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Each audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; + */ + private $audience_lists; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + */ + protected $next_page_token = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\AudienceList>|\Google\Protobuf\Internal\RepeatedField $audience_lists + * Each audience list for a property. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAudienceLists() + { + return $this->audience_lists; + } + + /** + * Each audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; + * @param array<\Google\Analytics\Data\V1alpha\AudienceList>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAudienceLists($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceList::class); + $this->audience_lists = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return isset($this->next_page_token) ? $this->next_page_token : ''; + } + + public function hasNextPageToken() + { + return isset($this->next_page_token); + } + + public function clearNextPageToken() + { + unset($this->next_page_token); + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php new file mode 100644 index 00000000000..c0ce897dbad --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php @@ -0,0 +1,186 @@ +google.analytics.data.v1alpha.ListRecurringAudienceListsRequest + */ +class ListRecurringAudienceListsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. The maximum number of recurring audience lists to return. The + * service may return fewer than this value. If unspecified, at most 200 + * recurring audience lists will be returned. The maximum value is 1000 + * (higher values will be coerced to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. A page token, received from a previous + * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent + * page. + * When paginating, all other parameters provided to + * `ListRecurringAudienceLists` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\ListRecurringAudienceListsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * @type int $page_size + * Optional. The maximum number of recurring audience lists to return. The + * service may return fewer than this value. If unspecified, at most 200 + * recurring audience lists will be returned. The maximum value is 1000 + * (higher values will be coerced to the maximum). + * @type string $page_token + * Optional. A page token, received from a previous + * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent + * page. + * When paginating, all other parameters provided to + * `ListRecurringAudienceLists` must match the call that provided the page + * token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Optional. The maximum number of recurring audience lists to return. The + * service may return fewer than this value. If unspecified, at most 200 + * recurring audience lists will be returned. The maximum value is 1000 + * (higher values will be coerced to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The maximum number of recurring audience lists to return. The + * service may return fewer than this value. If unspecified, at most 200 + * recurring audience lists will be returned. The maximum value is 1000 + * (higher values will be coerced to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. A page token, received from a previous + * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent + * page. + * When paginating, all other parameters provided to + * `ListRecurringAudienceLists` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. A page token, received from a previous + * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent + * page. + * When paginating, all other parameters provided to + * `ListRecurringAudienceLists` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php new file mode 100644 index 00000000000..0a48186323f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php @@ -0,0 +1,115 @@ +google.analytics.data.v1alpha.ListRecurringAudienceListsResponse + */ +class ListRecurringAudienceListsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Each recurring audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; + */ + private $recurring_audience_lists; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + */ + protected $next_page_token = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\RecurringAudienceList>|\Google\Protobuf\Internal\RepeatedField $recurring_audience_lists + * Each recurring audience list for a property. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each recurring audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRecurringAudienceLists() + { + return $this->recurring_audience_lists; + } + + /** + * Each recurring audience list for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; + * @param array<\Google\Analytics\Data\V1alpha\RecurringAudienceList>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRecurringAudienceLists($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\RecurringAudienceList::class); + $this->recurring_audience_lists = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return isset($this->next_page_token) ? $this->next_page_token : ''; + } + + public function hasNextPageToken() + { + return isset($this->next_page_token); + } + + public function clearNextPageToken() + { + unset($this->next_page_token); + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php new file mode 100644 index 00000000000..12429e405d1 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php @@ -0,0 +1,158 @@ +google.analytics.data.v1alpha.ListReportTasksRequest + */ +class ListReportTasksRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. The maximum number of report tasks to return. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. A page token, received from a previous `ListReportTasks` call. + * Provide this to retrieve the subsequent page. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\ListReportTasksRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * @type int $page_size + * Optional. The maximum number of report tasks to return. + * @type string $page_token + * Optional. A page token, received from a previous `ListReportTasks` call. + * Provide this to retrieve the subsequent page. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Optional. The maximum number of report tasks to return. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The maximum number of report tasks to return. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. A page token, received from a previous `ListReportTasks` call. + * Provide this to retrieve the subsequent page. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. A page token, received from a previous `ListReportTasks` call. + * Provide this to retrieve the subsequent page. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php new file mode 100644 index 00000000000..48be01c1d7a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php @@ -0,0 +1,115 @@ +google.analytics.data.v1alpha.ListReportTasksResponse + */ +class ListReportTasksResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Each report task for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ReportTask report_tasks = 1; + */ + private $report_tasks; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + */ + protected $next_page_token = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\ReportTask>|\Google\Protobuf\Internal\RepeatedField $report_tasks + * Each report task for a property. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each report task for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ReportTask report_tasks = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getReportTasks() + { + return $this->report_tasks; + } + + /** + * Each report task for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ReportTask report_tasks = 1; + * @param array<\Google\Analytics\Data\V1alpha\ReportTask>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setReportTasks($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\ReportTask::class); + $this->report_tasks = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return isset($this->next_page_token) ? $this->next_page_token : ''; + } + + public function hasNextPageToken() + { + return isset($this->next_page_token); + } + + public function clearNextPageToken() + { + unset($this->next_page_token); + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php new file mode 100644 index 00000000000..87da0af9af0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php @@ -0,0 +1,221 @@ +google.analytics.data.v1alpha.Metric + */ +class Metric extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + */ + protected $expression = ''; + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + */ + protected $invisible = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * @type string $expression + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * @type bool $invisible + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + * @return string + */ + public function getExpression() + { + return $this->expression; + } + + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + * @param string $var + * @return $this + */ + public function setExpression($var) + { + GPBUtil::checkString($var, True); + $this->expression = $var; + + return $this; + } + + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + * @return bool + */ + public function getInvisible() + { + return $this->invisible; + } + + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + * @param bool $var + * @return $this + */ + public function setInvisible($var) + { + GPBUtil::checkBool($var); + $this->invisible = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php new file mode 100644 index 00000000000..941961ccf25 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php @@ -0,0 +1,75 @@ +google.analytics.data.v1alpha.MetricAggregation + */ +class MetricAggregation +{ + /** + * Unspecified operator. + * + * Generated from protobuf enum METRIC_AGGREGATION_UNSPECIFIED = 0; + */ + const METRIC_AGGREGATION_UNSPECIFIED = 0; + /** + * SUM operator. + * + * Generated from protobuf enum TOTAL = 1; + */ + const TOTAL = 1; + /** + * Minimum operator. + * + * Generated from protobuf enum MINIMUM = 5; + */ + const MINIMUM = 5; + /** + * Maximum operator. + * + * Generated from protobuf enum MAXIMUM = 6; + */ + const MAXIMUM = 6; + /** + * Count operator. + * + * Generated from protobuf enum COUNT = 4; + */ + const COUNT = 4; + + private static $valueToName = [ + self::METRIC_AGGREGATION_UNSPECIFIED => 'METRIC_AGGREGATION_UNSPECIFIED', + self::TOTAL => 'TOTAL', + self::MINIMUM => 'MINIMUM', + self::MAXIMUM => 'MAXIMUM', + self::COUNT => 'COUNT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php new file mode 100644 index 00000000000..ed4f1ecb9a8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php @@ -0,0 +1,104 @@ +google.analytics.data.v1alpha.MetricHeader + */ +class MetricHeader extends \Google\Protobuf\Internal\Message +{ + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; + */ + protected $type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The metric's name. + * @type int $type + * The metric's data type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\MetricType::class); + $this->type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php new file mode 100644 index 00000000000..8dc85c6cf15 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php @@ -0,0 +1,131 @@ +google.analytics.data.v1alpha.MetricType + */ +class MetricType +{ + /** + * Unspecified type. + * + * Generated from protobuf enum METRIC_TYPE_UNSPECIFIED = 0; + */ + const METRIC_TYPE_UNSPECIFIED = 0; + /** + * Integer type. + * + * Generated from protobuf enum TYPE_INTEGER = 1; + */ + const TYPE_INTEGER = 1; + /** + * Floating point type. + * + * Generated from protobuf enum TYPE_FLOAT = 2; + */ + const TYPE_FLOAT = 2; + /** + * A duration of seconds; a special floating point type. + * + * Generated from protobuf enum TYPE_SECONDS = 4; + */ + const TYPE_SECONDS = 4; + /** + * A duration in milliseconds; a special floating point type. + * + * Generated from protobuf enum TYPE_MILLISECONDS = 5; + */ + const TYPE_MILLISECONDS = 5; + /** + * A duration in minutes; a special floating point type. + * + * Generated from protobuf enum TYPE_MINUTES = 6; + */ + const TYPE_MINUTES = 6; + /** + * A duration in hours; a special floating point type. + * + * Generated from protobuf enum TYPE_HOURS = 7; + */ + const TYPE_HOURS = 7; + /** + * A custom metric of standard type; a special floating point type. + * + * Generated from protobuf enum TYPE_STANDARD = 8; + */ + const TYPE_STANDARD = 8; + /** + * An amount of money; a special floating point type. + * + * Generated from protobuf enum TYPE_CURRENCY = 9; + */ + const TYPE_CURRENCY = 9; + /** + * A length in feet; a special floating point type. + * + * Generated from protobuf enum TYPE_FEET = 10; + */ + const TYPE_FEET = 10; + /** + * A length in miles; a special floating point type. + * + * Generated from protobuf enum TYPE_MILES = 11; + */ + const TYPE_MILES = 11; + /** + * A length in meters; a special floating point type. + * + * Generated from protobuf enum TYPE_METERS = 12; + */ + const TYPE_METERS = 12; + /** + * A length in kilometers; a special floating point type. + * + * Generated from protobuf enum TYPE_KILOMETERS = 13; + */ + const TYPE_KILOMETERS = 13; + + private static $valueToName = [ + self::METRIC_TYPE_UNSPECIFIED => 'METRIC_TYPE_UNSPECIFIED', + self::TYPE_INTEGER => 'TYPE_INTEGER', + self::TYPE_FLOAT => 'TYPE_FLOAT', + self::TYPE_SECONDS => 'TYPE_SECONDS', + self::TYPE_MILLISECONDS => 'TYPE_MILLISECONDS', + self::TYPE_MINUTES => 'TYPE_MINUTES', + self::TYPE_HOURS => 'TYPE_HOURS', + self::TYPE_STANDARD => 'TYPE_STANDARD', + self::TYPE_CURRENCY => 'TYPE_CURRENCY', + self::TYPE_FEET => 'TYPE_FEET', + self::TYPE_MILES => 'TYPE_MILES', + self::TYPE_METERS => 'TYPE_METERS', + self::TYPE_KILOMETERS => 'TYPE_KILOMETERS', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php new file mode 100644 index 00000000000..4abe417e906 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1alpha.MetricValue + */ +class MetricValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Measurement value. See MetricHeader for type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Measurement value. See MetricHeader for type. + * + * Generated from protobuf field string value = 4; + * @return string + */ + public function getValue() + { + return $this->readOneof(4); + } + + public function hasValue() + { + return $this->hasOneof(4); + } + + /** + * Measurement value. See MetricHeader for type. + * + * Generated from protobuf field string value = 4; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php new file mode 100644 index 00000000000..6a6fb83e34e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php @@ -0,0 +1,111 @@ +google.analytics.data.v1alpha.NumericFilter + */ +class NumericFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + */ + protected $operation = 0; + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; + */ + protected $value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $operation + * The operation type for this filter. + * @type \Google\Analytics\Data\V1alpha\NumericValue $value + * A numeric value or a date value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * @return int + */ + public function getOperation() + { + return $this->operation; + } + + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; + * @param int $var + * @return $this + */ + public function setOperation($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\NumericFilter\Operation::class); + $this->operation = $var; + + return $this; + } + + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; + * @return \Google\Analytics\Data\V1alpha\NumericValue|null + */ + public function getValue() + { + return $this->value; + } + + public function hasValue() + { + return isset($this->value); + } + + public function clearValue() + { + unset($this->value); + } + + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; + * @param \Google\Analytics\Data\V1alpha\NumericValue $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php new file mode 100644 index 00000000000..90f4da5651e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php @@ -0,0 +1,85 @@ +google.analytics.data.v1alpha.NumericFilter.Operation + */ +class Operation +{ + /** + * Unspecified. + * + * Generated from protobuf enum OPERATION_UNSPECIFIED = 0; + */ + const OPERATION_UNSPECIFIED = 0; + /** + * Equal + * + * Generated from protobuf enum EQUAL = 1; + */ + const EQUAL = 1; + /** + * Less than + * + * Generated from protobuf enum LESS_THAN = 2; + */ + const LESS_THAN = 2; + /** + * Less than or equal + * + * Generated from protobuf enum LESS_THAN_OR_EQUAL = 3; + */ + const LESS_THAN_OR_EQUAL = 3; + /** + * Greater than + * + * Generated from protobuf enum GREATER_THAN = 4; + */ + const GREATER_THAN = 4; + /** + * Greater than or equal + * + * Generated from protobuf enum GREATER_THAN_OR_EQUAL = 5; + */ + const GREATER_THAN_OR_EQUAL = 5; + + private static $valueToName = [ + self::OPERATION_UNSPECIFIED => 'OPERATION_UNSPECIFIED', + self::EQUAL => 'EQUAL', + self::LESS_THAN => 'LESS_THAN', + self::LESS_THAN_OR_EQUAL => 'LESS_THAN_OR_EQUAL', + self::GREATER_THAN => 'GREATER_THAN', + self::GREATER_THAN_OR_EQUAL => 'GREATER_THAN_OR_EQUAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Operation::class, \Google\Analytics\Data\V1alpha\NumericFilter_Operation::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php new file mode 100644 index 00000000000..58236fe2e88 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php @@ -0,0 +1,108 @@ +google.analytics.data.v1alpha.NumericValue + */ +class NumericValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $int64_value + * Integer value + * @type float $double_value + * Double value + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Integer value + * + * Generated from protobuf field int64 int64_value = 1; + * @return int|string + */ + public function getInt64Value() + { + return $this->readOneof(1); + } + + public function hasInt64Value() + { + return $this->hasOneof(1); + } + + /** + * Integer value + * + * Generated from protobuf field int64 int64_value = 1; + * @param int|string $var + * @return $this + */ + public function setInt64Value($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Double value + * + * Generated from protobuf field double double_value = 2; + * @return float + */ + public function getDoubleValue() + { + return $this->readOneof(2); + } + + public function hasDoubleValue() + { + return $this->hasOneof(2); + } + + /** + * Double value + * + * Generated from protobuf field double double_value = 2; + * @param float $var + * @return $this + */ + public function setDoubleValue($var) + { + GPBUtil::checkDouble($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php new file mode 100644 index 00000000000..957ad52e335 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php @@ -0,0 +1,144 @@ +google.analytics.data.v1alpha.OrderBy + */ +class OrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + */ + protected $desc = false; + protected $one_order_by; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy $metric + * Sorts results by a metric's values. + * @type \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy $dimension + * Sorts results by a dimension's values. + * @type bool $desc + * If true, sorts by descending order. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Sorts results by a metric's values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.MetricOrderBy metric = 1; + * @return \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy|null + */ + public function getMetric() + { + return $this->readOneof(1); + } + + public function hasMetric() + { + return $this->hasOneof(1); + } + + /** + * Sorts results by a metric's values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.MetricOrderBy metric = 1; + * @param \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy $var + * @return $this + */ + public function setMetric($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Sorts results by a dimension's values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy dimension = 2; + * @return \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy|null + */ + public function getDimension() + { + return $this->readOneof(2); + } + + public function hasDimension() + { + return $this->hasOneof(2); + } + + /** + * Sorts results by a dimension's values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy dimension = 2; + * @param \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy $var + * @return $this + */ + public function setDimension($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + * @return bool + */ + public function getDesc() + { + return $this->desc; + } + + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + * @param bool $var + * @return $this + */ + public function setDesc($var) + { + GPBUtil::checkBool($var); + $this->desc = $var; + + return $this; + } + + /** + * @return string + */ + public function getOneOrderBy() + { + return $this->whichOneof("one_order_by"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php new file mode 100644 index 00000000000..e660e209cf8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php @@ -0,0 +1,104 @@ +google.analytics.data.v1alpha.OrderBy.DimensionOrderBy + */ +class DimensionOrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + */ + protected $dimension_name = ''; + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; + */ + protected $order_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * A dimension name in the request to order by. + * @type int $order_type + * Controls the rule for dimension value ordering. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; + * @return int + */ + public function getOrderType() + { + return $this->order_type; + } + + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; + * @param int $var + * @return $this + */ + public function setOrderType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy\OrderType::class); + $this->order_type = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DimensionOrderBy::class, \Google\Analytics\Data\V1alpha\OrderBy_DimensionOrderBy::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php new file mode 100644 index 00000000000..002c3d3b1f4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php @@ -0,0 +1,76 @@ +google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType + */ +class OrderType +{ + /** + * Unspecified. + * + * Generated from protobuf enum ORDER_TYPE_UNSPECIFIED = 0; + */ + const ORDER_TYPE_UNSPECIFIED = 0; + /** + * Alphanumeric sort by Unicode code point. For example, "2" < "A" < "X" < + * "b" < "z". + * + * Generated from protobuf enum ALPHANUMERIC = 1; + */ + const ALPHANUMERIC = 1; + /** + * Case insensitive alphanumeric sort by lower case Unicode code point. + * For example, "2" < "A" < "b" < "X" < "z". + * + * Generated from protobuf enum CASE_INSENSITIVE_ALPHANUMERIC = 2; + */ + const CASE_INSENSITIVE_ALPHANUMERIC = 2; + /** + * Dimension values are converted to numbers before sorting. For example + * in NUMERIC sort, "25" < "100", and in `ALPHANUMERIC` sort, "100" < + * "25". Non-numeric dimension values all have equal ordering value below + * all numeric values. + * + * Generated from protobuf enum NUMERIC = 3; + */ + const NUMERIC = 3; + + private static $valueToName = [ + self::ORDER_TYPE_UNSPECIFIED => 'ORDER_TYPE_UNSPECIFIED', + self::ALPHANUMERIC => 'ALPHANUMERIC', + self::CASE_INSENSITIVE_ALPHANUMERIC => 'CASE_INSENSITIVE_ALPHANUMERIC', + self::NUMERIC => 'NUMERIC', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(OrderType::class, \Google\Analytics\Data\V1alpha\OrderBy_DimensionOrderBy_OrderType::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php new file mode 100644 index 00000000000..7d209774985 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php @@ -0,0 +1,70 @@ +google.analytics.data.v1alpha.OrderBy.MetricOrderBy + */ +class MetricOrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + */ + protected $metric_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $metric_name + * A metric name in the request to order by. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + * @return string + */ + public function getMetricName() + { + return $this->metric_name; + } + + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + * @param string $var + * @return $this + */ + public function setMetricName($var) + { + GPBUtil::checkString($var, True); + $this->metric_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MetricOrderBy::class, \Google\Analytics\Data\V1alpha\OrderBy_MetricOrderBy::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php new file mode 100644 index 00000000000..37c205d8251 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php @@ -0,0 +1,363 @@ +google.analytics.data.v1alpha.PropertyQuota + */ +class PropertyQuota extends \Google\Protobuf\Internal\Message +{ + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + */ + protected $tokens_per_day = null; + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + */ + protected $tokens_per_hour = null; + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + */ + protected $concurrent_requests = 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + */ + protected $server_errors_per_project_per_hour = 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + */ + protected $potentially_thresholded_requests_per_hour = null; + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; + */ + protected $tokens_per_project_per_hour = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_day + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_hour + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $concurrent_requests + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $server_errors_per_project_per_hour + * 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. + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $potentially_thresholded_requests_per_hour + * 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. + * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_project_per_hour + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getTokensPerDay() + { + return $this->tokens_per_day; + } + + public function hasTokensPerDay() + { + return isset($this->tokens_per_day); + } + + public function clearTokensPerDay() + { + unset($this->tokens_per_day); + } + + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setTokensPerDay($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->tokens_per_day = $var; + + return $this; + } + + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getTokensPerHour() + { + return $this->tokens_per_hour; + } + + public function hasTokensPerHour() + { + return isset($this->tokens_per_hour); + } + + public function clearTokensPerHour() + { + unset($this->tokens_per_hour); + } + + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setTokensPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->tokens_per_hour = $var; + + return $this; + } + + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getConcurrentRequests() + { + return $this->concurrent_requests; + } + + public function hasConcurrentRequests() + { + return isset($this->concurrent_requests); + } + + public function clearConcurrentRequests() + { + unset($this->concurrent_requests); + } + + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setConcurrentRequests($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->concurrent_requests = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getServerErrorsPerProjectPerHour() + { + return $this->server_errors_per_project_per_hour; + } + + public function hasServerErrorsPerProjectPerHour() + { + return isset($this->server_errors_per_project_per_hour); + } + + public function clearServerErrorsPerProjectPerHour() + { + unset($this->server_errors_per_project_per_hour); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setServerErrorsPerProjectPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->server_errors_per_project_per_hour = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getPotentiallyThresholdedRequestsPerHour() + { + return $this->potentially_thresholded_requests_per_hour; + } + + public function hasPotentiallyThresholdedRequestsPerHour() + { + return isset($this->potentially_thresholded_requests_per_hour); + } + + public function clearPotentiallyThresholdedRequestsPerHour() + { + unset($this->potentially_thresholded_requests_per_hour); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setPotentiallyThresholdedRequestsPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->potentially_thresholded_requests_per_hour = $var; + + return $this; + } + + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; + * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null + */ + public function getTokensPerProjectPerHour() + { + return $this->tokens_per_project_per_hour; + } + + public function hasTokensPerProjectPerHour() + { + return isset($this->tokens_per_project_per_hour); + } + + public function clearTokensPerProjectPerHour() + { + unset($this->tokens_per_project_per_hour); + } + + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; + * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var + * @return $this + */ + public function setTokensPerProjectPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); + $this->tokens_per_project_per_hour = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php new file mode 100644 index 00000000000..1e552270bd7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php @@ -0,0 +1,205 @@ +google.analytics.data.v1alpha.QueryAudienceListRequest + */ +class QueryAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $name = ''; + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $offset = 0; + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + + /** + * @param string $name Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * @return \Google\Analytics\Data\V1alpha\QueryAudienceListRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @type int|string $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int|string $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php new file mode 100644 index 00000000000..34eacd07d7f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php @@ -0,0 +1,191 @@ +google.analytics.data.v1alpha.QueryAudienceListResponse + */ +class QueryAudienceListResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Configuration data about AudienceList being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceList correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; + */ + protected $audience_list = null; + /** + * Rows for each user in an audience list. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; + */ + private $audience_rows; + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + */ + protected $row_count = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list + * Configuration data about AudienceList being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceList correspond to the columns in the AudienceRows. + * @type array<\Google\Analytics\Data\V1alpha\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $audience_rows + * Rows for each user in an audience list. The number of rows in this + * response will be less than or equal to request's page size. + * @type int $row_count + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Configuration data about AudienceList being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceList correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; + * @return \Google\Analytics\Data\V1alpha\AudienceList|null + */ + public function getAudienceList() + { + return $this->audience_list; + } + + public function hasAudienceList() + { + return isset($this->audience_list); + } + + public function clearAudienceList() + { + unset($this->audience_list); + } + + /** + * Configuration data about AudienceList being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceList correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; + * @param \Google\Analytics\Data\V1alpha\AudienceList $var + * @return $this + */ + public function setAudienceList($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); + $this->audience_list = $var; + + return $this; + } + + /** + * Rows for each user in an audience list. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAudienceRows() + { + return $this->audience_rows; + } + + /** + * Rows for each user in an audience list. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; + * @param array<\Google\Analytics\Data\V1alpha\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAudienceRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceRow::class); + $this->audience_rows = $arr; + + return $this; + } + + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @return int + */ + public function getRowCount() + { + return isset($this->row_count) ? $this->row_count : 0; + } + + public function hasRowCount() + { + return isset($this->row_count); + } + + public function clearRowCount() + { + unset($this->row_count); + } + + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php new file mode 100644 index 00000000000..17ab1b591dc --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php @@ -0,0 +1,225 @@ +google.analytics.data.v1alpha.QueryReportTaskRequest + */ +class QueryReportTaskRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $name = ''; + /** + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $offset = 0; + /** + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + + /** + * @param string $name Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * + * @return \Google\Analytics\Data\V1alpha\QueryReportTaskRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * @type int|string $offset + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int|string $limit + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php new file mode 100644 index 00000000000..cc6ed351abc --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php @@ -0,0 +1,323 @@ +google.analytics.data.v1alpha.QueryReportTaskResponse + */ +class QueryReportTaskResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + */ + private $dimension_headers; + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + */ + private $metric_headers; + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + */ + private $rows; + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row totals = 4; + */ + private $totals; + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row maximums = 5; + */ + private $maximums; + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row minimums = 6; + */ + private $minimums; + /** + * The total number of rows in the query result. + * + * Generated from protobuf field int32 row_count = 7; + */ + protected $row_count = 0; + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ResponseMetaData metadata = 8; + */ + protected $metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * @type array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of dimension value combinations and metric values in the report. + * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $totals + * If requested, the totaled values of metrics. + * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $maximums + * If requested, the maximum values of metrics. + * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $minimums + * If requested, the minimum values of metrics. + * @type int $row_count + * The total number of rows in the query result. + * @type \Google\Analytics\Data\V1alpha\ResponseMetaData $metadata + * Metadata for the report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionHeaders() + { + return $this->dimension_headers; + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; + * @param array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DimensionHeader::class); + $this->dimension_headers = $arr; + + return $this; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricHeaders() + { + return $this->metric_headers; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; + * @param array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\MetricHeader::class); + $this->metric_headers = $arr; + + return $this; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; + * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); + $this->rows = $arr; + + return $this; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row totals = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTotals() + { + return $this->totals; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row totals = 4; + * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTotals($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); + $this->totals = $arr; + + return $this; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row maximums = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaximums() + { + return $this->maximums; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row maximums = 5; + * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaximums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); + $this->maximums = $arr; + + return $this; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row minimums = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMinimums() + { + return $this->minimums; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row minimums = 6; + * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMinimums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); + $this->minimums = $arr; + + return $this; + } + + /** + * The total number of rows in the query result. + * + * Generated from protobuf field int32 row_count = 7; + * @return int + */ + public function getRowCount() + { + return $this->row_count; + } + + /** + * The total number of rows in the query result. + * + * Generated from protobuf field int32 row_count = 7; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ResponseMetaData metadata = 8; + * @return \Google\Analytics\Data\V1alpha\ResponseMetaData|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ResponseMetaData metadata = 8; + * @param \Google\Analytics\Data\V1alpha\ResponseMetaData $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ResponseMetaData::class); + $this->metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php new file mode 100644 index 00000000000..d0e52585a08 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php @@ -0,0 +1,101 @@ +google.analytics.data.v1alpha.QuotaStatus + */ +class QuotaStatus extends \Google\Protobuf\Internal\Message +{ + /** + * Quota consumed by this request. + * + * Generated from protobuf field int32 consumed = 1; + */ + protected $consumed = 0; + /** + * Quota remaining after this request. + * + * Generated from protobuf field int32 remaining = 2; + */ + protected $remaining = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $consumed + * Quota consumed by this request. + * @type int $remaining + * Quota remaining after this request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Quota consumed by this request. + * + * Generated from protobuf field int32 consumed = 1; + * @return int + */ + public function getConsumed() + { + return $this->consumed; + } + + /** + * Quota consumed by this request. + * + * Generated from protobuf field int32 consumed = 1; + * @param int $var + * @return $this + */ + public function setConsumed($var) + { + GPBUtil::checkInt32($var); + $this->consumed = $var; + + return $this; + } + + /** + * Quota remaining after this request. + * + * Generated from protobuf field int32 remaining = 2; + * @return int + */ + public function getRemaining() + { + return $this->remaining; + } + + /** + * Quota remaining after this request. + * + * Generated from protobuf field int32 remaining = 2; + * @param int $var + * @return $this + */ + public function setRemaining($var) + { + GPBUtil::checkInt32($var); + $this->remaining = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php new file mode 100644 index 00000000000..39bf5024667 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php @@ -0,0 +1,410 @@ +google.analytics.data.v1alpha.RecurringAudienceList + */ +class RecurringAudienceList extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The recurring audience list resource name assigned + * during creation. This resource name identifies this + * `RecurringAudienceList`. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $audience = ''; + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $audience_display_name = ''; + /** + * Required. The dimensions requested and displayed in the audience list + * response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + private $dimensions; + /** + * Optional. The number of remaining days that a recurring audience export + * will produce an audience list instance. This counter decreases by one each + * day, and when it reaches zero, no new audience lists will be created. + * Recurring audience list request for Analytics 360 properties default to 180 + * days and have a maximum of 365 days. Requests for standard Analytics + * properties default to 14 days and have a maximum of 30 days. + * The minimum value allowed during creation is 1. Requests above their + * respective maximum will be coerced to their maximum. + * + * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $active_days_remaining = null; + /** + * Output only. Audience list resource names for audience list instances + * created for this recurring audience list. One audience list is created for + * each day, and the audience list will be listed here. + * This list is ordered with the most recently created audience list first. + * + * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $audience_lists; + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when a recurring audience + * list creates new audience lists. Webhooks allow a notification to be sent + * to your servers & avoid the need for polling. + * Two POST requests will be sent each time a recurring audience list creates + * an audience list. This happens once per day until a recurring audience list + * reaches 0 active days remaining. The first request will be sent showing a + * newly created audience list in its CREATING state. The second request will + * be sent after the audience list completes creation (either the ACTIVE or + * FAILED state). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $webhook_notification = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The recurring audience list resource name assigned + * during creation. This resource name identifies this + * `RecurringAudienceList`. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * @type string $audience + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * @type string $audience_display_name + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * @type array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * Required. The dimensions requested and displayed in the audience list + * response. + * @type int $active_days_remaining + * Optional. The number of remaining days that a recurring audience export + * will produce an audience list instance. This counter decreases by one each + * day, and when it reaches zero, no new audience lists will be created. + * Recurring audience list request for Analytics 360 properties default to 180 + * days and have a maximum of 365 days. Requests for standard Analytics + * properties default to 14 days and have a maximum of 30 days. + * The minimum value allowed during creation is 1. Requests above their + * respective maximum will be coerced to their maximum. + * @type array|\Google\Protobuf\Internal\RepeatedField $audience_lists + * Output only. Audience list resource names for audience list instances + * created for this recurring audience list. One audience list is created for + * each day, and the audience list will be listed here. + * This list is ordered with the most recently created audience list first. + * @type \Google\Analytics\Data\V1alpha\WebhookNotification $webhook_notification + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when a recurring audience + * list creates new audience lists. Webhooks allow a notification to be sent + * to your servers & avoid the need for polling. + * Two POST requests will be sent each time a recurring audience list creates + * an audience list. This happens once per day until a recurring audience list + * reaches 0 active days remaining. The first request will be sent showing a + * newly created audience list in its CREATING state. The second request will + * be sent after the audience list completes creation (either the ACTIVE or + * FAILED state). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The recurring audience list resource name assigned + * during creation. This resource name identifies this + * `RecurringAudienceList`. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The recurring audience list resource name assigned + * during creation. This resource name identifies this + * `RecurringAudienceList`. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getAudience() + { + return $this->audience; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setAudience($var) + { + GPBUtil::checkString($var, True); + $this->audience = $var; + + return $this; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getAudienceDisplayName() + { + return $this->audience_display_name; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setAudienceDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->audience_display_name = $var; + + return $this; + } + + /** + * Required. The dimensions requested and displayed in the audience list + * response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * Required. The dimensions requested and displayed in the audience list + * response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * Optional. The number of remaining days that a recurring audience export + * will produce an audience list instance. This counter decreases by one each + * day, and when it reaches zero, no new audience lists will be created. + * Recurring audience list request for Analytics 360 properties default to 180 + * days and have a maximum of 365 days. Requests for standard Analytics + * properties default to 14 days and have a maximum of 30 days. + * The minimum value allowed during creation is 1. Requests above their + * respective maximum will be coerced to their maximum. + * + * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getActiveDaysRemaining() + { + return isset($this->active_days_remaining) ? $this->active_days_remaining : 0; + } + + public function hasActiveDaysRemaining() + { + return isset($this->active_days_remaining); + } + + public function clearActiveDaysRemaining() + { + unset($this->active_days_remaining); + } + + /** + * Optional. The number of remaining days that a recurring audience export + * will produce an audience list instance. This counter decreases by one each + * day, and when it reaches zero, no new audience lists will be created. + * Recurring audience list request for Analytics 360 properties default to 180 + * days and have a maximum of 365 days. Requests for standard Analytics + * properties default to 14 days and have a maximum of 30 days. + * The minimum value allowed during creation is 1. Requests above their + * respective maximum will be coerced to their maximum. + * + * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setActiveDaysRemaining($var) + { + GPBUtil::checkInt32($var); + $this->active_days_remaining = $var; + + return $this; + } + + /** + * Output only. Audience list resource names for audience list instances + * created for this recurring audience list. One audience list is created for + * each day, and the audience list will be listed here. + * This list is ordered with the most recently created audience list first. + * + * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAudienceLists() + { + return $this->audience_lists; + } + + /** + * Output only. Audience list resource names for audience list instances + * created for this recurring audience list. One audience list is created for + * each day, and the audience list will be listed here. + * This list is ordered with the most recently created audience list first. + * + * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAudienceLists($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->audience_lists = $arr; + + return $this; + } + + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when a recurring audience + * list creates new audience lists. Webhooks allow a notification to be sent + * to your servers & avoid the need for polling. + * Two POST requests will be sent each time a recurring audience list creates + * an audience list. This happens once per day until a recurring audience list + * reaches 0 active days remaining. The first request will be sent showing a + * newly created audience list in its CREATING state. The second request will + * be sent after the audience list completes creation (either the ACTIVE or + * FAILED state). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\WebhookNotification|null + */ + public function getWebhookNotification() + { + return $this->webhook_notification; + } + + public function hasWebhookNotification() + { + return isset($this->webhook_notification); + } + + public function clearWebhookNotification() + { + unset($this->webhook_notification); + } + + /** + * Optional. Configures webhook notifications to be sent from the Google + * Analytics Data API to your webhook server. Use of webhooks is optional. If + * unused, you'll need to poll this API to determine when a recurring audience + * list creates new audience lists. Webhooks allow a notification to be sent + * to your servers & avoid the need for polling. + * Two POST requests will be sent each time a recurring audience list creates + * an audience list. This happens once per day until a recurring audience list + * reaches 0 active days remaining. The first request will be sent showing a + * newly created audience list in its CREATING state. The second request will + * be sent after the audience list completes creation (either the ACTIVE or + * FAILED state). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\WebhookNotification $var + * @return $this + */ + public function setWebhookNotification($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\WebhookNotification::class); + $this->webhook_notification = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php new file mode 100644 index 00000000000..91c9e39f72b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php @@ -0,0 +1,183 @@ +google.analytics.data.v1alpha.ReportTask + */ +class ReportTask extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The report task resource name assigned during + * creation. Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Optional. A report definition to fetch report data, which describes the + * structure of a report. It typically includes the fields that will be + * included in the report and the criteria that will be used to filter the + * data. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportDefinition report_definition = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $report_definition = null; + /** + * Output only. The report metadata for a specific report task, which provides + * information about a report. It typically includes the following + * information: the resource name of the report, the state of the report, the + * timestamp the report was created, etc, + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportMetadata report_metadata = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $report_metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The report task resource name assigned during + * creation. Format: `properties/{property}/reportTasks/{report_task}` + * @type \Google\Analytics\Data\V1alpha\ReportTask\ReportDefinition $report_definition + * Optional. A report definition to fetch report data, which describes the + * structure of a report. It typically includes the fields that will be + * included in the report and the criteria that will be used to filter the + * data. + * @type \Google\Analytics\Data\V1alpha\ReportTask\ReportMetadata $report_metadata + * Output only. The report metadata for a specific report task, which provides + * information about a report. It typically includes the following + * information: the resource name of the report, the state of the report, the + * timestamp the report was created, etc, + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The report task resource name assigned during + * creation. Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The report task resource name assigned during + * creation. Format: `properties/{property}/reportTasks/{report_task}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. A report definition to fetch report data, which describes the + * structure of a report. It typically includes the fields that will be + * included in the report and the criteria that will be used to filter the + * data. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportDefinition report_definition = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\ReportTask\ReportDefinition|null + */ + public function getReportDefinition() + { + return $this->report_definition; + } + + public function hasReportDefinition() + { + return isset($this->report_definition); + } + + public function clearReportDefinition() + { + unset($this->report_definition); + } + + /** + * Optional. A report definition to fetch report data, which describes the + * structure of a report. It typically includes the fields that will be + * included in the report and the criteria that will be used to filter the + * data. + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportDefinition report_definition = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\ReportTask\ReportDefinition $var + * @return $this + */ + public function setReportDefinition($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ReportTask\ReportDefinition::class); + $this->report_definition = $var; + + return $this; + } + + /** + * Output only. The report metadata for a specific report task, which provides + * information about a report. It typically includes the following + * information: the resource name of the report, the state of the report, the + * timestamp the report was created, etc, + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportMetadata report_metadata = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Analytics\Data\V1alpha\ReportTask\ReportMetadata|null + */ + public function getReportMetadata() + { + return $this->report_metadata; + } + + public function hasReportMetadata() + { + return isset($this->report_metadata); + } + + public function clearReportMetadata() + { + unset($this->report_metadata); + } + + /** + * Output only. The report metadata for a specific report task, which provides + * information about a report. It typically includes the following + * information: the resource name of the report, the state of the report, the + * timestamp the report was created, etc, + * + * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportMetadata report_metadata = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Analytics\Data\V1alpha\ReportTask\ReportMetadata $var + * @return $this + */ + public function setReportMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ReportTask\ReportMetadata::class); + $this->report_metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php new file mode 100644 index 00000000000..5eaf6627192 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php @@ -0,0 +1,614 @@ +google.analytics.data.v1alpha.ReportTask.ReportDefinition + */ +class ReportDefinition extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Dimension dimensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $dimensions; + /** + * Optional. The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Metric metrics = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $metrics; + /** + * Optional. 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. In a cohort request, + * this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $date_ranges; + /** + * Optional. Dimension filters let you ask for only specific dimension + * values in the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $dimension_filter = null; + /** + * Optional. The filter clause of metrics. Applied after aggregating the + * report's rows, similar to SQL having-clause. Dimensions cannot be used in + * this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression metric_filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $metric_filter = null; + /** + * Optional. The row count of the start row from Google Analytics Storage. + * The first row is counted as row 0. + * When creating a report task, the `offset` and `limit` parameters define + * the subset of data rows from Google Analytics storage to be included in + * the generated report. For example, if there are a total of 300,000 rows + * in Google Analytics storage, the initial report task may have the + * first 10,000 rows with a limit of 10,000 and an offset of 0. + * Subsequently, another report task could cover the next 10,000 rows with a + * limit of 10,000 and an offset of 10,000. + * + * Generated from protobuf field int64 offset = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $offset = 0; + /** + * Optional. The number of rows to return in the Report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if + * you set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + /** + * Optional. Aggregation of metrics. Aggregated metric values will be shown + * in rows where the dimension_values are set to + * "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricAggregation metric_aggregations = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $metric_aggregations; + /** + * Optional. Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.OrderBy order_bys = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $order_bys; + /** + * Optional. A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $currency_code = ''; + /** + * Optional. Cohort group associated with this request. If there is a cohort + * group in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortSpec cohort_spec = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $cohort_spec = null; + /** + * Optional. If false or unspecified, each row with all metrics equal to 0 + * will not be returned. If true, these rows will be returned if they are + * not separately removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * containing eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $keep_empty_rows = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * Optional. The dimensions requested and displayed. + * @type array<\Google\Analytics\Data\V1alpha\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics + * Optional. The metrics requested and displayed. + * @type array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges + * Optional. 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. In a cohort request, + * this `dateRanges` must be unspecified. + * @type \Google\Analytics\Data\V1alpha\FilterExpression $dimension_filter + * Optional. Dimension filters let you ask for only specific dimension + * values in the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * @type \Google\Analytics\Data\V1alpha\FilterExpression $metric_filter + * Optional. The filter clause of metrics. Applied after aggregating the + * report's rows, similar to SQL having-clause. Dimensions cannot be used in + * this filter. + * @type int|string $offset + * Optional. The row count of the start row from Google Analytics Storage. + * The first row is counted as row 0. + * When creating a report task, the `offset` and `limit` parameters define + * the subset of data rows from Google Analytics storage to be included in + * the generated report. For example, if there are a total of 300,000 rows + * in Google Analytics storage, the initial report task may have the + * first 10,000 rows with a limit of 10,000 and an offset of 0. + * Subsequently, another report task could cover the next 10,000 rows with a + * limit of 10,000 and an offset of 10,000. + * @type int|string $limit + * Optional. The number of rows to return in the Report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if + * you set `limit` to a higher value. + * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations + * Optional. Aggregation of metrics. Aggregated metric values will be shown + * in rows where the dimension_values are set to + * "RESERVED_(MetricAggregation)". + * @type array<\Google\Analytics\Data\V1alpha\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys + * Optional. Specifies how rows are ordered in the response. + * @type string $currency_code + * Optional. A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * @type \Google\Analytics\Data\V1alpha\CohortSpec $cohort_spec + * Optional. Cohort group associated with this request. If there is a cohort + * group in the request the 'cohort' dimension must be present. + * @type bool $keep_empty_rows + * Optional. If false or unspecified, each row with all metrics equal to 0 + * will not be returned. If true, these rows will be returned if they are + * not separately removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * containing eventName: "purchase" and eventCount: 0. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Dimension dimensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * Optional. The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Dimension dimensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\Dimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Dimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * Optional. The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Metric metrics = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * Optional. The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Metric metrics = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\Metric>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Metric::class); + $this->metrics = $arr; + + return $this; + } + + /** + * Optional. 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. In a cohort request, + * this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDateRanges() + { + return $this->date_ranges; + } + + /** + * Optional. 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. In a cohort request, + * this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDateRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DateRange::class); + $this->date_ranges = $arr; + + return $this; + } + + /** + * Optional. Dimension filters let you ask for only specific dimension + * values in the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * Optional. Dimension filters let you ask for only specific dimension + * values in the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * Optional. The filter clause of metrics. Applied after aggregating the + * report's rows, similar to SQL having-clause. Dimensions cannot be used in + * this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression metric_filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\FilterExpression|null + */ + public function getMetricFilter() + { + return $this->metric_filter; + } + + public function hasMetricFilter() + { + return isset($this->metric_filter); + } + + public function clearMetricFilter() + { + unset($this->metric_filter); + } + + /** + * Optional. The filter clause of metrics. Applied after aggregating the + * report's rows, similar to SQL having-clause. Dimensions cannot be used in + * this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression metric_filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\FilterExpression $var + * @return $this + */ + public function setMetricFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); + $this->metric_filter = $var; + + return $this; + } + + /** + * Optional. The row count of the start row from Google Analytics Storage. + * The first row is counted as row 0. + * When creating a report task, the `offset` and `limit` parameters define + * the subset of data rows from Google Analytics storage to be included in + * the generated report. For example, if there are a total of 300,000 rows + * in Google Analytics storage, the initial report task may have the + * first 10,000 rows with a limit of 10,000 and an offset of 0. + * Subsequently, another report task could cover the next 10,000 rows with a + * limit of 10,000 and an offset of 10,000. + * + * Generated from protobuf field int64 offset = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * Optional. The row count of the start row from Google Analytics Storage. + * The first row is counted as row 0. + * When creating a report task, the `offset` and `limit` parameters define + * the subset of data rows from Google Analytics storage to be included in + * the generated report. For example, if there are a total of 300,000 rows + * in Google Analytics storage, the initial report task may have the + * first 10,000 rows with a limit of 10,000 and an offset of 0. + * Subsequently, another report task could cover the next 10,000 rows with a + * limit of 10,000 and an offset of 10,000. + * + * Generated from protobuf field int64 offset = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * Optional. The number of rows to return in the Report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if + * you set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return in the Report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if + * you set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + + /** + * Optional. Aggregation of metrics. Aggregated metric values will be shown + * in rows where the dimension_values are set to + * "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricAggregation metric_aggregations = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricAggregations() + { + return $this->metric_aggregations; + } + + /** + * Optional. Aggregation of metrics. Aggregated metric values will be shown + * in rows where the dimension_values are set to + * "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricAggregation metric_aggregations = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricAggregations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1alpha\MetricAggregation::class); + $this->metric_aggregations = $arr; + + return $this; + } + + /** + * Optional. Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.OrderBy order_bys = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrderBys() + { + return $this->order_bys; + } + + /** + * Optional. Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.OrderBy order_bys = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrderBys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\OrderBy::class); + $this->order_bys = $arr; + + return $this; + } + + /** + * Optional. A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getCurrencyCode() + { + return $this->currency_code; + } + + /** + * Optional. A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * Optional. Cohort group associated with this request. If there is a cohort + * group in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortSpec cohort_spec = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\CohortSpec|null + */ + public function getCohortSpec() + { + return $this->cohort_spec; + } + + public function hasCohortSpec() + { + return isset($this->cohort_spec); + } + + public function clearCohortSpec() + { + unset($this->cohort_spec); + } + + /** + * Optional. Cohort group associated with this request. If there is a cohort + * group in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1alpha.CohortSpec cohort_spec = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\CohortSpec $var + * @return $this + */ + public function setCohortSpec($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\CohortSpec::class); + $this->cohort_spec = $var; + + return $this; + } + + /** + * Optional. If false or unspecified, each row with all metrics equal to 0 + * will not be returned. If true, these rows will be returned if they are + * not separately removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * containing eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getKeepEmptyRows() + { + return $this->keep_empty_rows; + } + + /** + * Optional. If false or unspecified, each row with all metrics equal to 0 + * will not be returned. If true, these rows will be returned if they are + * not separately removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * containing eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setKeepEmptyRows($var) + { + GPBUtil::checkBool($var); + $this->keep_empty_rows = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ReportDefinition::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportDefinition::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php new file mode 100644 index 00000000000..ffb4729f713 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php @@ -0,0 +1,374 @@ +google.analytics.data.v1alpha.ReportTask.ReportMetadata + */ +class ReportMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The current state for this report task. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ReportTask.ReportMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = null; + /** + * Output only. The time when `CreateReportTask` was called and the report + * began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $begin_creating_time = null; + /** + * Output only. The total quota tokens charged during creation of the + * report. Because this token count is based on activity from the `CREATING` + * state, this tokens charge will be fixed once a report task enters the + * `ACTIVE` or `FAILED` state. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $creation_quota_tokens_charged = 0; + /** + * Output only. The total number of rows in the report result. This field + * will be populated when the state is active. You can utilize + * `task_row_count` for pagination within the confines of their existing + * report. + * + * Generated from protobuf field optional int32 task_row_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $task_row_count = null; + /** + * Output only. Error message is populated if a report task fails during + * creation. + * + * Generated from protobuf field optional string error_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $error_message = null; + /** + * Output only. The total number of rows in Google Analytics storage. If you + * want to query additional data rows beyond the current report, they can + * initiate a new report task based on the `total_row_count`. + * The `task_row_count` represents the number of rows specifically + * pertaining to the current report, whereas `total_row_count` encompasses + * the total count of rows across all data retrieved from Google + * Analytics storage. + * For example, suppose the current report's `task_row_count` is 20, + * displaying the data from the first 20 rows. Simultaneously, the + * `total_row_count` is 30, indicating the presence of data for all 30 rows. + * The `task_row_count` can be utilizated to paginate through the initial 20 + * rows. To expand the report and include data from all 30 rows, a new + * report task can be created using the total_row_count to access the full + * set of 30 rows' worth of data. + * + * Generated from protobuf field optional int32 total_row_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $total_row_count = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $state + * Output only. The current state for this report task. + * @type \Google\Protobuf\Timestamp $begin_creating_time + * Output only. The time when `CreateReportTask` was called and the report + * began the `CREATING` state. + * @type int $creation_quota_tokens_charged + * Output only. The total quota tokens charged during creation of the + * report. Because this token count is based on activity from the `CREATING` + * state, this tokens charge will be fixed once a report task enters the + * `ACTIVE` or `FAILED` state. + * @type int $task_row_count + * Output only. The total number of rows in the report result. This field + * will be populated when the state is active. You can utilize + * `task_row_count` for pagination within the confines of their existing + * report. + * @type string $error_message + * Output only. Error message is populated if a report task fails during + * creation. + * @type int $total_row_count + * Output only. The total number of rows in Google Analytics storage. If you + * want to query additional data rows beyond the current report, they can + * initiate a new report task based on the `total_row_count`. + * The `task_row_count` represents the number of rows specifically + * pertaining to the current report, whereas `total_row_count` encompasses + * the total count of rows across all data retrieved from Google + * Analytics storage. + * For example, suppose the current report's `task_row_count` is 20, + * displaying the data from the first 20 rows. Simultaneously, the + * `total_row_count` is 30, indicating the presence of data for all 30 rows. + * The `task_row_count` can be utilizated to paginate through the initial 20 + * rows. To expand the report and include data from all 30 rows, a new + * report task can be created using the total_row_count to access the full + * set of 30 rows' worth of data. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The current state for this report task. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ReportTask.ReportMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return isset($this->state) ? $this->state : 0; + } + + public function hasState() + { + return isset($this->state); + } + + public function clearState() + { + unset($this->state); + } + + /** + * Output only. The current state for this report task. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ReportTask.ReportMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\ReportTask\ReportMetadata\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. The time when `CreateReportTask` was called and the report + * began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBeginCreatingTime() + { + return $this->begin_creating_time; + } + + public function hasBeginCreatingTime() + { + return isset($this->begin_creating_time); + } + + public function clearBeginCreatingTime() + { + unset($this->begin_creating_time); + } + + /** + * Output only. The time when `CreateReportTask` was called and the report + * began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBeginCreatingTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->begin_creating_time = $var; + + return $this; + } + + /** + * Output only. The total quota tokens charged during creation of the + * report. Because this token count is based on activity from the `CREATING` + * state, this tokens charge will be fixed once a report task enters the + * `ACTIVE` or `FAILED` state. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getCreationQuotaTokensCharged() + { + return $this->creation_quota_tokens_charged; + } + + /** + * Output only. The total quota tokens charged during creation of the + * report. Because this token count is based on activity from the `CREATING` + * state, this tokens charge will be fixed once a report task enters the + * `ACTIVE` or `FAILED` state. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setCreationQuotaTokensCharged($var) + { + GPBUtil::checkInt32($var); + $this->creation_quota_tokens_charged = $var; + + return $this; + } + + /** + * Output only. The total number of rows in the report result. This field + * will be populated when the state is active. You can utilize + * `task_row_count` for pagination within the confines of their existing + * report. + * + * Generated from protobuf field optional int32 task_row_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getTaskRowCount() + { + return isset($this->task_row_count) ? $this->task_row_count : 0; + } + + public function hasTaskRowCount() + { + return isset($this->task_row_count); + } + + public function clearTaskRowCount() + { + unset($this->task_row_count); + } + + /** + * Output only. The total number of rows in the report result. This field + * will be populated when the state is active. You can utilize + * `task_row_count` for pagination within the confines of their existing + * report. + * + * Generated from protobuf field optional int32 task_row_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setTaskRowCount($var) + { + GPBUtil::checkInt32($var); + $this->task_row_count = $var; + + return $this; + } + + /** + * Output only. Error message is populated if a report task fails during + * creation. + * + * Generated from protobuf field optional string error_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getErrorMessage() + { + return isset($this->error_message) ? $this->error_message : ''; + } + + public function hasErrorMessage() + { + return isset($this->error_message); + } + + public function clearErrorMessage() + { + unset($this->error_message); + } + + /** + * Output only. Error message is populated if a report task fails during + * creation. + * + * Generated from protobuf field optional string error_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setErrorMessage($var) + { + GPBUtil::checkString($var, True); + $this->error_message = $var; + + return $this; + } + + /** + * Output only. The total number of rows in Google Analytics storage. If you + * want to query additional data rows beyond the current report, they can + * initiate a new report task based on the `total_row_count`. + * The `task_row_count` represents the number of rows specifically + * pertaining to the current report, whereas `total_row_count` encompasses + * the total count of rows across all data retrieved from Google + * Analytics storage. + * For example, suppose the current report's `task_row_count` is 20, + * displaying the data from the first 20 rows. Simultaneously, the + * `total_row_count` is 30, indicating the presence of data for all 30 rows. + * The `task_row_count` can be utilizated to paginate through the initial 20 + * rows. To expand the report and include data from all 30 rows, a new + * report task can be created using the total_row_count to access the full + * set of 30 rows' worth of data. + * + * Generated from protobuf field optional int32 total_row_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getTotalRowCount() + { + return isset($this->total_row_count) ? $this->total_row_count : 0; + } + + public function hasTotalRowCount() + { + return isset($this->total_row_count); + } + + public function clearTotalRowCount() + { + unset($this->total_row_count); + } + + /** + * Output only. The total number of rows in Google Analytics storage. If you + * want to query additional data rows beyond the current report, they can + * initiate a new report task based on the `total_row_count`. + * The `task_row_count` represents the number of rows specifically + * pertaining to the current report, whereas `total_row_count` encompasses + * the total count of rows across all data retrieved from Google + * Analytics storage. + * For example, suppose the current report's `task_row_count` is 20, + * displaying the data from the first 20 rows. Simultaneously, the + * `total_row_count` is 30, indicating the presence of data for all 30 rows. + * The `task_row_count` can be utilizated to paginate through the initial 20 + * rows. To expand the report and include data from all 30 rows, a new + * report task can be created using the total_row_count to access the full + * set of 30 rows' worth of data. + * + * Generated from protobuf field optional int32 total_row_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setTotalRowCount($var) + { + GPBUtil::checkInt32($var); + $this->total_row_count = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ReportMetadata::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportMetadata::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php new file mode 100644 index 00000000000..90c793f136a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php @@ -0,0 +1,72 @@ +google.analytics.data.v1alpha.ReportTask.ReportMetadata.State + */ +class State +{ + /** + * Unspecified state will never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The report is currently creating and will be available in the + * future. Creating occurs immediately after the CreateReport call. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * The report is fully created and ready for querying. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The report failed to be created. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + self::FAILED => 'FAILED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportMetadata_State::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php new file mode 100644 index 00000000000..8331635b0a2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php @@ -0,0 +1,34 @@ +google.analytics.data.v1alpha.ReportTaskMetadata + */ +class ReportTaskMetadata extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php new file mode 100644 index 00000000000..35955f8ff9b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php @@ -0,0 +1,407 @@ +google.analytics.data.v1alpha.ResponseMetaData + */ +class ResponseMetaData extends \Google\Protobuf\Internal\Message +{ + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + */ + protected $data_loss_from_other_row = false; + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + */ + protected $schema_restriction_response = null; + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + */ + protected $currency_code = null; + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + */ + protected $time_zone = null; + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + */ + protected $empty_reason = null; + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + */ + protected $subject_to_thresholding = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $data_loss_from_other_row + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * @type \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $schema_restriction_response + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * @type string $currency_code + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * @type string $time_zone + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * @type string $empty_reason + * If empty reason is specified, the report is empty for this reason. + * @type bool $subject_to_thresholding + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + * @return bool + */ + public function getDataLossFromOtherRow() + { + return $this->data_loss_from_other_row; + } + + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + * @param bool $var + * @return $this + */ + public function setDataLossFromOtherRow($var) + { + GPBUtil::checkBool($var); + $this->data_loss_from_other_row = $var; + + return $this; + } + + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @return \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse|null + */ + public function getSchemaRestrictionResponse() + { + return $this->schema_restriction_response; + } + + public function hasSchemaRestrictionResponse() + { + return isset($this->schema_restriction_response); + } + + public function clearSchemaRestrictionResponse() + { + unset($this->schema_restriction_response); + } + + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @param \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $var + * @return $this + */ + public function setSchemaRestrictionResponse($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse::class); + $this->schema_restriction_response = $var; + + return $this; + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @return string + */ + public function getCurrencyCode() + { + return isset($this->currency_code) ? $this->currency_code : ''; + } + + public function hasCurrencyCode() + { + return isset($this->currency_code); + } + + public function clearCurrencyCode() + { + unset($this->currency_code); + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @return string + */ + public function getTimeZone() + { + return isset($this->time_zone) ? $this->time_zone : ''; + } + + public function hasTimeZone() + { + return isset($this->time_zone); + } + + public function clearTimeZone() + { + unset($this->time_zone); + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @param string $var + * @return $this + */ + public function setTimeZone($var) + { + GPBUtil::checkString($var, True); + $this->time_zone = $var; + + return $this; + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @return string + */ + public function getEmptyReason() + { + return isset($this->empty_reason) ? $this->empty_reason : ''; + } + + public function hasEmptyReason() + { + return isset($this->empty_reason); + } + + public function clearEmptyReason() + { + unset($this->empty_reason); + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @param string $var + * @return $this + */ + public function setEmptyReason($var) + { + GPBUtil::checkString($var, True); + $this->empty_reason = $var; + + return $this; + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @return bool + */ + public function getSubjectToThresholding() + { + return isset($this->subject_to_thresholding) ? $this->subject_to_thresholding : false; + } + + public function hasSubjectToThresholding() + { + return isset($this->subject_to_thresholding); + } + + public function clearSubjectToThresholding() + { + unset($this->subject_to_thresholding); + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @param bool $var + * @return $this + */ + public function setSubjectToThresholding($var) + { + GPBUtil::checkBool($var); + $this->subject_to_thresholding = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php new file mode 100644 index 00000000000..be49e2a5e52 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php @@ -0,0 +1,84 @@ +google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse + */ +class SchemaRestrictionResponse extends \Google\Protobuf\Internal\Message +{ + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + */ + private $active_metric_restrictions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $active_metric_restrictions + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActiveMetricRestrictions() + { + return $this->active_metric_restrictions; + } + + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + * @param array<\Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActiveMetricRestrictions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction::class); + $this->active_metric_restrictions = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SchemaRestrictionResponse::class, \Google\Analytics\Data\V1alpha\ResponseMetaData_SchemaRestrictionResponse::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php new file mode 100644 index 00000000000..899eb88c337 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php @@ -0,0 +1,114 @@ +google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction + */ +class ActiveMetricRestriction extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + */ + protected $metric_name = null; + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RestrictedMetricType restricted_metric_types = 2; + */ + private $restricted_metric_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $metric_name + * The name of the restricted metric. + * @type array|\Google\Protobuf\Internal\RepeatedField $restricted_metric_types + * The reason for this metric's restriction. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + * @return string + */ + public function getMetricName() + { + return isset($this->metric_name) ? $this->metric_name : ''; + } + + public function hasMetricName() + { + return isset($this->metric_name); + } + + public function clearMetricName() + { + unset($this->metric_name); + } + + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + * @param string $var + * @return $this + */ + public function setMetricName($var) + { + GPBUtil::checkString($var, True); + $this->metric_name = $var; + + return $this; + } + + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RestrictedMetricType restricted_metric_types = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRestrictedMetricTypes() + { + return $this->restricted_metric_types; + } + + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.RestrictedMetricType restricted_metric_types = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRestrictedMetricTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1alpha\RestrictedMetricType::class); + $this->restricted_metric_types = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ActiveMetricRestriction::class, \Google\Analytics\Data\V1alpha\ResponseMetaData_SchemaRestrictionResponse_ActiveMetricRestriction::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php new file mode 100644 index 00000000000..b3c8bdd09ad --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php @@ -0,0 +1,62 @@ +google.analytics.data.v1alpha.RestrictedMetricType + */ +class RestrictedMetricType +{ + /** + * Unspecified type. + * + * Generated from protobuf enum RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; + */ + const RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; + /** + * Cost metrics such as `adCost`. + * + * Generated from protobuf enum COST_DATA = 1; + */ + const COST_DATA = 1; + /** + * Revenue metrics such as `purchaseRevenue`. + * + * Generated from protobuf enum REVENUE_DATA = 2; + */ + const REVENUE_DATA = 2; + + private static $valueToName = [ + self::RESTRICTED_METRIC_TYPE_UNSPECIFIED => 'RESTRICTED_METRIC_TYPE_UNSPECIFIED', + self::COST_DATA => 'COST_DATA', + self::REVENUE_DATA => 'REVENUE_DATA', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php new file mode 100644 index 00000000000..f6a27f8042b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php @@ -0,0 +1,138 @@ +google.analytics.data.v1alpha.Row + */ +class Row extends \Google\Protobuf\Internal\Message +{ + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + */ + private $dimension_values; + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + */ + private $metric_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * @type array<\Google\Analytics\Data\V1alpha\MetricValue>|\Google\Protobuf\Internal\RepeatedField $metric_values + * List of requested visible metric values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionValues() + { + return $this->dimension_values; + } + + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; + * @param array<\Google\Analytics\Data\V1alpha\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DimensionValue::class); + $this->dimension_values = $arr; + + return $this; + } + + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricValues() + { + return $this->metric_values; + } + + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; + * @param array<\Google\Analytics\Data\V1alpha\MetricValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\MetricValue::class); + $this->metric_values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php new file mode 100644 index 00000000000..bd1c2b97569 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php @@ -0,0 +1,557 @@ +google.analytics.data.v1alpha.RunFunnelReportRequest + */ +class RunFunnelReportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. 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 + * + * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $property = ''; + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $date_ranges; + /** + * Optional. The configuration of this request's funnel. This funnel + * configuration is required. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $funnel = null; + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $funnel_breakdown = null; + /** + * Optional. 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 next + * action of the `eventName` dimension will create rows for several events + * (for example `session_start` & `click`) and the total. + * Next action only supports `eventName` and most Page / Screen dimensions + * like `pageTitle` and `pagePath`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $funnel_next_action = null; + /** + * Optional. The funnel visualization type controls the dimensions present in + * the funnel visualization sub report response. If not specified, + * `STANDARD_FUNNEL` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $funnel_visualization_type = 0; + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $segments; + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $dimension_filter = null; + /** + * Optional. Toggles whether to return the current state of this Analytics + * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $return_property_quota = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $property + * Optional. 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 + * @type array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges + * Optional. 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. + * @type \Google\Analytics\Data\V1alpha\Funnel $funnel + * Optional. The configuration of this request's funnel. This funnel + * configuration is required. + * @type \Google\Analytics\Data\V1alpha\FunnelBreakdown $funnel_breakdown + * Optional. 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. + * @type \Google\Analytics\Data\V1alpha\FunnelNextAction $funnel_next_action + * Optional. 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 next + * action of the `eventName` dimension will create rows for several events + * (for example `session_start` & `click`) and the total. + * Next action only supports `eventName` and most Page / Screen dimensions + * like `pageTitle` and `pagePath`. + * @type int $funnel_visualization_type + * Optional. The funnel visualization type controls the dimensions present in + * the funnel visualization sub report response. If not specified, + * `STANDARD_FUNNEL` is used. + * @type array<\Google\Analytics\Data\V1alpha\Segment>|\Google\Protobuf\Internal\RepeatedField $segments + * Optional. 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. + * @type int|string $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * @type \Google\Analytics\Data\V1alpha\FilterExpression $dimension_filter + * Optional. 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. + * @type bool $return_property_quota + * Optional. Toggles whether to return the current state of this Analytics + * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Optional. 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 + * + * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getProperty() + { + return $this->property; + } + + /** + * Optional. 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 + * + * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDateRanges() + { + return $this->date_ranges; + } + + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDateRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DateRange::class); + $this->date_ranges = $arr; + + return $this; + } + + /** + * Optional. The configuration of this request's funnel. This funnel + * configuration is required. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\Funnel|null + */ + public function getFunnel() + { + return $this->funnel; + } + + public function hasFunnel() + { + return isset($this->funnel); + } + + public function clearFunnel() + { + unset($this->funnel); + } + + /** + * Optional. The configuration of this request's funnel. This funnel + * configuration is required. + * + * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\Funnel $var + * @return $this + */ + public function setFunnel($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Funnel::class); + $this->funnel = $var; + + return $this; + } + + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\FunnelBreakdown|null + */ + public function getFunnelBreakdown() + { + return $this->funnel_breakdown; + } + + public function hasFunnelBreakdown() + { + return isset($this->funnel_breakdown); + } + + public function clearFunnelBreakdown() + { + unset($this->funnel_breakdown); + } + + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\FunnelBreakdown $var + * @return $this + */ + public function setFunnelBreakdown($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelBreakdown::class); + $this->funnel_breakdown = $var; + + return $this; + } + + /** + * Optional. 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 next + * action of the `eventName` dimension will create rows for several events + * (for example `session_start` & `click`) and the total. + * Next action only supports `eventName` and most Page / Screen dimensions + * like `pageTitle` and `pagePath`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\FunnelNextAction|null + */ + public function getFunnelNextAction() + { + return $this->funnel_next_action; + } + + public function hasFunnelNextAction() + { + return isset($this->funnel_next_action); + } + + public function clearFunnelNextAction() + { + unset($this->funnel_next_action); + } + + /** + * Optional. 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 next + * action of the `eventName` dimension will create rows for several events + * (for example `session_start` & `click`) and the total. + * Next action only supports `eventName` and most Page / Screen dimensions + * like `pageTitle` and `pagePath`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\FunnelNextAction $var + * @return $this + */ + public function setFunnelNextAction($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelNextAction::class); + $this->funnel_next_action = $var; + + return $this; + } + + /** + * Optional. The funnel visualization type controls the dimensions present in + * the funnel visualization sub report response. If not specified, + * `STANDARD_FUNNEL` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getFunnelVisualizationType() + { + return $this->funnel_visualization_type; + } + + /** + * Optional. The funnel visualization type controls the dimensions present in + * the funnel visualization sub report response. If not specified, + * `STANDARD_FUNNEL` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setFunnelVisualizationType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\RunFunnelReportRequest\FunnelVisualizationType::class); + $this->funnel_visualization_type = $var; + + return $this; + } + + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSegments() + { + return $this->segments; + } + + /** + * Optional. 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param array<\Google\Analytics\Data\V1alpha\Segment>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSegments($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Segment::class); + $this->segments = $arr; + + return $this; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Analytics\Data\V1alpha\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * Optional. 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Analytics\Data\V1alpha\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * Optional. Toggles whether to return the current state of this Analytics + * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getReturnPropertyQuota() + { + return $this->return_property_quota; + } + + /** + * Optional. Toggles whether to return the current state of this Analytics + * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setReturnPropertyQuota($var) + { + GPBUtil::checkBool($var); + $this->return_property_quota = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php new file mode 100644 index 00000000000..cbb2df603a9 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType + */ +class FunnelVisualizationType +{ + /** + * Unspecified type. + * + * Generated from protobuf enum FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; + */ + const FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; + /** + * A standard (stepped) funnel. The funnel visualization sub report in the + * response will not contain date. + * + * Generated from protobuf enum STANDARD_FUNNEL = 1; + */ + const STANDARD_FUNNEL = 1; + /** + * A trended (line chart) funnel. The funnel visualization sub report in the + * response will contain the date dimension. + * + * Generated from protobuf enum TRENDED_FUNNEL = 2; + */ + const TRENDED_FUNNEL = 2; + + private static $valueToName = [ + self::FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED => 'FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED', + self::STANDARD_FUNNEL => 'STANDARD_FUNNEL', + self::TRENDED_FUNNEL => 'TRENDED_FUNNEL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(FunnelVisualizationType::class, \Google\Analytics\Data\V1alpha\RunFunnelReportRequest_FunnelVisualizationType::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php new file mode 100644 index 00000000000..7e62c5adcd8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php @@ -0,0 +1,248 @@ +google.analytics.data.v1alpha.RunFunnelReportResponse + */ +class RunFunnelReportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + */ + protected $funnel_table = 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 through the `TRENDED_FUNNEL` funnel type. The next action + * dimension is only present in the response if it was requested. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + */ + protected $funnel_visualization = null; + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + */ + protected $property_quota = null; + /** + * 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. + * + * Generated from protobuf field string kind = 4; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\FunnelSubReport $funnel_table + * 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. + * @type \Google\Analytics\Data\V1alpha\FunnelSubReport $funnel_visualization + * 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 through the `TRENDED_FUNNEL` funnel type. The next action + * dimension is only present in the response if it was requested. + * @type \Google\Analytics\Data\V1alpha\PropertyQuota $property_quota + * This Analytics Property's quota state including this request. + * @type string $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * @return \Google\Analytics\Data\V1alpha\FunnelSubReport|null + */ + public function getFunnelTable() + { + return $this->funnel_table; + } + + public function hasFunnelTable() + { + return isset($this->funnel_table); + } + + public function clearFunnelTable() + { + unset($this->funnel_table); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; + * @param \Google\Analytics\Data\V1alpha\FunnelSubReport $var + * @return $this + */ + public function setFunnelTable($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelSubReport::class); + $this->funnel_table = $var; + + 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 through the `TRENDED_FUNNEL` funnel type. The next action + * dimension is only present in the response if it was requested. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * @return \Google\Analytics\Data\V1alpha\FunnelSubReport|null + */ + public function getFunnelVisualization() + { + return $this->funnel_visualization; + } + + public function hasFunnelVisualization() + { + return isset($this->funnel_visualization); + } + + public function clearFunnelVisualization() + { + unset($this->funnel_visualization); + } + + /** + * 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 through the `TRENDED_FUNNEL` funnel type. The next action + * dimension is only present in the response if it was requested. + * + * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; + * @param \Google\Analytics\Data\V1alpha\FunnelSubReport $var + * @return $this + */ + public function setFunnelVisualization($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelSubReport::class); + $this->funnel_visualization = $var; + + return $this; + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * @return \Google\Analytics\Data\V1alpha\PropertyQuota|null + */ + public function getPropertyQuota() + { + return $this->property_quota; + } + + public function hasPropertyQuota() + { + return isset($this->property_quota); + } + + public function clearPropertyQuota() + { + unset($this->property_quota); + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; + * @param \Google\Analytics\Data\V1alpha\PropertyQuota $var + * @return $this + */ + public function setPropertyQuota($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\PropertyQuota::class); + $this->property_quota = $var; + + 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. + * + * Generated from protobuf field string kind = 4; + * @return string + */ + public function getKind() + { + return $this->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. + * + * Generated from protobuf field string kind = 4; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php new file mode 100644 index 00000000000..1c501d95f5e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php @@ -0,0 +1,134 @@ +google.analytics.data.v1alpha.SamplingMetadata + */ +class SamplingMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field int64 samples_read_count = 1; + */ + protected $samples_read_count = 0; + /** + * 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`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + */ + protected $sampling_space_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $samples_read_count + * 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. + * @type int|string $sampling_space_size + * 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`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field int64 samples_read_count = 1; + * @return int|string + */ + public function getSamplesReadCount() + { + return $this->samples_read_count; + } + + /** + * 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. + * + * Generated from protobuf field int64 samples_read_count = 1; + * @param int|string $var + * @return $this + */ + public function setSamplesReadCount($var) + { + GPBUtil::checkInt64($var); + $this->samples_read_count = $var; + + 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`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + * @return int|string + */ + public function getSamplingSpaceSize() + { + return $this->sampling_space_size; + } + + /** + * 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`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + * @param int|string $var + * @return $this + */ + public function setSamplingSpaceSize($var) + { + GPBUtil::checkInt64($var); + $this->sampling_space_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php new file mode 100644 index 00000000000..9a4ea990049 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php @@ -0,0 +1,198 @@ +google.analytics.data.v1alpha.Segment + */ +class Segment extends \Google\Protobuf\Internal\Message +{ + /** + * 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 (for example "1. Segment", "2. Segment", etc.). + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + protected $one_segment_scope; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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 (for example "1. Segment", "2. Segment", etc.). + * @type \Google\Analytics\Data\V1alpha\UserSegment $user_segment + * User segments are subsets of users who engaged with your site or app. + * @type \Google\Analytics\Data\V1alpha\SessionSegment $session_segment + * Session segments are subsets of the sessions that occurred on your site + * or app. + * @type \Google\Analytics\Data\V1alpha\EventSegment $event_segment + * Event segments are subsets of events that were triggered on your site or + * app. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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 (for example "1. Segment", "2. Segment", etc.). + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->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 (for example "1. Segment", "2. Segment", etc.). + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * User segments are subsets of users who engaged with your site or app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * @return \Google\Analytics\Data\V1alpha\UserSegment|null + */ + public function getUserSegment() + { + return $this->readOneof(2); + } + + public function hasUserSegment() + { + return $this->hasOneof(2); + } + + /** + * User segments are subsets of users who engaged with your site or app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegment user_segment = 2; + * @param \Google\Analytics\Data\V1alpha\UserSegment $var + * @return $this + */ + public function setUserSegment($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegment::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Session segments are subsets of the sessions that occurred on your site + * or app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * @return \Google\Analytics\Data\V1alpha\SessionSegment|null + */ + public function getSessionSegment() + { + return $this->readOneof(3); + } + + public function hasSessionSegment() + { + return $this->hasOneof(3); + } + + /** + * Session segments are subsets of the sessions that occurred on your site + * or app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegment session_segment = 3; + * @param \Google\Analytics\Data\V1alpha\SessionSegment $var + * @return $this + */ + public function setSessionSegment($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegment::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Event segments are subsets of events that were triggered on your site or + * app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * @return \Google\Analytics\Data\V1alpha\EventSegment|null + */ + public function getEventSegment() + { + return $this->readOneof(4); + } + + public function hasEventSegment() + { + return $this->hasOneof(4); + } + + /** + * Event segments are subsets of events that were triggered on your site or + * app. + * + * Generated from protobuf field .google.analytics.data.v1alpha.EventSegment event_segment = 4; + * @param \Google\Analytics\Data\V1alpha\EventSegment $var + * @return $this + */ + public function setEventSegment($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegment::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneSegmentScope() + { + return $this->whichOneof("one_segment_scope"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php new file mode 100644 index 00000000000..4947a2698cf --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php @@ -0,0 +1,140 @@ +google.analytics.data.v1alpha.SegmentEventFilter + */ +class SegmentEventFilter extends \Google\Protobuf\Internal\Message +{ + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + */ + protected $event_name = null; + /** + * 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + */ + protected $segment_parameter_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $event_name + * This filter matches events of this single event name. Event name is + * required. + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $segment_parameter_filter_expression + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + * @return string + */ + public function getEventName() + { + return isset($this->event_name) ? $this->event_name : ''; + } + + public function hasEventName() + { + return isset($this->event_name); + } + + public function clearEventName() + { + unset($this->event_name); + } + + /** + * This filter matches events of this single event name. Event name is + * required. + * + * Generated from protobuf field optional string event_name = 1; + * @param string $var + * @return $this + */ + public function setEventName($var) + { + GPBUtil::checkString($var, True); + $this->event_name = $var; + + 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression|null + */ + public function getSegmentParameterFilterExpression() + { + return $this->segment_parameter_filter_expression; + } + + public function hasSegmentParameterFilterExpression() + { + return isset($this->segment_parameter_filter_expression); + } + + public function clearSegmentParameterFilterExpression() + { + unset($this->segment_parameter_filter_expression); + } + + /** + * 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. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $var + * @return $this + */ + public function setSegmentParameterFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); + $this->segment_parameter_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php new file mode 100644 index 00000000000..ee3af867491 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php @@ -0,0 +1,252 @@ +google.analytics.data.v1alpha.SegmentFilter + */ +class SegmentFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + */ + protected $field_name = ''; + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + */ + protected $filter_scoping = null; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field_name + * The dimension name or metric name. + * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter + * A filter for between two values. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterScoping $filter_scoping + * Specifies the scope for the filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + * @return string + */ + public function getFieldName() + { + return $this->field_name; + } + + /** + * The dimension name or metric name. + * + * Generated from protobuf field string field_name = 1; + * @param string $var + * @return $this + */ + public function setFieldName($var) + { + GPBUtil::checkString($var, True); + $this->field_name = $var; + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @return \Google\Analytics\Data\V1alpha\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(4); + } + + public function hasStringFilter() + { + return $this->hasOneof(4); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @param \Google\Analytics\Data\V1alpha\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @return \Google\Analytics\Data\V1alpha\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(5); + } + + public function hasInListFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @param \Google\Analytics\Data\V1alpha\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @return \Google\Analytics\Data\V1alpha\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(6); + } + + public function hasNumericFilter() + { + return $this->hasOneof(6); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @param \Google\Analytics\Data\V1alpha\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(7); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(7); + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterScoping|null + */ + public function getFilterScoping() + { + return $this->filter_scoping; + } + + public function hasFilterScoping() + { + return isset($this->filter_scoping); + } + + public function clearFilterScoping() + { + unset($this->filter_scoping); + } + + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterScoping $var + * @return $this + */ + public function setFilterScoping($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterScoping::class); + $this->filter_scoping = $var; + + return $this; + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php new file mode 100644 index 00000000000..6fe85c6acbc --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php @@ -0,0 +1,216 @@ +google.analytics.data.v1alpha.SegmentFilterExpression + */ +class SegmentFilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $and_group + * The SegmentFilterExpression in `andGroup` have an AND relationship. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $or_group + * The SegmentFilterExpression in `orGroup` have an OR relationship. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $not_expression + * The SegmentFilterExpression is NOT of `notExpression`. + * @type \Google\Analytics\Data\V1alpha\SegmentFilter $segment_filter + * A primitive segment filter. + * @type \Google\Analytics\Data\V1alpha\SegmentEventFilter $segment_event_filter + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The SegmentFilterExpression in `andGroup` have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The SegmentFilterExpression in `andGroup` have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The SegmentFilterExpression in `orGroup` have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The SegmentFilterExpression in `orGroup` have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The SegmentFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The SegmentFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A primitive segment filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * @return \Google\Analytics\Data\V1alpha\SegmentFilter|null + */ + public function getSegmentFilter() + { + return $this->readOneof(4); + } + + public function hasSegmentFilter() + { + return $this->hasOneof(4); + } + + /** + * A primitive segment filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; + * @param \Google\Analytics\Data\V1alpha\SegmentFilter $var + * @return $this + */ + public function setSegmentFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilter::class); + $this->writeOneof(4, $var); + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * @return \Google\Analytics\Data\V1alpha\SegmentEventFilter|null + */ + public function getSegmentEventFilter() + { + return $this->readOneof(5); + } + + public function hasSegmentEventFilter() + { + return $this->hasOneof(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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; + * @param \Google\Analytics\Data\V1alpha\SegmentEventFilter $var + * @return $this + */ + public function setSegmentEventFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentEventFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php new file mode 100644 index 00000000000..206cf85b572 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.SegmentFilterExpressionList + */ +class SegmentFilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * The list of segment filter expressions + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\SegmentFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * The list of segment filter expressions + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of segment filter expressions + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * The list of segment filter expressions + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1alpha\SegmentFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php new file mode 100644 index 00000000000..8af2c7927bc --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php @@ -0,0 +1,118 @@ +google.analytics.data.v1alpha.SegmentFilterScoping + */ +class SegmentFilterScoping extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field optional bool at_any_point_in_time = 1; + */ + protected $at_any_point_in_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $at_any_point_in_time + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field optional bool at_any_point_in_time = 1; + * @return bool + */ + public function getAtAnyPointInTime() + { + return isset($this->at_any_point_in_time) ? $this->at_any_point_in_time : false; + } + + public function hasAtAnyPointInTime() + { + return isset($this->at_any_point_in_time); + } + + public function clearAtAnyPointInTime() + { + unset($this->at_any_point_in_time); + } + + /** + * 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. + * + * Generated from protobuf field optional bool at_any_point_in_time = 1; + * @param bool $var + * @return $this + */ + public function setAtAnyPointInTime($var) + { + GPBUtil::checkBool($var); + $this->at_any_point_in_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php new file mode 100644 index 00000000000..e161480fd21 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php @@ -0,0 +1,335 @@ +google.analytics.data.v1alpha.SegmentParameterFilter + */ +class SegmentParameterFilter extends \Google\Protobuf\Internal\Message +{ + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + */ + protected $filter_scoping = null; + protected $one_parameter; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $event_parameter_name + * 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. + * @type string $item_parameter_name + * 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. + * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter + * A filter for between two values. + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping $filter_scoping + * Specifies the scope for the filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field string event_parameter_name = 1; + * @return string + */ + public function getEventParameterName() + { + return $this->readOneof(1); + } + + public function hasEventParameterName() + { + return $this->hasOneof(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. + * + * Generated from protobuf field string event_parameter_name = 1; + * @param string $var + * @return $this + */ + public function setEventParameterName($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + 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. + * + * Generated from protobuf field string item_parameter_name = 2; + * @return string + */ + public function getItemParameterName() + { + return $this->readOneof(2); + } + + public function hasItemParameterName() + { + return $this->hasOneof(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. + * + * Generated from protobuf field string item_parameter_name = 2; + * @param string $var + * @return $this + */ + public function setItemParameterName($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @return \Google\Analytics\Data\V1alpha\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(4); + } + + public function hasStringFilter() + { + return $this->hasOneof(4); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; + * @param \Google\Analytics\Data\V1alpha\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @return \Google\Analytics\Data\V1alpha\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(5); + } + + public function hasInListFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; + * @param \Google\Analytics\Data\V1alpha\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @return \Google\Analytics\Data\V1alpha\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(6); + } + + public function hasNumericFilter() + { + return $this->hasOneof(6); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; + * @param \Google\Analytics\Data\V1alpha\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(7); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(7); + } + + /** + * A filter for between two values. + * + * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; + * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping|null + */ + public function getFilterScoping() + { + return $this->filter_scoping; + } + + public function hasFilterScoping() + { + return isset($this->filter_scoping); + } + + public function clearFilterScoping() + { + unset($this->filter_scoping); + } + + /** + * Specifies the scope for the filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping $var + * @return $this + */ + public function setFilterScoping($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping::class); + $this->filter_scoping = $var; + + return $this; + } + + /** + * @return string + */ + public function getOneParameter() + { + return $this->whichOneof("one_parameter"); + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php new file mode 100644 index 00000000000..f9983bc974a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php @@ -0,0 +1,180 @@ +google.analytics.data.v1alpha.SegmentParameterFilterExpression + */ +class SegmentParameterFilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $and_group + * The SegmentParameterFilterExpression in `andGroup` have an AND + * relationship. + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $or_group + * The SegmentParameterFilterExpression in `orGroup` have an OR + * relationship. + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $not_expression + * The SegmentParameterFilterExpression is NOT of `notExpression`. + * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilter $segment_parameter_filter + * A primitive segment parameter filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The SegmentParameterFilterExpression in `andGroup` have an AND + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The SegmentParameterFilterExpression in `andGroup` have an AND + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The SegmentParameterFilterExpression in `orGroup` have an OR + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The SegmentParameterFilterExpression in `orGroup` have an OR + * relationship. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The SegmentParameterFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The SegmentParameterFilterExpression is NOT of `notExpression`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A primitive segment parameter filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilter|null + */ + public function getSegmentParameterFilter() + { + return $this->readOneof(4); + } + + public function hasSegmentParameterFilter() + { + return $this->hasOneof(4); + } + + /** + * A primitive segment parameter filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; + * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilter $var + * @return $this + */ + public function setSegmentParameterFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php new file mode 100644 index 00000000000..714a516d2f4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1alpha.SegmentParameterFilterExpressionList + */ +class SegmentParameterFilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * The list of segment parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * The list of segment parameter filter expressions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of segment parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * The list of segment parameter filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php new file mode 100644 index 00000000000..052ccb6aefb --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php @@ -0,0 +1,158 @@ +google.analytics.data.v1alpha.SegmentParameterFilterScoping + */ +class SegmentParameterFilterScoping extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field optional int64 in_any_n_day_period = 1; + */ + protected $in_any_n_day_period = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $in_any_n_day_period + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field optional int64 in_any_n_day_period = 1; + * @return int|string + */ + public function getInAnyNDayPeriod() + { + return isset($this->in_any_n_day_period) ? $this->in_any_n_day_period : 0; + } + + public function hasInAnyNDayPeriod() + { + return isset($this->in_any_n_day_period); + } + + public function clearInAnyNDayPeriod() + { + unset($this->in_any_n_day_period); + } + + /** + * 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. + * + * Generated from protobuf field optional int64 in_any_n_day_period = 1; + * @param int|string $var + * @return $this + */ + public function setInAnyNDayPeriod($var) + { + GPBUtil::checkInt64($var); + $this->in_any_n_day_period = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php new file mode 100644 index 00000000000..9c91a5d4589 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php @@ -0,0 +1,64 @@ +google.analytics.data.v1alpha.SessionCriteriaScoping + */ +class SessionCriteriaScoping +{ + /** + * Unspecified criteria scoping. Do not specify. + * + * Generated from protobuf enum SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + const SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; + /** + * If the criteria is satisfied within one event, the session matches the + * criteria. + * + * Generated from protobuf enum SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + const SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; + /** + * If the criteria is satisfied within one session, the session matches + * the criteria. + * + * Generated from protobuf enum SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + const SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; + + private static $valueToName = [ + self::SESSION_CRITERIA_SCOPING_UNSPECIFIED => 'SESSION_CRITERIA_SCOPING_UNSPECIFIED', + self::SESSION_CRITERIA_WITHIN_SAME_EVENT => 'SESSION_CRITERIA_WITHIN_SAME_EVENT', + self::SESSION_CRITERIA_WITHIN_SAME_SESSION => 'SESSION_CRITERIA_WITHIN_SAME_SESSION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php new file mode 100644 index 00000000000..345ecc1e5b5 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php @@ -0,0 +1,64 @@ +google.analytics.data.v1alpha.SessionExclusionDuration + */ +class SessionExclusionDuration +{ + /** + * Unspecified exclusion duration. Do not specify. + * + * Generated from protobuf enum SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + const SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; + /** + * Temporarily exclude sessions from the segment during periods when the + * session meets the `sessionExclusionCriteria` condition. + * + * Generated from protobuf enum SESSION_EXCLUSION_TEMPORARY = 1; + */ + const SESSION_EXCLUSION_TEMPORARY = 1; + /** + * Permanently exclude sessions from the segment if the session ever meets + * the `sessionExclusionCriteria` condition. + * + * Generated from protobuf enum SESSION_EXCLUSION_PERMANENT = 2; + */ + const SESSION_EXCLUSION_PERMANENT = 2; + + private static $valueToName = [ + self::SESSION_EXCLUSION_DURATION_UNSPECIFIED => 'SESSION_EXCLUSION_DURATION_UNSPECIFIED', + self::SESSION_EXCLUSION_TEMPORARY => 'SESSION_EXCLUSION_TEMPORARY', + self::SESSION_EXCLUSION_PERMANENT => 'SESSION_EXCLUSION_PERMANENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php new file mode 100644 index 00000000000..032ea93baa8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php @@ -0,0 +1,123 @@ +google.analytics.data.v1alpha.SessionSegment + */ +class SessionSegment extends \Google\Protobuf\Internal\Message +{ + /** + * Defines which sessions are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + */ + protected $session_inclusion_criteria = null; + /** + * Defines which sessions are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + */ + protected $exclusion = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $session_inclusion_criteria + * Defines which sessions are included in this segment. Optional. + * @type \Google\Analytics\Data\V1alpha\SessionSegmentExclusion $exclusion + * Defines which sessions are excluded in this segment. Optional. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Defines which sessions are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * @return \Google\Analytics\Data\V1alpha\SessionSegmentCriteria|null + */ + public function getSessionInclusionCriteria() + { + return $this->session_inclusion_criteria; + } + + public function hasSessionInclusionCriteria() + { + return isset($this->session_inclusion_criteria); + } + + public function clearSessionInclusionCriteria() + { + unset($this->session_inclusion_criteria); + } + + /** + * Defines which sessions are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; + * @param \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $var + * @return $this + */ + public function setSessionInclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentCriteria::class); + $this->session_inclusion_criteria = $var; + + return $this; + } + + /** + * Defines which sessions are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * @return \Google\Analytics\Data\V1alpha\SessionSegmentExclusion|null + */ + public function getExclusion() + { + return $this->exclusion; + } + + public function hasExclusion() + { + return isset($this->exclusion); + } + + public function clearExclusion() + { + unset($this->exclusion); + } + + /** + * Defines which sessions are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; + * @param \Google\Analytics\Data\V1alpha\SessionSegmentExclusion $var + * @return $this + */ + public function setExclusion($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentExclusion::class); + $this->exclusion = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php new file mode 100644 index 00000000000..54cfa44dc51 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php @@ -0,0 +1,164 @@ +google.analytics.data.v1alpha.SessionSegmentConditionGroup + */ +class SessionSegmentConditionGroup extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + */ + protected $condition_scoping = 0; + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + */ + protected $segment_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $condition_scoping + * 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. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * @return int + */ + public function getConditionScoping() + { + return $this->condition_scoping; + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; + * @param int $var + * @return $this + */ + public function setConditionScoping($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\SessionCriteriaScoping::class); + $this->condition_scoping = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null + */ + public function getSegmentFilterExpression() + { + return $this->segment_filter_expression; + } + + public function hasSegmentFilterExpression() + { + return isset($this->segment_filter_expression); + } + + public function clearSegmentFilterExpression() + { + unset($this->segment_filter_expression); + } + + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var + * @return $this + */ + public function setSegmentFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->segment_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php new file mode 100644 index 00000000000..da0987320b8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php @@ -0,0 +1,72 @@ +google.analytics.data.v1alpha.SessionSegmentCriteria + */ +class SessionSegmentCriteria extends \Google\Protobuf\Internal\Message +{ + /** + * A session matches this criteria if the session matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + */ + private $and_condition_groups; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups + * A session matches this criteria if the session matches each of these + * `andConditionGroups`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * A session matches this criteria if the session matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAndConditionGroups() + { + return $this->and_condition_groups; + } + + /** + * A session matches this criteria if the session matches each of these + * `andConditionGroups`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; + * @param array<\Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAndConditionGroups($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup::class); + $this->and_condition_groups = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php new file mode 100644 index 00000000000..7c6f5f25cf3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php @@ -0,0 +1,127 @@ +google.analytics.data.v1alpha.SessionSegmentExclusion + */ +class SessionSegmentExclusion extends \Google\Protobuf\Internal\Message +{ + /** + * Specifies how long an exclusion will last if a session matches the + * `sessionExclusionCriteria`. + * Optional. If unspecified, a `sessionExclusionDuration` of + * `SESSION_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + */ + protected $session_exclusion_duration = 0; + /** + * If a session meets this condition, the session is excluded from + * membership in the segment for the `sessionExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + */ + protected $session_exclusion_criteria = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $session_exclusion_duration + * Specifies how long an exclusion will last if a session matches the + * `sessionExclusionCriteria`. + * Optional. If unspecified, a `sessionExclusionDuration` of + * `SESSION_EXCLUSION_TEMPORARY` is used. + * @type \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $session_exclusion_criteria + * If a session meets this condition, the session is excluded from + * membership in the segment for the `sessionExclusionDuration`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Specifies how long an exclusion will last if a session matches the + * `sessionExclusionCriteria`. + * Optional. If unspecified, a `sessionExclusionDuration` of + * `SESSION_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * @return int + */ + public function getSessionExclusionDuration() + { + return $this->session_exclusion_duration; + } + + /** + * Specifies how long an exclusion will last if a session matches the + * `sessionExclusionCriteria`. + * Optional. If unspecified, a `sessionExclusionDuration` of + * `SESSION_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; + * @param int $var + * @return $this + */ + public function setSessionExclusionDuration($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\SessionExclusionDuration::class); + $this->session_exclusion_duration = $var; + + return $this; + } + + /** + * If a session meets this condition, the session is excluded from + * membership in the segment for the `sessionExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * @return \Google\Analytics\Data\V1alpha\SessionSegmentCriteria|null + */ + public function getSessionExclusionCriteria() + { + return $this->session_exclusion_criteria; + } + + public function hasSessionExclusionCriteria() + { + return isset($this->session_exclusion_criteria); + } + + public function clearSessionExclusionCriteria() + { + unset($this->session_exclusion_criteria); + } + + /** + * If a session meets this condition, the session is excluded from + * membership in the segment for the `sessionExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; + * @param \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $var + * @return $this + */ + public function setSessionExclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentCriteria::class); + $this->session_exclusion_criteria = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php new file mode 100644 index 00000000000..b431bc30f8f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php @@ -0,0 +1,206 @@ +google.analytics.data.v1alpha.SheetExportAudienceListRequest + */ +class SheetExportAudienceListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $offset = 0; + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + + /** + * @param string $name Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * Please see {@see AlphaAnalyticsDataClient::audienceListName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1alpha\SheetExportAudienceListRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @type int|string $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int|string $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php new file mode 100644 index 00000000000..e73e6e086e2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php @@ -0,0 +1,253 @@ +google.analytics.data.v1alpha.SheetExportAudienceListResponse + */ +class SheetExportAudienceListResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A uri for you to visit in your browser to view the Google Sheet. + * + * Generated from protobuf field optional string spreadsheet_uri = 1; + */ + protected $spreadsheet_uri = null; + /** + * An ID that identifies the created Google Sheet resource. + * + * Generated from protobuf field optional string spreadsheet_id = 2; + */ + protected $spreadsheet_id = null; + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + */ + protected $row_count = null; + /** + * Configuration data about AudienceList being exported. Returned to help + * interpret the AudienceList in the Google Sheet of this response. + * For example, the AudienceList may have more rows than are present in the + * Google Sheet, and in that case, you may want to send an additional sheet + * export request with a different `offset` value to retrieve the next page of + * rows in an additional Google Sheet. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; + */ + protected $audience_list = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $spreadsheet_uri + * A uri for you to visit in your browser to view the Google Sheet. + * @type string $spreadsheet_id + * An ID that identifies the created Google Sheet resource. + * @type int $row_count + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list + * Configuration data about AudienceList being exported. Returned to help + * interpret the AudienceList in the Google Sheet of this response. + * For example, the AudienceList may have more rows than are present in the + * Google Sheet, and in that case, you may want to send an additional sheet + * export request with a different `offset` value to retrieve the next page of + * rows in an additional Google Sheet. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * A uri for you to visit in your browser to view the Google Sheet. + * + * Generated from protobuf field optional string spreadsheet_uri = 1; + * @return string + */ + public function getSpreadsheetUri() + { + return isset($this->spreadsheet_uri) ? $this->spreadsheet_uri : ''; + } + + public function hasSpreadsheetUri() + { + return isset($this->spreadsheet_uri); + } + + public function clearSpreadsheetUri() + { + unset($this->spreadsheet_uri); + } + + /** + * A uri for you to visit in your browser to view the Google Sheet. + * + * Generated from protobuf field optional string spreadsheet_uri = 1; + * @param string $var + * @return $this + */ + public function setSpreadsheetUri($var) + { + GPBUtil::checkString($var, True); + $this->spreadsheet_uri = $var; + + return $this; + } + + /** + * An ID that identifies the created Google Sheet resource. + * + * Generated from protobuf field optional string spreadsheet_id = 2; + * @return string + */ + public function getSpreadsheetId() + { + return isset($this->spreadsheet_id) ? $this->spreadsheet_id : ''; + } + + public function hasSpreadsheetId() + { + return isset($this->spreadsheet_id); + } + + public function clearSpreadsheetId() + { + unset($this->spreadsheet_id); + } + + /** + * An ID that identifies the created Google Sheet resource. + * + * Generated from protobuf field optional string spreadsheet_id = 2; + * @param string $var + * @return $this + */ + public function setSpreadsheetId($var) + { + GPBUtil::checkString($var, True); + $this->spreadsheet_id = $var; + + return $this; + } + + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @return int + */ + public function getRowCount() + { + return isset($this->row_count) ? $this->row_count : 0; + } + + public function hasRowCount() + { + return isset($this->row_count); + } + + public function clearRowCount() + { + unset($this->row_count); + } + + /** + * The total number of rows in the AudienceList result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * Configuration data about AudienceList being exported. Returned to help + * interpret the AudienceList in the Google Sheet of this response. + * For example, the AudienceList may have more rows than are present in the + * Google Sheet, and in that case, you may want to send an additional sheet + * export request with a different `offset` value to retrieve the next page of + * rows in an additional Google Sheet. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; + * @return \Google\Analytics\Data\V1alpha\AudienceList|null + */ + public function getAudienceList() + { + return $this->audience_list; + } + + public function hasAudienceList() + { + return isset($this->audience_list); + } + + public function clearAudienceList() + { + unset($this->audience_list); + } + + /** + * Configuration data about AudienceList being exported. Returned to help + * interpret the AudienceList in the Google Sheet of this response. + * For example, the AudienceList may have more rows than are present in the + * Google Sheet, and in that case, you may want to send an additional sheet + * export request with a different `offset` value to retrieve the next page of + * rows in an additional Google Sheet. + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; + * @param \Google\Analytics\Data\V1alpha\AudienceList $var + * @return $this + */ + public function setAudienceList($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); + $this->audience_list = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php new file mode 100644 index 00000000000..eb4772bde8f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php @@ -0,0 +1,135 @@ +google.analytics.data.v1alpha.StringFilter + */ +class StringFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + */ + protected $match_type = 0; + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + */ + protected $value = ''; + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + */ + protected $case_sensitive = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $match_type + * The match type for this filter. + * @type string $value + * The string value used for the matching. + * @type bool $case_sensitive + * If true, the string value is case sensitive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * @return int + */ + public function getMatchType() + { + return $this->match_type; + } + + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; + * @param int $var + * @return $this + */ + public function setMatchType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\StringFilter\MatchType::class); + $this->match_type = $var; + + return $this; + } + + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @return bool + */ + public function getCaseSensitive() + { + return $this->case_sensitive; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @param bool $var + * @return $this + */ + public function setCaseSensitive($var) + { + GPBUtil::checkBool($var); + $this->case_sensitive = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php new file mode 100644 index 00000000000..8277a91a88c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php @@ -0,0 +1,92 @@ +google.analytics.data.v1alpha.StringFilter.MatchType + */ +class MatchType +{ + /** + * Unspecified + * + * Generated from protobuf enum MATCH_TYPE_UNSPECIFIED = 0; + */ + const MATCH_TYPE_UNSPECIFIED = 0; + /** + * Exact match of the string value. + * + * Generated from protobuf enum EXACT = 1; + */ + const EXACT = 1; + /** + * Begins with the string value. + * + * Generated from protobuf enum BEGINS_WITH = 2; + */ + const BEGINS_WITH = 2; + /** + * Ends with the string value. + * + * Generated from protobuf enum ENDS_WITH = 3; + */ + const ENDS_WITH = 3; + /** + * Contains the string value. + * + * Generated from protobuf enum CONTAINS = 4; + */ + const CONTAINS = 4; + /** + * Full match for the regular expression with the string value. + * + * Generated from protobuf enum FULL_REGEXP = 5; + */ + const FULL_REGEXP = 5; + /** + * Partial match for the regular expression with the string value. + * + * Generated from protobuf enum PARTIAL_REGEXP = 6; + */ + const PARTIAL_REGEXP = 6; + + private static $valueToName = [ + self::MATCH_TYPE_UNSPECIFIED => 'MATCH_TYPE_UNSPECIFIED', + self::EXACT => 'EXACT', + self::BEGINS_WITH => 'BEGINS_WITH', + self::ENDS_WITH => 'ENDS_WITH', + self::CONTAINS => 'CONTAINS', + self::FULL_REGEXP => 'FULL_REGEXP', + self::PARTIAL_REGEXP => 'PARTIAL_REGEXP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MatchType::class, \Google\Analytics\Data\V1alpha\StringFilter_MatchType::class); + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php new file mode 100644 index 00000000000..3b9dcafc518 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php @@ -0,0 +1,72 @@ +google.analytics.data.v1alpha.UserCriteriaScoping + */ +class UserCriteriaScoping +{ + /** + * Unspecified criteria scoping. Do not specify. + * + * Generated from protobuf enum USER_CRITERIA_SCOPING_UNSPECIFIED = 0; + */ + const USER_CRITERIA_SCOPING_UNSPECIFIED = 0; + /** + * If the criteria is satisfied within one event, the user matches the + * criteria. + * + * Generated from protobuf enum USER_CRITERIA_WITHIN_SAME_EVENT = 1; + */ + const USER_CRITERIA_WITHIN_SAME_EVENT = 1; + /** + * If the criteria is satisfied within one session, the user matches the + * criteria. + * + * Generated from protobuf enum USER_CRITERIA_WITHIN_SAME_SESSION = 2; + */ + const USER_CRITERIA_WITHIN_SAME_SESSION = 2; + /** + * If the criteria is satisfied by any events for the user, the user + * matches the criteria. + * + * Generated from protobuf enum USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; + */ + const USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; + + private static $valueToName = [ + self::USER_CRITERIA_SCOPING_UNSPECIFIED => 'USER_CRITERIA_SCOPING_UNSPECIFIED', + self::USER_CRITERIA_WITHIN_SAME_EVENT => 'USER_CRITERIA_WITHIN_SAME_EVENT', + self::USER_CRITERIA_WITHIN_SAME_SESSION => 'USER_CRITERIA_WITHIN_SAME_SESSION', + self::USER_CRITERIA_ACROSS_ALL_SESSIONS => 'USER_CRITERIA_ACROSS_ALL_SESSIONS', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php new file mode 100644 index 00000000000..8ea6e8aa479 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php @@ -0,0 +1,64 @@ +google.analytics.data.v1alpha.UserExclusionDuration + */ +class UserExclusionDuration +{ + /** + * Unspecified exclusion duration. Do not specify. + * + * Generated from protobuf enum USER_EXCLUSION_DURATION_UNSPECIFIED = 0; + */ + const USER_EXCLUSION_DURATION_UNSPECIFIED = 0; + /** + * Temporarily exclude users from the segment during periods when the + * user meets the `userExclusionCriteria` condition. + * + * Generated from protobuf enum USER_EXCLUSION_TEMPORARY = 1; + */ + const USER_EXCLUSION_TEMPORARY = 1; + /** + * Permanently exclude users from the segment if the user ever meets the + * `userExclusionCriteria` condition. + * + * Generated from protobuf enum USER_EXCLUSION_PERMANENT = 2; + */ + const USER_EXCLUSION_PERMANENT = 2; + + private static $valueToName = [ + self::USER_EXCLUSION_DURATION_UNSPECIFIED => 'USER_EXCLUSION_DURATION_UNSPECIFIED', + self::USER_EXCLUSION_TEMPORARY => 'USER_EXCLUSION_TEMPORARY', + self::USER_EXCLUSION_PERMANENT => 'USER_EXCLUSION_PERMANENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php new file mode 100644 index 00000000000..0bfd9be4499 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php @@ -0,0 +1,123 @@ +google.analytics.data.v1alpha.UserSegment + */ +class UserSegment extends \Google\Protobuf\Internal\Message +{ + /** + * Defines which users are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + */ + protected $user_inclusion_criteria = null; + /** + * Defines which users are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + */ + protected $exclusion = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1alpha\UserSegmentCriteria $user_inclusion_criteria + * Defines which users are included in this segment. Optional. + * @type \Google\Analytics\Data\V1alpha\UserSegmentExclusion $exclusion + * Defines which users are excluded in this segment. Optional. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Defines which users are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * @return \Google\Analytics\Data\V1alpha\UserSegmentCriteria|null + */ + public function getUserInclusionCriteria() + { + return $this->user_inclusion_criteria; + } + + public function hasUserInclusionCriteria() + { + return isset($this->user_inclusion_criteria); + } + + public function clearUserInclusionCriteria() + { + unset($this->user_inclusion_criteria); + } + + /** + * Defines which users are included in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; + * @param \Google\Analytics\Data\V1alpha\UserSegmentCriteria $var + * @return $this + */ + public function setUserInclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentCriteria::class); + $this->user_inclusion_criteria = $var; + + return $this; + } + + /** + * Defines which users are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * @return \Google\Analytics\Data\V1alpha\UserSegmentExclusion|null + */ + public function getExclusion() + { + return $this->exclusion; + } + + public function hasExclusion() + { + return isset($this->exclusion); + } + + public function clearExclusion() + { + unset($this->exclusion); + } + + /** + * Defines which users are excluded in this segment. Optional. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; + * @param \Google\Analytics\Data\V1alpha\UserSegmentExclusion $var + * @return $this + */ + public function setExclusion($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentExclusion::class); + $this->exclusion = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php new file mode 100644 index 00000000000..d2f547575d0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php @@ -0,0 +1,164 @@ +google.analytics.data.v1alpha.UserSegmentConditionGroup + */ +class UserSegmentConditionGroup extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + */ + protected $condition_scoping = 0; + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + */ + protected $segment_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $condition_scoping + * 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. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * @return int + */ + public function getConditionScoping() + { + return $this->condition_scoping; + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; + * @param int $var + * @return $this + */ + public function setConditionScoping($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); + $this->condition_scoping = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null + */ + public function getSegmentFilterExpression() + { + return $this->segment_filter_expression; + } + + public function hasSegmentFilterExpression() + { + return isset($this->segment_filter_expression); + } + + public function clearSegmentFilterExpression() + { + unset($this->segment_filter_expression); + } + + /** + * Data is included or excluded from the segment based on if it matches + * this expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var + * @return $this + */ + public function setSegmentFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->segment_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php new file mode 100644 index 00000000000..9e4f026d7e0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php @@ -0,0 +1,118 @@ +google.analytics.data.v1alpha.UserSegmentCriteria + */ +class UserSegmentCriteria extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + */ + private $and_condition_groups; + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + */ + private $and_sequence_groups; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1alpha\UserSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups + * 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. + * @type array<\Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup>|\Google\Protobuf\Internal\RepeatedField $and_sequence_groups + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAndConditionGroups() + { + return $this->and_condition_groups; + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; + * @param array<\Google\Analytics\Data\V1alpha\UserSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAndConditionGroups($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSegmentConditionGroup::class); + $this->and_condition_groups = $arr; + + 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAndSequenceGroups() + { + return $this->and_sequence_groups; + } + + /** + * 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; + * @param array<\Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAndSequenceGroups($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup::class); + $this->and_sequence_groups = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php new file mode 100644 index 00000000000..25cff90f0b1 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php @@ -0,0 +1,127 @@ +google.analytics.data.v1alpha.UserSegmentExclusion + */ +class UserSegmentExclusion extends \Google\Protobuf\Internal\Message +{ + /** + * Specifies how long an exclusion will last if a user matches the + * `userExclusionCriteria`. + * Optional. If unspecified, `userExclusionDuration` of + * `USER_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + */ + protected $user_exclusion_duration = 0; + /** + * If a user meets this condition, the user is excluded from membership in + * the segment for the `userExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + */ + protected $user_exclusion_criteria = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $user_exclusion_duration + * Specifies how long an exclusion will last if a user matches the + * `userExclusionCriteria`. + * Optional. If unspecified, `userExclusionDuration` of + * `USER_EXCLUSION_TEMPORARY` is used. + * @type \Google\Analytics\Data\V1alpha\UserSegmentCriteria $user_exclusion_criteria + * If a user meets this condition, the user is excluded from membership in + * the segment for the `userExclusionDuration`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * Specifies how long an exclusion will last if a user matches the + * `userExclusionCriteria`. + * Optional. If unspecified, `userExclusionDuration` of + * `USER_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * @return int + */ + public function getUserExclusionDuration() + { + return $this->user_exclusion_duration; + } + + /** + * Specifies how long an exclusion will last if a user matches the + * `userExclusionCriteria`. + * Optional. If unspecified, `userExclusionDuration` of + * `USER_EXCLUSION_TEMPORARY` is used. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; + * @param int $var + * @return $this + */ + public function setUserExclusionDuration($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserExclusionDuration::class); + $this->user_exclusion_duration = $var; + + return $this; + } + + /** + * If a user meets this condition, the user is excluded from membership in + * the segment for the `userExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * @return \Google\Analytics\Data\V1alpha\UserSegmentCriteria|null + */ + public function getUserExclusionCriteria() + { + return $this->user_exclusion_criteria; + } + + public function hasUserExclusionCriteria() + { + return isset($this->user_exclusion_criteria); + } + + public function clearUserExclusionCriteria() + { + unset($this->user_exclusion_criteria); + } + + /** + * If a user meets this condition, the user is excluded from membership in + * the segment for the `userExclusionDuration`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; + * @param \Google\Analytics\Data\V1alpha\UserSegmentCriteria $var + * @return $this + */ + public function setUserExclusionCriteria($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentCriteria::class); + $this->user_exclusion_criteria = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php new file mode 100644 index 00000000000..3f6d5d1ed4f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php @@ -0,0 +1,202 @@ +google.analytics.data.v1alpha.UserSegmentSequenceGroup + */ +class UserSegmentSequenceGroup extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + */ + protected $sequence_scoping = 0; + /** + * 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. + * + * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; + */ + protected $sequence_maximum_duration = null; + /** + * An ordered sequence of condition steps. A user's events must complete + * each step in order for the user to match the + * `UserSegmentSequenceGroup`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + */ + private $user_sequence_steps; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $sequence_scoping + * 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. + * @type \Google\Protobuf\Duration $sequence_maximum_duration + * 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. + * @type array<\Google\Analytics\Data\V1alpha\UserSequenceStep>|\Google\Protobuf\Internal\RepeatedField $user_sequence_steps + * An ordered sequence of condition steps. A user's events must complete + * each step in order for the user to match the + * `UserSegmentSequenceGroup`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * @return int + */ + public function getSequenceScoping() + { + return $this->sequence_scoping; + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; + * @param int $var + * @return $this + */ + public function setSequenceScoping($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); + $this->sequence_scoping = $var; + + 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. + * + * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getSequenceMaximumDuration() + { + return $this->sequence_maximum_duration; + } + + public function hasSequenceMaximumDuration() + { + return isset($this->sequence_maximum_duration); + } + + public function clearSequenceMaximumDuration() + { + unset($this->sequence_maximum_duration); + } + + /** + * 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. + * + * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setSequenceMaximumDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->sequence_maximum_duration = $var; + + 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`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getUserSequenceSteps() + { + return $this->user_sequence_steps; + } + + /** + * An ordered sequence of condition steps. A user's events must complete + * each step in order for the user to match the + * `UserSegmentSequenceGroup`. + * + * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; + * @param array<\Google\Analytics\Data\V1alpha\UserSequenceStep>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setUserSequenceSteps($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSequenceStep::class); + $this->user_sequence_steps = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php new file mode 100644 index 00000000000..25397518d56 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php @@ -0,0 +1,198 @@ +google.analytics.data.v1alpha.UserSequenceStep + */ +class UserSequenceStep extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field bool is_directly_followed_by = 1; + */ + protected $is_directly_followed_by = false; + /** + * 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`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + */ + protected $step_scoping = 0; + /** + * A user matches this sequence step if their events match this + * expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + */ + protected $segment_filter_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $is_directly_followed_by + * 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. + * @type int $step_scoping + * 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`. + * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression + * A user matches this sequence step if their events match this + * expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field bool is_directly_followed_by = 1; + * @return bool + */ + public function getIsDirectlyFollowedBy() + { + return $this->is_directly_followed_by; + } + + /** + * 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. + * + * Generated from protobuf field bool is_directly_followed_by = 1; + * @param bool $var + * @return $this + */ + public function setIsDirectlyFollowedBy($var) + { + GPBUtil::checkBool($var); + $this->is_directly_followed_by = $var; + + 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`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * @return int + */ + public function getStepScoping() + { + return $this->step_scoping; + } + + /** + * 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`. + * + * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; + * @param int $var + * @return $this + */ + public function setStepScoping($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); + $this->step_scoping = $var; + + return $this; + } + + /** + * A user matches this sequence step if their events match this + * expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null + */ + public function getSegmentFilterExpression() + { + return $this->segment_filter_expression; + } + + public function hasSegmentFilterExpression() + { + return isset($this->segment_filter_expression); + } + + public function clearSegmentFilterExpression() + { + unset($this->segment_filter_expression); + } + + /** + * A user matches this sequence step if their events match this + * expression. Expressions express criteria on dimension, metrics, + * and/or parameters. + * + * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; + * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var + * @return $this + */ + public function setSegmentFilterExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); + $this->segment_filter_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php new file mode 100644 index 00000000000..7325fcd52a8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php @@ -0,0 +1,258 @@ +google.analytics.data.v1alpha.WebhookNotification + */ +class WebhookNotification extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The web address that will receive the webhook notification. This + * address will receive POST requests as the state of the long running + * operation resource changes. The POST request will contain both a JSON + * version of the long running operation resource in the body and a + * `sentTimestamp` field. The sent timestamp will specify the unix + * microseconds since the epoch that the request was sent; this lets you + * identify replayed notifications. + * An example URI is + * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. + * The URI must use HTTPS and point to a site with a valid SSL certificate on + * the web server. The URI must have a maximum string length of 128 characters + * & use only the allowlisted characters from [RFC + * 1738](https://www.rfc-editor.org/rfc/rfc1738). + * When your webhook server receives a notification, it is expected to reply + * with an HTTP response status code of 200 within 5 seconds. + * A URI is required to use webhook notifications. + * Requests to this webhook server will contain an ID token authenticating the + * service account + * `google-analytics-audience-export@system.gserviceaccount.com`. To learn + * more about ID tokens, see + * https://cloud.google.com/docs/authentication/token-types#id. For Google + * Cloud Functions, this lets you configure your function to require + * authentication. In Cloud IAM, you will need to grant the service account + * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud + * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook + * post request to pass Google Cloud Functions authentication. This API can + * send webhook notifications to arbitrary URIs; for webhook servers other + * than Google Cloud Functions, this ID token in the authorization bearer + * header should be ignored if it is not needed. + * + * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $uri = null; + /** + * Optional. The channel token is an arbitrary string value and must have a + * maximum string length of 64 characters. Channel tokens allow you to verify + * the source of a webhook notification. This guards against the message being + * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` + * HTTP header of the webhook POST request. + * A channel token is not required to use webhook notifications. + * + * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $channel_token = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * Optional. The web address that will receive the webhook notification. This + * address will receive POST requests as the state of the long running + * operation resource changes. The POST request will contain both a JSON + * version of the long running operation resource in the body and a + * `sentTimestamp` field. The sent timestamp will specify the unix + * microseconds since the epoch that the request was sent; this lets you + * identify replayed notifications. + * An example URI is + * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. + * The URI must use HTTPS and point to a site with a valid SSL certificate on + * the web server. The URI must have a maximum string length of 128 characters + * & use only the allowlisted characters from [RFC + * 1738](https://www.rfc-editor.org/rfc/rfc1738). + * When your webhook server receives a notification, it is expected to reply + * with an HTTP response status code of 200 within 5 seconds. + * A URI is required to use webhook notifications. + * Requests to this webhook server will contain an ID token authenticating the + * service account + * `google-analytics-audience-export@system.gserviceaccount.com`. To learn + * more about ID tokens, see + * https://cloud.google.com/docs/authentication/token-types#id. For Google + * Cloud Functions, this lets you configure your function to require + * authentication. In Cloud IAM, you will need to grant the service account + * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud + * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook + * post request to pass Google Cloud Functions authentication. This API can + * send webhook notifications to arbitrary URIs; for webhook servers other + * than Google Cloud Functions, this ID token in the authorization bearer + * header should be ignored if it is not needed. + * @type string $channel_token + * Optional. The channel token is an arbitrary string value and must have a + * maximum string length of 64 characters. Channel tokens allow you to verify + * the source of a webhook notification. This guards against the message being + * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` + * HTTP header of the webhook POST request. + * A channel token is not required to use webhook notifications. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The web address that will receive the webhook notification. This + * address will receive POST requests as the state of the long running + * operation resource changes. The POST request will contain both a JSON + * version of the long running operation resource in the body and a + * `sentTimestamp` field. The sent timestamp will specify the unix + * microseconds since the epoch that the request was sent; this lets you + * identify replayed notifications. + * An example URI is + * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. + * The URI must use HTTPS and point to a site with a valid SSL certificate on + * the web server. The URI must have a maximum string length of 128 characters + * & use only the allowlisted characters from [RFC + * 1738](https://www.rfc-editor.org/rfc/rfc1738). + * When your webhook server receives a notification, it is expected to reply + * with an HTTP response status code of 200 within 5 seconds. + * A URI is required to use webhook notifications. + * Requests to this webhook server will contain an ID token authenticating the + * service account + * `google-analytics-audience-export@system.gserviceaccount.com`. To learn + * more about ID tokens, see + * https://cloud.google.com/docs/authentication/token-types#id. For Google + * Cloud Functions, this lets you configure your function to require + * authentication. In Cloud IAM, you will need to grant the service account + * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud + * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook + * post request to pass Google Cloud Functions authentication. This API can + * send webhook notifications to arbitrary URIs; for webhook servers other + * than Google Cloud Functions, this ID token in the authorization bearer + * header should be ignored if it is not needed. + * + * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getUri() + { + return isset($this->uri) ? $this->uri : ''; + } + + public function hasUri() + { + return isset($this->uri); + } + + public function clearUri() + { + unset($this->uri); + } + + /** + * Optional. The web address that will receive the webhook notification. This + * address will receive POST requests as the state of the long running + * operation resource changes. The POST request will contain both a JSON + * version of the long running operation resource in the body and a + * `sentTimestamp` field. The sent timestamp will specify the unix + * microseconds since the epoch that the request was sent; this lets you + * identify replayed notifications. + * An example URI is + * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. + * The URI must use HTTPS and point to a site with a valid SSL certificate on + * the web server. The URI must have a maximum string length of 128 characters + * & use only the allowlisted characters from [RFC + * 1738](https://www.rfc-editor.org/rfc/rfc1738). + * When your webhook server receives a notification, it is expected to reply + * with an HTTP response status code of 200 within 5 seconds. + * A URI is required to use webhook notifications. + * Requests to this webhook server will contain an ID token authenticating the + * service account + * `google-analytics-audience-export@system.gserviceaccount.com`. To learn + * more about ID tokens, see + * https://cloud.google.com/docs/authentication/token-types#id. For Google + * Cloud Functions, this lets you configure your function to require + * authentication. In Cloud IAM, you will need to grant the service account + * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud + * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook + * post request to pass Google Cloud Functions authentication. This API can + * send webhook notifications to arbitrary URIs; for webhook servers other + * than Google Cloud Functions, this ID token in the authorization bearer + * header should be ignored if it is not needed. + * + * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Optional. The channel token is an arbitrary string value and must have a + * maximum string length of 64 characters. Channel tokens allow you to verify + * the source of a webhook notification. This guards against the message being + * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` + * HTTP header of the webhook POST request. + * A channel token is not required to use webhook notifications. + * + * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getChannelToken() + { + return isset($this->channel_token) ? $this->channel_token : ''; + } + + public function hasChannelToken() + { + return isset($this->channel_token); + } + + public function clearChannelToken() + { + unset($this->channel_token); + } + + /** + * Optional. The channel token is an arbitrary string value and must have a + * maximum string length of 64 characters. Channel tokens allow you to verify + * the source of a webhook notification. This guards against the message being + * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` + * HTTP header of the webhook POST request. + * A channel token is not required to use webhook notifications. + * + * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setChannelToken($var) + { + GPBUtil::checkString($var, True); + $this->channel_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php new file mode 100644 index 00000000000..60f00596f47 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php @@ -0,0 +1,119 @@ +setAudience($audienceListAudience) + ->setDimensions($audienceListDimensions); + $request = (new CreateAudienceListRequest()) + ->setParent($formattedParent) + ->setAudienceList($audienceList); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $alphaAnalyticsDataClient->createAudienceList($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var AudienceList $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + $audienceListAudience = '[AUDIENCE]'; + + create_audience_list_sample($formattedParent, $audienceListAudience); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_CreateAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php new file mode 100644 index 00000000000..3c4f80ae7c6 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php @@ -0,0 +1,103 @@ +setAudience($recurringAudienceListAudience) + ->setDimensions($recurringAudienceListDimensions); + $request = (new CreateRecurringAudienceListRequest()) + ->setParent($formattedParent) + ->setRecurringAudienceList($recurringAudienceList); + + // Call the API and handle any network failures. + try { + /** @var RecurringAudienceList $response */ + $response = $alphaAnalyticsDataClient->createRecurringAudienceList($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + $recurringAudienceListAudience = '[AUDIENCE]'; + + create_recurring_audience_list_sample($formattedParent, $recurringAudienceListAudience); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_CreateRecurringAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php new file mode 100644 index 00000000000..22e5fc7dfc7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php @@ -0,0 +1,89 @@ +setParent($formattedParent) + ->setReportTask($reportTask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $alphaAnalyticsDataClient->createReportTask($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ReportTask $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + + create_report_task_sample($formattedParent); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_CreateReportTask_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php new file mode 100644 index 00000000000..55c893ca826 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php @@ -0,0 +1,83 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var AudienceList $response */ + $response = $alphaAnalyticsDataClient->getAudienceList($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = AlphaAnalyticsDataClient::audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + + get_audience_list_sample($formattedName); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_GetAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php new file mode 100644 index 00000000000..2288cc91d97 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php @@ -0,0 +1,86 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var RecurringAudienceList $response */ + $response = $alphaAnalyticsDataClient->getRecurringAudienceList($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = AlphaAnalyticsDataClient::recurringAudienceListName( + '[PROPERTY]', + '[RECURRING_AUDIENCE_LIST]' + ); + + get_recurring_audience_list_sample($formattedName); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_GetRecurringAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php new file mode 100644 index 00000000000..5dddf6fc9bb --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ReportTask $response */ + $response = $alphaAnalyticsDataClient->getReportTask($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = AlphaAnalyticsDataClient::reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + + get_report_task_sample($formattedName); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_GetReportTask_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php new file mode 100644 index 00000000000..dac54f22283 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php @@ -0,0 +1,90 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $alphaAnalyticsDataClient->listAudienceLists($request); + + /** @var AudienceList $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + + list_audience_lists_sample($formattedParent); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_ListAudienceLists_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php new file mode 100644 index 00000000000..6f67c56ae5d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php @@ -0,0 +1,88 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $alphaAnalyticsDataClient->listRecurringAudienceLists($request); + + /** @var RecurringAudienceList $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + + list_recurring_audience_lists_sample($formattedParent); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_ListRecurringAudienceLists_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php new file mode 100644 index 00000000000..43c27b56ef2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $alphaAnalyticsDataClient->listReportTasks($request); + + /** @var ReportTask $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); + + list_report_tasks_sample($formattedParent); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_ListReportTasks_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php new file mode 100644 index 00000000000..e4d3e33d8d4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php @@ -0,0 +1,88 @@ +setName($name); + + // Call the API and handle any network failures. + try { + /** @var QueryAudienceListResponse $response */ + $response = $alphaAnalyticsDataClient->queryAudienceList($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $name = '[NAME]'; + + query_audience_list_sample($name); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_QueryAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php new file mode 100644 index 00000000000..3282d2889f7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php @@ -0,0 +1,75 @@ +setName($name); + + // Call the API and handle any network failures. + try { + /** @var QueryReportTaskResponse $response */ + $response = $alphaAnalyticsDataClient->queryReportTask($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $name = '[NAME]'; + + query_report_task_sample($name); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_QueryReportTask_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php new file mode 100644 index 00000000000..8d202612edc --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php @@ -0,0 +1,72 @@ +runFunnelReport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_RunFunnelReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php new file mode 100644 index 00000000000..9d9a4259c3c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php @@ -0,0 +1,90 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var SheetExportAudienceListResponse $response */ + $response = $alphaAnalyticsDataClient->sheetExportAudienceList($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = AlphaAnalyticsDataClient::audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + + sheet_export_audience_list_sample($formattedName); +} +// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_SheetExportAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php new file mode 100644 index 00000000000..ca7d0b50ee3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php @@ -0,0 +1,36 @@ + self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/alpha_analytics_data_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_rest_client_config.php', + ], + ], + ]; + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + * + * @experimental + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + * + * @experimental + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * audience_list resource. + * + * @param string $property + * @param string $audienceList + * + * @return string The formatted audience_list resource. + * + * @experimental + */ + public static function audienceListName(string $property, string $audienceList): string + { + return self::getPathTemplate('audienceList')->render([ + 'property' => $property, + 'audience_list' => $audienceList, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a property + * resource. + * + * @param string $property + * + * @return string The formatted property resource. + * + * @experimental + */ + public static function propertyName(string $property): string + { + return self::getPathTemplate('property')->render([ + 'property' => $property, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * recurring_audience_list resource. + * + * @param string $property + * @param string $recurringAudienceList + * + * @return string The formatted recurring_audience_list resource. + * + * @experimental + */ + public static function recurringAudienceListName(string $property, string $recurringAudienceList): string + { + return self::getPathTemplate('recurringAudienceList')->render([ + 'property' => $property, + 'recurring_audience_list' => $recurringAudienceList, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a report_task + * resource. + * + * @param string $property + * @param string $reportTask + * + * @return string The formatted report_task resource. + * + * @experimental + */ + public static function reportTaskName(string $property, string $reportTask): string + { + return self::getPathTemplate('reportTask')->render([ + 'property' => $property, + 'report_task' => $reportTask, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - audienceList: properties/{property}/audienceLists/{audience_list} + * - property: properties/{property} + * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} + * - reportTask: properties/{property}/reportTasks/{report_task} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + * + * @experimental + */ + public static function parseName(string $formattedName, string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'analyticsdata.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + * + * @experimental + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates an audience list for later retrieval. This method quickly returns + * the audience list's resource name and initiates a long running asynchronous + * request to form an audience list. To list the users in an audience list, + * first create the audience list through this method and then send the + * audience resource name to the `QueryAudienceList` method. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * An audience list is a snapshot of the users currently in the audience at + * the time of audience list creation. Creating audience lists for one + * audience on different days will return different results as users enter and + * exit the audience. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. Audience lists contain + * the users in each audience. + * + * This method is available at beta stability at + * [audienceExports.create](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/create). + * To give your feedback on this API, complete the [Google Analytics Audience + * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see AlphaAnalyticsDataClient::createAudienceListAsync()} + * . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php + * + * @param CreateAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function createAudienceList(CreateAudienceListRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateAudienceList', $request, $callOptions)->wait(); + } + + /** + * Creates a recurring audience list. Recurring audience lists produces new + * audience lists each day. Audience lists are users in an audience at the + * time of the list's creation. + * + * A recurring audience list ensures that you have audience list based on the + * most recent data available for use each day. If you manually create + * audience list, you don't know when an audience list based on an additional + * day's data is available. This recurring audience list automates the + * creation of an audience list when an additional day's data is available. + * You will consume fewer quota tokens by using recurring audience list versus + * manually creating audience list at various times of day trying to guess + * when an additional day's data is ready. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is + * {@see AlphaAnalyticsDataClient::createRecurringAudienceListAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php + * + * @param CreateRecurringAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RecurringAudienceList + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function createRecurringAudienceList(CreateRecurringAudienceListRequest $request, array $callOptions = []): RecurringAudienceList + { + return $this->startApiCall('CreateRecurringAudienceList', $request, $callOptions)->wait(); + } + + /** + * Initiates the creation of a report task. This method quickly + * returns a report task and initiates a long running + * asynchronous request to form a customized report of your Google Analytics + * event data. + * + * The async variant is {@see AlphaAnalyticsDataClient::createReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php + * + * @param CreateReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function createReportTask(CreateReportTaskRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateReportTask', $request, $callOptions)->wait(); + } + + /** + * Gets configuration metadata about a specific audience list. This method + * can be used to understand an audience list after it has been created. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * This method is available at beta stability at + * [audienceExports.get](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/get). + * To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see AlphaAnalyticsDataClient::getAudienceListAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php + * + * @param GetAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return AudienceList + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getAudienceList(GetAudienceListRequest $request, array $callOptions = []): AudienceList + { + return $this->startApiCall('GetAudienceList', $request, $callOptions)->wait(); + } + + /** + * Gets configuration metadata about a specific recurring audience list. This + * method can be used to understand a recurring audience list's state after it + * has been created. For example, a recurring audience list resource will + * generate audience list instances for each day, and this method can be used + * to get the resource name of the most recent audience list instance. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is + * {@see AlphaAnalyticsDataClient::getRecurringAudienceListAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php + * + * @param GetRecurringAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RecurringAudienceList + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getRecurringAudienceList(GetRecurringAudienceListRequest $request, array $callOptions = []): RecurringAudienceList + { + return $this->startApiCall('GetRecurringAudienceList', $request, $callOptions)->wait(); + } + + /** + * Gets report metadata about a specific report task. After creating a report + * task, use this method to check its processing state or inspect its + * report definition. + * + * The async variant is {@see AlphaAnalyticsDataClient::getReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php + * + * @param GetReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ReportTask + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getReportTask(GetReportTaskRequest $request, array $callOptions = []): ReportTask + { + return $this->startApiCall('GetReportTask', $request, $callOptions)->wait(); + } + + /** + * Lists all audience lists for a property. This method can be used for you to + * find and reuse existing audience lists rather than creating unnecessary new + * audience lists. The same audience can have multiple audience lists that + * represent the list of users that were in an audience on different days. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * This method is available at beta stability at + * [audienceExports.list](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/list). + * To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see AlphaAnalyticsDataClient::listAudienceListsAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php + * + * @param ListAudienceListsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function listAudienceLists(ListAudienceListsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListAudienceLists', $request, $callOptions); + } + + /** + * Lists all recurring audience lists for a property. This method can be used + * for you to find and reuse existing recurring audience lists rather than + * creating unnecessary new recurring audience lists. The same audience can + * have multiple recurring audience lists that represent different dimension + * combinations; for example, just the dimension `deviceId` or both the + * dimensions `deviceId` and `userId`. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is + * {@see AlphaAnalyticsDataClient::listRecurringAudienceListsAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php + * + * @param ListRecurringAudienceListsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function listRecurringAudienceLists(ListRecurringAudienceListsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListRecurringAudienceLists', $request, $callOptions); + } + + /** + * Lists all report tasks for a property. + * + * The async variant is {@see AlphaAnalyticsDataClient::listReportTasksAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php + * + * @param ListReportTasksRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function listReportTasks(ListReportTasksRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListReportTasks', $request, $callOptions); + } + + /** + * Retrieves an audience list of users. After creating an audience, the users + * are not immediately available for listing. First, a request to + * `CreateAudienceList` is necessary to create an audience list of users, and + * then second, this method is used to retrieve the users in the audience + * list. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * This method is available at beta stability at + * [audienceExports.query](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/query). + * To give your feedback on this API, complete the [Google Analytics Audience + * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see AlphaAnalyticsDataClient::queryAudienceListAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php + * + * @param QueryAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return QueryAudienceListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function queryAudienceList(QueryAudienceListRequest $request, array $callOptions = []): QueryAudienceListResponse + { + return $this->startApiCall('QueryAudienceList', $request, $callOptions)->wait(); + } + + /** + * Retrieves a report task's content. After requesting the `CreateReportTask`, + * you are able to retrieve the report content once the report is + * ACTIVE. This method will return an error if the report task's state is not + * `ACTIVE`. A query response will return the tabular row & column values of + * the report. + * + * The async variant is {@see AlphaAnalyticsDataClient::queryReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php + * + * @param QueryReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return QueryReportTaskResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function queryReportTask(QueryReportTaskRequest $request, array $callOptions = []): QueryReportTaskResponse + { + return $this->startApiCall('QueryReportTask', $request, $callOptions)->wait(); + } + + /** + * 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). + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the [Google Analytics Data API Funnel + * Reporting + * Feedback](https://docs.google.com/forms/d/e/1FAIpQLSdwOlQDJAUoBiIgUZZ3S_Lwi8gr7Bb0k1jhvc-DEg7Rol3UjA/viewform). + * + * The async variant is {@see AlphaAnalyticsDataClient::runFunnelReportAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php + * + * @param RunFunnelReportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RunFunnelReportResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function runFunnelReport(RunFunnelReportRequest $request, array $callOptions = []): RunFunnelReportResponse + { + return $this->startApiCall('RunFunnelReport', $request, $callOptions)->wait(); + } + + /** + * Exports an audience list of users to a Google Sheet. After creating an + * audience, the users are not immediately available for listing. First, a + * request to `CreateAudienceList` is necessary to create an audience list of + * users, and then second, this method is used to export those users in the + * audience list to a Google Sheet. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is + * {@see AlphaAnalyticsDataClient::sheetExportAudienceListAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php + * + * @param SheetExportAudienceListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SheetExportAudienceListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function sheetExportAudienceList(SheetExportAudienceListRequest $request, array $callOptions = []): SheetExportAudienceListResponse + { + return $this->startApiCall('SheetExportAudienceList', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php new file mode 100644 index 00000000000..a63144e6ee9 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php @@ -0,0 +1,1477 @@ +propertyName('[PROPERTY]'); + * $audienceList = new AudienceList(); + * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceList'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * 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 parseName method to extract the individual identifiers + * contained within formatted names that are returned by the API. + * + * @experimental + * + * @deprecated Please use the new service client {@see \Google\Analytics\Data\V1alpha\Client\AlphaAnalyticsDataClient}. + */ +class AlphaAnalyticsDataGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'google.analytics.data.v1alpha.AlphaAnalyticsData'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + const SERVICE_ADDRESS = 'analyticsdata.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'analyticsdata.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/analytics', + 'https://www.googleapis.com/auth/analytics.readonly', + 'https://www.googleapis.com/auth/drive', + 'https://www.googleapis.com/auth/drive.file', + 'https://www.googleapis.com/auth/spreadsheets', + ]; + + private static $audienceListNameTemplate; + + private static $propertyNameTemplate; + + private static $recurringAudienceListNameTemplate; + + private static $reportTaskNameTemplate; + + private static $pathTemplateMap; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/alpha_analytics_data_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_rest_client_config.php', + ], + ], + ]; + } + + private static function getAudienceListNameTemplate() + { + if (self::$audienceListNameTemplate == null) { + self::$audienceListNameTemplate = new PathTemplate('properties/{property}/audienceLists/{audience_list}'); + } + + return self::$audienceListNameTemplate; + } + + private static function getPropertyNameTemplate() + { + if (self::$propertyNameTemplate == null) { + self::$propertyNameTemplate = new PathTemplate('properties/{property}'); + } + + return self::$propertyNameTemplate; + } + + private static function getRecurringAudienceListNameTemplate() + { + if (self::$recurringAudienceListNameTemplate == null) { + self::$recurringAudienceListNameTemplate = new PathTemplate('properties/{property}/recurringAudienceLists/{recurring_audience_list}'); + } + + return self::$recurringAudienceListNameTemplate; + } + + private static function getReportTaskNameTemplate() + { + if (self::$reportTaskNameTemplate == null) { + self::$reportTaskNameTemplate = new PathTemplate('properties/{property}/reportTasks/{report_task}'); + } + + return self::$reportTaskNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'audienceList' => self::getAudienceListNameTemplate(), + 'property' => self::getPropertyNameTemplate(), + 'recurringAudienceList' => self::getRecurringAudienceListNameTemplate(), + 'reportTask' => self::getReportTaskNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * audience_list resource. + * + * @param string $property + * @param string $audienceList + * + * @return string The formatted audience_list resource. + * + * @experimental + */ + public static function audienceListName($property, $audienceList) + { + return self::getAudienceListNameTemplate()->render([ + 'property' => $property, + 'audience_list' => $audienceList, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a property + * resource. + * + * @param string $property + * + * @return string The formatted property resource. + * + * @experimental + */ + public static function propertyName($property) + { + return self::getPropertyNameTemplate()->render([ + 'property' => $property, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * recurring_audience_list resource. + * + * @param string $property + * @param string $recurringAudienceList + * + * @return string The formatted recurring_audience_list resource. + * + * @experimental + */ + public static function recurringAudienceListName($property, $recurringAudienceList) + { + return self::getRecurringAudienceListNameTemplate()->render([ + 'property' => $property, + 'recurring_audience_list' => $recurringAudienceList, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a report_task + * resource. + * + * @param string $property + * @param string $reportTask + * + * @return string The formatted report_task resource. + * + * @experimental + */ + public static function reportTaskName($property, $reportTask) + { + return self::getReportTaskNameTemplate()->render([ + 'property' => $property, + 'report_task' => $reportTask, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - audienceList: properties/{property}/audienceLists/{audience_list} + * - property: properties/{property} + * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} + * - reportTask: properties/{property}/reportTasks/{report_task} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + * + * @experimental + */ + public static function parseName($formattedName, $template = null) + { + $templateMap = self::getPathTemplateMap(); + if ($template) { + if (!isset($templateMap[$template])) { + throw new ValidationException("Template name $template does not exist"); + } + + return $templateMap[$template]->match($formattedName); + } + + foreach ($templateMap as $templateName => $pathTemplate) { + try { + return $pathTemplate->match($formattedName); + } catch (ValidationException $ex) { + // Swallow the exception to continue trying other path templates + } + } + + throw new ValidationException("Input did not match any known format. Input: $formattedName"); + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + * + * @experimental + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + * + * @experimental + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'analyticsdata.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + * + * @experimental + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** + * Creates an audience list for later retrieval. This method quickly returns + * the audience list's resource name and initiates a long running asynchronous + * request to form an audience list. To list the users in an audience list, + * first create the audience list through this method and then send the + * audience resource name to the `QueryAudienceList` method. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * An audience list is a snapshot of the users currently in the audience at + * the time of audience list creation. Creating audience lists for one + * audience on different days will return different results as users enter and + * exit the audience. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. Audience lists contain + * the users in each audience. + * + * This method is available at beta stability at + * [audienceExports.create](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/create). + * To give your feedback on this API, complete the [Google Analytics Audience + * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * $audienceList = new AudienceList(); + * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceList'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent resource where this audience list will be created. + * Format: `properties/{property}` + * @param AudienceList $audienceList Required. The audience list to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createAudienceList($parent, $audienceList, array $optionalArgs = []) + { + $request = new CreateAudienceListRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setAudienceList($audienceList); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('CreateAudienceList', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Creates a recurring audience list. Recurring audience lists produces new + * audience lists each day. Audience lists are users in an audience at the + * time of the list's creation. + * + * A recurring audience list ensures that you have audience list based on the + * most recent data available for use each day. If you manually create + * audience list, you don't know when an audience list based on an additional + * day's data is available. This recurring audience list automates the + * creation of an audience list when an additional day's data is available. + * You will consume fewer quota tokens by using recurring audience list versus + * manually creating audience list at various times of day trying to guess + * when an additional day's data is ready. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * $recurringAudienceList = new RecurringAudienceList(); + * $response = $alphaAnalyticsDataClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent resource where this recurring audience list will be + * created. Format: `properties/{property}` + * @param RecurringAudienceList $recurringAudienceList Required. The recurring audience list to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createRecurringAudienceList($parent, $recurringAudienceList, array $optionalArgs = []) + { + $request = new CreateRecurringAudienceListRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setRecurringAudienceList($recurringAudienceList); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateRecurringAudienceList', RecurringAudienceList::class, $optionalArgs, $request)->wait(); + } + + /** + * Initiates the creation of a report task. This method quickly + * returns a report task and initiates a long running + * asynchronous request to form a customized report of your Google Analytics + * event data. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * $reportTask = new ReportTask(); + * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createReportTask'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * @param ReportTask $reportTask Required. The report task configuration to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createReportTask($parent, $reportTask, array $optionalArgs = []) + { + $request = new CreateReportTaskRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setReportTask($reportTask); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('CreateReportTask', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Gets configuration metadata about a specific audience list. This method + * can be used to understand an audience list after it has been created. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * This method is available at beta stability at + * [audienceExports.get](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/get). + * To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedName = $alphaAnalyticsDataClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + * $response = $alphaAnalyticsDataClient->getAudienceList($formattedName); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The audience list resource name. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\AudienceList + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getAudienceList($name, array $optionalArgs = []) + { + $request = new GetAudienceListRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetAudienceList', AudienceList::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets configuration metadata about a specific recurring audience list. This + * method can be used to understand a recurring audience list's state after it + * has been created. For example, a recurring audience list resource will + * generate audience list instances for each day, and this method can be used + * to get the resource name of the most recent audience list instance. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedName = $alphaAnalyticsDataClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); + * $response = $alphaAnalyticsDataClient->getRecurringAudienceList($formattedName); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The recurring audience list resource name. + * Format: + * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getRecurringAudienceList($name, array $optionalArgs = []) + { + $request = new GetRecurringAudienceListRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetRecurringAudienceList', RecurringAudienceList::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets report metadata about a specific report task. After creating a report + * task, use this method to check its processing state or inspect its + * report definition. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedName = $alphaAnalyticsDataClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + * $response = $alphaAnalyticsDataClient->getReportTask($formattedName); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\ReportTask + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getReportTask($name, array $optionalArgs = []) + { + $request = new GetReportTaskRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetReportTask', ReportTask::class, $optionalArgs, $request)->wait(); + } + + /** + * Lists all audience lists for a property. This method can be used for you to + * find and reuse existing audience lists rather than creating unnecessary new + * audience lists. The same audience can have multiple audience lists that + * represent the list of users that were in an audience on different days. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * This method is available at beta stability at + * [audienceExports.list](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/list). + * To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * // Iterate over pages of elements + * $pagedResponse = $alphaAnalyticsDataClient->listAudienceLists($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $alphaAnalyticsDataClient->listAudienceLists($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. All audience lists for this property will be listed in the + * response. Format: `properties/{property}` + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listAudienceLists($parent, array $optionalArgs = []) + { + $request = new ListAudienceListsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListAudienceLists', $optionalArgs, ListAudienceListsResponse::class, $request); + } + + /** + * Lists all recurring audience lists for a property. This method can be used + * for you to find and reuse existing recurring audience lists rather than + * creating unnecessary new recurring audience lists. The same audience can + * have multiple recurring audience lists that represent different dimension + * combinations; for example, just the dimension `deviceId` or both the + * dimensions `deviceId` and `userId`. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * // Iterate over pages of elements + * $pagedResponse = $alphaAnalyticsDataClient->listRecurringAudienceLists($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $alphaAnalyticsDataClient->listRecurringAudienceLists($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. All recurring audience lists for this property will be listed in + * the response. Format: `properties/{property}` + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listRecurringAudienceLists($parent, array $optionalArgs = []) + { + $request = new ListRecurringAudienceListsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListRecurringAudienceLists', $optionalArgs, ListRecurringAudienceListsResponse::class, $request); + } + + /** + * Lists all report tasks for a property. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * // Iterate over pages of elements + * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listReportTasks($parent, array $optionalArgs = []) + { + $request = new ListReportTasksRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListReportTasks', $optionalArgs, ListReportTasksResponse::class, $request); + } + + /** + * Retrieves an audience list of users. After creating an audience, the users + * are not immediately available for listing. First, a request to + * `CreateAudienceList` is necessary to create an audience list of users, and + * then second, this method is used to retrieve the users in the audience + * list. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * This method is available at beta stability at + * [audienceExports.query](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/query). + * To give your feedback on this API, complete the [Google Analytics Audience + * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $name = 'name'; + * $response = $alphaAnalyticsDataClient->queryAudienceList($name); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @param array $optionalArgs { + * Optional. + * + * @type int $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\QueryAudienceListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function queryAudienceList($name, array $optionalArgs = []) + { + $request = new QueryAudienceListRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('QueryAudienceList', QueryAudienceListResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Retrieves a report task's content. After requesting the `CreateReportTask`, + * you are able to retrieve the report content once the report is + * ACTIVE. This method will return an error if the report task's state is not + * `ACTIVE`. A query response will return the tabular row & column values of + * the report. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $name = 'name'; + * $response = $alphaAnalyticsDataClient->queryReportTask($name); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * @param array $optionalArgs { + * Optional. + * + * @type int $offset + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\QueryReportTaskResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function queryReportTask($name, array $optionalArgs = []) + { + $request = new QueryReportTaskRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('QueryReportTask', QueryReportTaskResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * 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). + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the [Google Analytics Data API Funnel + * Reporting + * Feedback](https://docs.google.com/forms/d/e/1FAIpQLSdwOlQDJAUoBiIgUZZ3S_Lwi8gr7Bb0k1jhvc-DEg7Rol3UjA/viewform). + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $response = $alphaAnalyticsDataClient->runFunnelReport(); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $property + * Optional. 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 + * @type DateRange[] $dateRanges + * Optional. 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. + * @type Funnel $funnel + * Optional. The configuration of this request's funnel. This funnel + * configuration is required. + * @type FunnelBreakdown $funnelBreakdown + * Optional. 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. + * @type FunnelNextAction $funnelNextAction + * Optional. 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 next + * action of the `eventName` dimension will create rows for several events + * (for example `session_start` & `click`) and the total. + * + * Next action only supports `eventName` and most Page / Screen dimensions + * like `pageTitle` and `pagePath`. + * @type int $funnelVisualizationType + * Optional. The funnel visualization type controls the dimensions present in + * the funnel visualization sub report response. If not specified, + * `STANDARD_FUNNEL` is used. + * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1alpha\RunFunnelReportRequest\FunnelVisualizationType} + * @type Segment[] $segments + * Optional. 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. + * @type int $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * @type FilterExpression $dimensionFilter + * Optional. 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. + * @type bool $returnPropertyQuota + * Optional. Toggles whether to return the current state of this Analytics + * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\RunFunnelReportResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function runFunnelReport(array $optionalArgs = []) + { + $request = new RunFunnelReportRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['dateRanges'])) { + $request->setDateRanges($optionalArgs['dateRanges']); + } + + if (isset($optionalArgs['funnel'])) { + $request->setFunnel($optionalArgs['funnel']); + } + + if (isset($optionalArgs['funnelBreakdown'])) { + $request->setFunnelBreakdown($optionalArgs['funnelBreakdown']); + } + + if (isset($optionalArgs['funnelNextAction'])) { + $request->setFunnelNextAction($optionalArgs['funnelNextAction']); + } + + if (isset($optionalArgs['funnelVisualizationType'])) { + $request->setFunnelVisualizationType($optionalArgs['funnelVisualizationType']); + } + + if (isset($optionalArgs['segments'])) { + $request->setSegments($optionalArgs['segments']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + if (isset($optionalArgs['dimensionFilter'])) { + $request->setDimensionFilter($optionalArgs['dimensionFilter']); + } + + if (isset($optionalArgs['returnPropertyQuota'])) { + $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('RunFunnelReport', RunFunnelReportResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Exports an audience list of users to a Google Sheet. After creating an + * audience, the users are not immediately available for listing. First, a + * request to `CreateAudienceList` is necessary to create an audience list of + * users, and then second, this method is used to export those users in the + * audience list to a Google Sheet. + * + * See [Creating an Audience + * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Lists with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * This method is introduced at alpha stability with the intention of + * gathering feedback on syntax and capabilities before entering beta. To give + * your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedName = $alphaAnalyticsDataClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + * $response = $alphaAnalyticsDataClient->sheetExportAudienceList($formattedName); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the audience list to retrieve users from. + * Format: `properties/{property}/audienceLists/{audience_list}` + * @param array $optionalArgs { + * Optional. + * + * @type int $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\SheetExportAudienceListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function sheetExportAudienceList($name, array $optionalArgs = []) + { + $request = new SheetExportAudienceListRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SheetExportAudienceList', SheetExportAudienceListResponse::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json new file mode 100644 index 00000000000..6b8b6ebe92b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json @@ -0,0 +1,83 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.analytics.data.v1alpha", + "libraryPackage": "Google\\Analytics\\Data\\V1alpha", + "services": { + "AlphaAnalyticsData": { + "clients": { + "grpc": { + "libraryClient": "AlphaAnalyticsDataGapicClient", + "rpcs": { + "CreateAudienceList": { + "methods": [ + "createAudienceList" + ] + }, + "CreateRecurringAudienceList": { + "methods": [ + "createRecurringAudienceList" + ] + }, + "CreateReportTask": { + "methods": [ + "createReportTask" + ] + }, + "GetAudienceList": { + "methods": [ + "getAudienceList" + ] + }, + "GetRecurringAudienceList": { + "methods": [ + "getRecurringAudienceList" + ] + }, + "GetReportTask": { + "methods": [ + "getReportTask" + ] + }, + "ListAudienceLists": { + "methods": [ + "listAudienceLists" + ] + }, + "ListRecurringAudienceLists": { + "methods": [ + "listRecurringAudienceLists" + ] + }, + "ListReportTasks": { + "methods": [ + "listReportTasks" + ] + }, + "QueryAudienceList": { + "methods": [ + "queryAudienceList" + ] + }, + "QueryReportTask": { + "methods": [ + "queryReportTask" + ] + }, + "RunFunnelReport": { + "methods": [ + "runFunnelReport" + ] + }, + "SheetExportAudienceList": { + "methods": [ + "sheetExportAudienceList" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json new file mode 100644 index 00000000000..730a2dea65b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json @@ -0,0 +1,109 @@ +{ + "interfaces": { + "google.analytics.data.v1alpha.AlphaAnalyticsData": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNKNOWN" + ], + "no_retry_1_codes": [] + }, + "retry_params": { + "no_retry_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 0, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 0, + "total_timeout_millis": 0 + }, + "retry_policy_1_params": { + "initial_retry_delay_millis": 1000, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 60000, + "initial_rpc_timeout_millis": 60000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 60000, + "total_timeout_millis": 60000 + }, + "no_retry_1_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 60000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 60000, + "total_timeout_millis": 60000 + } + }, + "methods": { + "CreateAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateRecurringAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetRecurringAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListAudienceLists": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListRecurringAudienceLists": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListReportTasks": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "QueryAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "QueryReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "RunFunnelReport": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "SheetExportAudienceList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + } + } + } + } +} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php new file mode 100644 index 00000000000..6903c5bf2ef --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php @@ -0,0 +1,228 @@ + [ + 'google.analytics.data.v1alpha.AlphaAnalyticsData' => [ + 'CreateAudienceList' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Analytics\Data\V1alpha\AudienceList', + 'metadataReturnType' => '\Google\Analytics\Data\V1alpha\AudienceListMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateReportTask' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Analytics\Data\V1alpha\ReportTask', + 'metadataReturnType' => '\Google\Analytics\Data\V1alpha\ReportTaskMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateRecurringAudienceList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\RecurringAudienceList', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'GetAudienceList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\AudienceList', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetRecurringAudienceList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\RecurringAudienceList', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetReportTask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ReportTask', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListAudienceLists' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getAudienceLists', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ListAudienceListsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListRecurringAudienceLists' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getRecurringAudienceLists', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ListRecurringAudienceListsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListReportTasks' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getReportTasks', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ListReportTasksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'QueryAudienceList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\QueryAudienceListResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'QueryReportTask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\QueryReportTaskResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'RunFunnelReport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\RunFunnelReportResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'SheetExportAudienceList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\SheetExportAudienceListResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'audienceList' => 'properties/{property}/audienceLists/{audience_list}', + 'property' => 'properties/{property}', + 'recurringAudienceList' => 'properties/{property}/recurringAudienceLists/{recurring_audience_list}', + 'reportTask' => 'properties/{property}/reportTasks/{report_task}', + ], + ], + ], +]; diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php new file mode 100644 index 00000000000..6b05bd39065 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php @@ -0,0 +1,179 @@ + [ + 'google.analytics.data.v1alpha.AlphaAnalyticsData' => [ + 'CreateAudienceList' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/audienceLists', + 'body' => 'audience_list', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateRecurringAudienceList' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/recurringAudienceLists', + 'body' => 'recurring_audience_list', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateReportTask' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', + 'body' => 'report_task', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'GetAudienceList' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetRecurringAudienceList' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{name=properties/*/recurringAudienceLists/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetReportTask' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListAudienceLists' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/audienceLists', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListRecurringAudienceLists' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/recurringAudienceLists', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListReportTasks' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'QueryAudienceList' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}:query', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'QueryReportTask' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}:query', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'RunFunnelReport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{property=properties/*}:runFunnelReport', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'SheetExportAudienceList' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}:exportSheet', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php new file mode 100644 index 00000000000..c915f17b643 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php @@ -0,0 +1,1062 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return AlphaAnalyticsDataClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new AlphaAnalyticsDataClient($options); + } + + /** @test */ + public function createAudienceListTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $recurringAudienceList = 'recurringAudienceList2056789015'; + $expectedResponse = new AudienceList(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $expectedResponse->setRecurringAudienceList($recurringAudienceList); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createAudienceListTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceList = new AudienceList(); + $audienceListAudience = 'audienceListAudience867162342'; + $audienceList->setAudience($audienceListAudience); + $audienceListDimensions = []; + $audienceList->setDimensions($audienceListDimensions); + $response = $gapicClient->createAudienceList($formattedParent, $audienceList); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getAudienceList(); + $this->assertProtobufEquals($audienceList, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createAudienceListExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceList = new AudienceList(); + $audienceListAudience = 'audienceListAudience867162342'; + $audienceList->setAudience($audienceListAudience); + $audienceListDimensions = []; + $audienceList->setDimensions($audienceListDimensions); + $response = $gapicClient->createAudienceList($formattedParent, $audienceList); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createRecurringAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $activeDaysRemaining = 1427137945; + $expectedResponse = new RecurringAudienceList(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $recurringAudienceList = new RecurringAudienceList(); + $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; + $recurringAudienceList->setAudience($recurringAudienceListAudience); + $recurringAudienceListDimensions = []; + $recurringAudienceList->setDimensions($recurringAudienceListDimensions); + $response = $gapicClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateRecurringAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRecurringAudienceList(); + $this->assertProtobufEquals($recurringAudienceList, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createRecurringAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $recurringAudienceList = new RecurringAudienceList(); + $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; + $recurringAudienceList->setAudience($recurringAudienceListAudience); + $recurringAudienceListDimensions = []; + $recurringAudienceList->setDimensions($recurringAudienceListDimensions); + try { + $gapicClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createReportTaskTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createReportTaskTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $response = $gapicClient->createReportTask($formattedParent, $reportTask); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getReportTask(); + $this->assertProtobufEquals($reportTask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createReportTaskExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $response = $gapicClient->createReportTask($formattedParent, $reportTask); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function getAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $recurringAudienceList = 'recurringAudienceList2056789015'; + $expectedResponse = new AudienceList(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $expectedResponse->setRecurringAudienceList($recurringAudienceList); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $response = $gapicClient->getAudienceList($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + try { + $gapicClient->getAudienceList($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getRecurringAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $activeDaysRemaining = 1427137945; + $expectedResponse = new RecurringAudienceList(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); + $response = $gapicClient->getRecurringAudienceList($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetRecurringAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getRecurringAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); + try { + $gapicClient->getRecurringAudienceList($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $response = $gapicClient->getReportTask($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + try { + $gapicClient->getReportTask($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceListsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $audienceListsElement = new AudienceList(); + $audienceLists = [ + $audienceListsElement, + ]; + $expectedResponse = new ListAudienceListsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setAudienceLists($audienceLists); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $response = $gapicClient->listAudienceLists($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getAudienceLists()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListAudienceLists', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceListsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + try { + $gapicClient->listAudienceLists($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRecurringAudienceListsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $recurringAudienceListsElement = new RecurringAudienceList(); + $recurringAudienceLists = [ + $recurringAudienceListsElement, + ]; + $expectedResponse = new ListRecurringAudienceListsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setRecurringAudienceLists($recurringAudienceLists); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $response = $gapicClient->listRecurringAudienceLists($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getRecurringAudienceLists()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListRecurringAudienceLists', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRecurringAudienceListsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + try { + $gapicClient->listRecurringAudienceLists($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $reportTasksElement = new ReportTask(); + $reportTasks = [ + $reportTasksElement, + ]; + $expectedResponse = new ListReportTasksResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setReportTasks($reportTasks); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $response = $gapicClient->listReportTasks($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + try { + $gapicClient->listReportTasks($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryAudienceListResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $response = $gapicClient->queryAudienceList($name); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + try { + $gapicClient->queryAudienceList($name); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryReportTaskResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $response = $gapicClient->queryReportTask($name); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + try { + $gapicClient->queryReportTask($name); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runFunnelReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new RunFunnelReportResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->runFunnelReport(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/RunFunnelReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runFunnelReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->runFunnelReport(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function sheetExportAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $spreadsheetUri = 'spreadsheetUri-1521055111'; + $spreadsheetId = 'spreadsheetId1336406638'; + $rowCount = 1340416618; + $expectedResponse = new SheetExportAudienceListResponse(); + $expectedResponse->setSpreadsheetUri($spreadsheetUri); + $expectedResponse->setSpreadsheetId($spreadsheetId); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $response = $gapicClient->sheetExportAudienceList($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/SheetExportAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function sheetExportAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + try { + $gapicClient->sheetExportAudienceList($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php new file mode 100644 index 00000000000..27ed731150f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php @@ -0,0 +1,1219 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return AlphaAnalyticsDataClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new AlphaAnalyticsDataClient($options); + } + + /** @test */ + public function createAudienceListTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $recurringAudienceList = 'recurringAudienceList2056789015'; + $expectedResponse = new AudienceList(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $expectedResponse->setRecurringAudienceList($recurringAudienceList); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createAudienceListTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceList = new AudienceList(); + $audienceListAudience = 'audienceListAudience867162342'; + $audienceList->setAudience($audienceListAudience); + $audienceListDimensions = []; + $audienceList->setDimensions($audienceListDimensions); + $request = (new CreateAudienceListRequest()) + ->setParent($formattedParent) + ->setAudienceList($audienceList); + $response = $gapicClient->createAudienceList($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getAudienceList(); + $this->assertProtobufEquals($audienceList, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createAudienceListExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceList = new AudienceList(); + $audienceListAudience = 'audienceListAudience867162342'; + $audienceList->setAudience($audienceListAudience); + $audienceListDimensions = []; + $audienceList->setDimensions($audienceListDimensions); + $request = (new CreateAudienceListRequest()) + ->setParent($formattedParent) + ->setAudienceList($audienceList); + $response = $gapicClient->createAudienceList($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createRecurringAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $activeDaysRemaining = 1427137945; + $expectedResponse = new RecurringAudienceList(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $recurringAudienceList = new RecurringAudienceList(); + $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; + $recurringAudienceList->setAudience($recurringAudienceListAudience); + $recurringAudienceListDimensions = []; + $recurringAudienceList->setDimensions($recurringAudienceListDimensions); + $request = (new CreateRecurringAudienceListRequest()) + ->setParent($formattedParent) + ->setRecurringAudienceList($recurringAudienceList); + $response = $gapicClient->createRecurringAudienceList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateRecurringAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRecurringAudienceList(); + $this->assertProtobufEquals($recurringAudienceList, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createRecurringAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $recurringAudienceList = new RecurringAudienceList(); + $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; + $recurringAudienceList->setAudience($recurringAudienceListAudience); + $recurringAudienceListDimensions = []; + $recurringAudienceList->setDimensions($recurringAudienceListDimensions); + $request = (new CreateRecurringAudienceListRequest()) + ->setParent($formattedParent) + ->setRecurringAudienceList($recurringAudienceList); + try { + $gapicClient->createRecurringAudienceList($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createReportTaskTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createReportTaskTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $request = (new CreateReportTaskRequest()) + ->setParent($formattedParent) + ->setReportTask($reportTask); + $response = $gapicClient->createReportTask($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getReportTask(); + $this->assertProtobufEquals($reportTask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createReportTaskExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $request = (new CreateReportTaskRequest()) + ->setParent($formattedParent) + ->setReportTask($reportTask); + $response = $gapicClient->createReportTask($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function getAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $recurringAudienceList = 'recurringAudienceList2056789015'; + $expectedResponse = new AudienceList(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $expectedResponse->setRecurringAudienceList($recurringAudienceList); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $request = (new GetAudienceListRequest()) + ->setName($formattedName); + $response = $gapicClient->getAudienceList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $request = (new GetAudienceListRequest()) + ->setName($formattedName); + try { + $gapicClient->getAudienceList($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getRecurringAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $activeDaysRemaining = 1427137945; + $expectedResponse = new RecurringAudienceList(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); + $request = (new GetRecurringAudienceListRequest()) + ->setName($formattedName); + $response = $gapicClient->getRecurringAudienceList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetRecurringAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getRecurringAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); + $request = (new GetRecurringAudienceListRequest()) + ->setName($formattedName); + try { + $gapicClient->getRecurringAudienceList($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $request = (new GetReportTaskRequest()) + ->setName($formattedName); + $response = $gapicClient->getReportTask($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $request = (new GetReportTaskRequest()) + ->setName($formattedName); + try { + $gapicClient->getReportTask($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceListsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $audienceListsElement = new AudienceList(); + $audienceLists = [ + $audienceListsElement, + ]; + $expectedResponse = new ListAudienceListsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setAudienceLists($audienceLists); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListAudienceListsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listAudienceLists($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getAudienceLists()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListAudienceLists', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceListsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListAudienceListsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listAudienceLists($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRecurringAudienceListsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $recurringAudienceListsElement = new RecurringAudienceList(); + $recurringAudienceLists = [ + $recurringAudienceListsElement, + ]; + $expectedResponse = new ListRecurringAudienceListsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setRecurringAudienceLists($recurringAudienceLists); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListRecurringAudienceListsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listRecurringAudienceLists($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getRecurringAudienceLists()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListRecurringAudienceLists', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRecurringAudienceListsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListRecurringAudienceListsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listRecurringAudienceLists($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $reportTasksElement = new ReportTask(); + $reportTasks = [ + $reportTasksElement, + ]; + $expectedResponse = new ListReportTasksResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setReportTasks($reportTasks); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListReportTasksRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listReportTasks($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListReportTasksRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listReportTasks($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryAudienceListResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $request = (new QueryAudienceListRequest()) + ->setName($name); + $response = $gapicClient->queryAudienceList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + $request = (new QueryAudienceListRequest()) + ->setName($name); + try { + $gapicClient->queryAudienceList($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryReportTaskResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $request = (new QueryReportTaskRequest()) + ->setName($name); + $response = $gapicClient->queryReportTask($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + $request = (new QueryReportTaskRequest()) + ->setName($name); + try { + $gapicClient->queryReportTask($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runFunnelReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new RunFunnelReportResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new RunFunnelReportRequest(); + $response = $gapicClient->runFunnelReport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/RunFunnelReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runFunnelReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new RunFunnelReportRequest(); + try { + $gapicClient->runFunnelReport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function sheetExportAudienceListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $spreadsheetUri = 'spreadsheetUri-1521055111'; + $spreadsheetId = 'spreadsheetId1336406638'; + $rowCount = 1340416618; + $expectedResponse = new SheetExportAudienceListResponse(); + $expectedResponse->setSpreadsheetUri($spreadsheetUri); + $expectedResponse->setSpreadsheetId($spreadsheetId); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $request = (new SheetExportAudienceListRequest()) + ->setName($formattedName); + $response = $gapicClient->sheetExportAudienceList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/SheetExportAudienceList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function sheetExportAudienceListExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); + $request = (new SheetExportAudienceListRequest()) + ->setName($formattedName); + try { + $gapicClient->sheetExportAudienceList($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createAudienceListAsyncTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $recurringAudienceList = 'recurringAudienceList2056789015'; + $expectedResponse = new AudienceList(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $expectedResponse->setRecurringAudienceList($recurringAudienceList); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createAudienceListTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceList = new AudienceList(); + $audienceListAudience = 'audienceListAudience867162342'; + $audienceList->setAudience($audienceListAudience); + $audienceListDimensions = []; + $audienceList->setDimensions($audienceListDimensions); + $request = (new CreateAudienceListRequest()) + ->setParent($formattedParent) + ->setAudienceList($audienceList); + $response = $gapicClient->createAudienceListAsync($request)->wait(); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getAudienceList(); + $this->assertProtobufEquals($audienceList, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php new file mode 100644 index 0000000000000000000000000000000000000000..97e6fc78757970226441983404c768b1d2781063 GIT binary patch literal 10331 zcmeHN&2JRR72o#QX8eqeU0^d9$o4iY7#3z0o6i9+^w`GsE(^vuB#Ioh+B4;Gi*fhR z-2+Tk&LNkLl3Q}v%bs$}CAlS1E|GGGA`X#~+>j!1$Vw6aL87dbS5;j--80R6m_48< zzS!=r_v(HA>b+Ne<7Rcc3MbShYE#$rX-VCztNu1stFGfaMW>=}*0#2&s}`M|s#T$G zR#g}7sdw+KtBVUO>+d0{=hWOH&8ua{DOYIDw9QK0w~Ah_Wcp_A$%Rddzrv>mduo_f zE6aBPu+1InRm~z*msSg(;##&~V~I1{&?U2t1@`peg#s?P4p6L^o~MRy*-O1@!Dpc2 zPqnsLv5Knan<$2Q(((+;wtUO1SU*7h=F}~-;!$MMx^}B(7k$gIRYq{nF4E~Us^H1i zo~$}(k2zHex5`X}=Gj=Wed?m58w=Dcx>nV9+*Mqf&zGqm8kRkoJ`-%q*jZcZw2(2M zZxM1%_1zkc?yjmX^=qzuoy*M_?1q1BbZa_p#(ch^UV~dAkE(?(upMSe$M$+7oUd5a z_IsnbZP7}pK)1~&mgDwDx<-RQ>{`1!j$L+Zwr$zvjeAuV{=F#~`hVTR5cbWTYO=&U zZq9#X1yQ1xN?}mk#*~^4-N>AJ8veBmm-duP6{ZSPSkNQq4SdPY%|=^=tSRzeoG$K09eQ&ZE! zGaIL~LY8FXWEUg>xdi)msP7_xWm25MVJzI#*s>~!2$_BqXLu&to*qL0 z*DgM*qV1T(WD!P$0FuqXp4hCwA%@wZy(G6m# zW@`|-T>mZ0mK!jPx>3V5?J@>Qe|I^G6l;tiG1>N(B`wLu z(xdmB9fd(>Ys;g4W*^e0$OsHntR2hGr1`&h;2^pMVZt!WWtW!4Ns}2uwMS<<#2ES; z3H1gYxe7y$TcWP9S@$x)P4|BLD7(j&7wTjJMv67prFOAy6rB>y4D-mJgW;mHjZtEF zRa(sK=O&nL&vKpV315LK6iIPhcIp1ESFdLUS6)C`IV0Fnxq~zK5Y=prB9y#de3W=lO zz4nxA&Qo#$27OeqB7?dMl37Uan9r=8+K!hQ;O^{_2+KH5G}tZCI1HgS==z#1B6Wb= z!p#H3;KAB4_OZ_5u#aXkS>27eIojmjAs#>-j+oWp(7w+ifHka%_^vQ-^~*!aLv~L9dVHjrIhN%B>>6*G9X=7VT!+M|5*~@CHh&!?EOj z11Ud|*%Q~cLrLGfSE9=Ifh%Y0HfDRIEpM% z9I`}OVLb*jvm9p5!v}4f?>HyzXE+$SV|h&*gpfUtWuA%MmM;cVgzvRQdrhUrrhEZk-~;o?Dh!^u=@mx1s)sm&9pBDBomPo*$0f0OT_(0bU3(4%a&~vnZs~IZm`od zBg()j$r>9!eg%>ZN8o~mf+0Z8!f`?D*rM+@c&vIxaocpuw8Up6JepJFXtXnBX)m5H z_c2EA!U%O;$2D-w?qM$A-~^Lf?37{)PQf7@02eXSSf;RHVTIyd7Vjn%v92H2X$vsG z^+bP-KUmk-7maV_XG?Ym55&%H5?gg#Zld^Xn@Q7svY8-?#OZ zJGd&9|Ecmy|6J(_Dae(eMQ$3_$>;{UD7g##Z7`?odBSo!PVp z!8x=n$KZiw7Wy3hLe`XnY}^faG7U!=-Hl!!JTWVHwb9+^Trvr<;2|T{K7{d>H<)Cj zjnNv%AyHy8XK0rj&W`gU2Vj6pBu=sAcM8KefV8Q>AI^MEV4U5`#x7&YFBBN!g%vw- zNsnFER0sSE8OwfCyZEEO{p06-S?!FxZw?3IbCJY5yPJ3AKs>LUCBIQ%6nRCuEwYym zYHCldkamsBJga59kU1hE6a04y9FRSmXmC8zL5Qa1L8?w&l1LtwJ<&VEYzvjhLM_i_ zzo_Lp$-WtH)tT^rR^X828_~-n*SeD>N+Z?C?}aqb&HpCTtiiCHqoB0anY+9iKbf-!rvAtsmGZ^=_EN+3nO z(lcFP<{Mn-%i4ud=pZxeF~Nfrjc(0s{6_^y>lGyFAWbWURO4!UHIfJeJ?6L`SG1W< zdK6o(teGNTWArE0z@4H$iAE}OTq+Z}XU~RTG-y9jp6k;sh3spN_80o3=vmG+onKt- zTiW@C+Pt-iJ1-}Rf@&onmM=j;L;j+`!G!ajbZ|%liPXLWY$Q?!zFdsv(^YLY)U7q2 zniR|7S@M`wK+LDV#SCj{GdpEi3xU+9r#?ly5mg~a8t&;v1@audkt@a0 zZhWV9uIrUqY>-NhU8xs-uK@c_PG(~$OY}%BOvDN${Az8L^-!zI_ihCrsFa-wUUFw0 zx11|e8$r@{a*b~Q8WKjoue;9FeWl-oQ{kp&31?%?I^tgZOBpf|fN#7X*&O8C&7KZF dNjfLKLyLU2#(E8_nDEIOUn#yP+l5_#{{oI-sW1Ql literal 0 HcmV?d00001 diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php new file mode 100644 index 0000000000000000000000000000000000000000..649e364c14ef6c8012712e1a949cb9a4ca0bab4f GIT binary patch literal 8211 zcmcIpU2_{(8ICMVkzU!dymlN%X@j~1;-p2Hx{!gSX}glvmJ(S~rFA~2r^{M8mbaC( zVt3`>GQD7c8E$|XE;`&Z!yP|?EB*jC+;kXjxMcVbyze=?tCcOwb|>V*(Vji$Iq&z^ zzW?Fya0uVdZLsbH8J_#{Hvr_Zj|2zw;auU|{r_Gc?*Px7{f0 z;9GjRx6P05DgN=j60JUaw}2ZS0knIDp2P6q>AeS|LEAO0L5>d82W_@-HzzP@@9m+5TtCkF1T{zyD1^Prz-2a4 zw^w3L+ct-;WjAo^!-rkw2I8ZYjl15p1ZN)PHUy0iAD$xean7|zEPQ(|XES$X4<2#4 z3E<1%7pLrdADA8;N~aTCyM?OR2sYBOJMiB}uy^NzN|D|W8}oto@?2v=d-8{nM9H(J zG3YW$0zigrSH~S}J(7!TB&7@_*q|d;=J?72%#)tiqx2;IG6Ja`b1?ETZo#s^=<`KK zH@X&wij}YYCK8d}fF;5Uza`jMIYMtIunVgo>8HR75@hrf5b|fphS_HW2bCXy2nOn~ z+VNlM>}NxpIkan?ZcS~zo1Z0~d;qEj2jxFUVP(p?^bDY9y<)cBHXOD-&*4A1GX!XnVjPuKwm zGzUkfWA68aWhdmn%s~dd4{sQ=C2d2}K=bX|)@aDhI<>huTVy98s;1+jR<|Hw*&dEC z#czgFhV;O4Lu_-uOl{^bM-@`^0OALnUC(xJUj(6ir4WaC5~utLtWM)qDne>3ZlSBc3&4DfpA-)$ho_J>2YL_Ht7@yIYh|T|qFnDH&sPb zn_}m@gz({&@#a|ew-H#JFhS`9^km!W>%vAzOqb$JdLI(5<((EW^b&F@EC5i#IN&i) z{yGL%>vo6Pg=0yDc%LT@FT%e!TiV{Syht|Q6AvWGAbWY`#)FF?1?9yUtO&88d1Sd> zct6MEeUchF49^ez%+psu6va|vz!FMRMX8#j`%t?CA%H)!UG9@932tqnZ zZ=O>F`J|q_BhOz@7?DjhU_#|F1;azVSt5%&9Ujmgm1+ZRc6Uc@R*GoIZ^4^IrKRc^ z1=L!rqE()$`oxwwDFs*k{n6~-BCrq^+EkfHpFoBy10z|F@s7hm1xL|*m5V7jd_|r= zw0xwjf{}^T7Ob2p?TPXz6le=+SRm6Ds@Ol4k*gTTBzDHh(~oOE#AwB}wtwvN@tq6t zK@rkAIB=LS%P0kWUX^hRi%L~k@eIo7c5T+>@z7b1p{UZE_h(-rOj8-3lfRAt6s<$c zc3VT%mVN+N+x*F|Db6Wa#8F9sMemqyQ`h5p<~fl=9Ck#X)Pywwq1$YT?2y>FnK^EzO|GlmCGhKEcgXNOe&X zqn=@#?y;Ax&Iwdufc*COw6qEfqGR*SfC9A8D%F?h&;ar0s`?avbI;wu6ko=NsC*ArrwNwsHrnk`ANli|+JyX795PLuR9FLt zp`95h9Ye~&I*QfMdzRzqJTF-|F0pmndd2mckZic=v=3R|K)qAB$vvNbb0Dv5F3(oP z$!qg1j)==Xpua=(%ULwnk!`a<`&e&V9fr<>ZMW!_*C6SlZRlU1v-AEfS)QXV`UWhp z{?I)}(hLU+kgNPilwRG2>&|HZGYncfrcU<|i9fV@9W>tc1nx?d=V{jykQ}2w>`_6D z4$Q|m&U%tZxN{ndmUoWCO5)7^bq;Qv$)ohE2xJYE;}N5as7ywRd`b9@{gc-v(!9d2 zLfY`AkjS%tjKK9X-bw3IvZByU3$FXrG8}0L`l)snQ8ayCYv@zJI)Wm~Zxp+IC~9yD zx8MzZhSgEut4~-66*hWc7lkEQ)WgS1=2q!GI;uixWy9h?oMu(H5H zgx?^)jgvy|BmDSyGqu;rlbfHwLb!{Ou0aaNqYu6xY8IkcW3RzN$HIBBcLz6?$Vse! zM`00%z1U2-#~+U@jP+P!xz^{{hUzp}>lh;Kr8dvuo*!=ETzce41y~9}9O9^)Uw$c! zEm)xu9FOlVde=`!82tPy;u5s%g6uH+2w7paZP|h=oXPVzPaJac#2DieuzP!OcWB{! zkcRKQ<8ivcXy+5l1<2vWVB-?-HMkj);3;y&Xyf8|@^eUq6?6>}C|n0eC>(|`rpaqZ_aPiCA84|91D4w($HlI=!w&d&4?IYsP0)pOrfb>9 zBBjfJh(cPp)c=_(KNb@qmx#r@@CzpAqC}a_A(bczsRc{>J*)jWw=XJP9IQ&HS9o}l zsN~BaUl15gUj0mn4M;6A+V$e(o?DPDRO`j3Y6&MqO6$~U1P36sI=*_Q)^=5WN7b;q zY+*IJ0!z4FthcmaaZdhc1l9s`DdN{PY%2u#)5(XRn;;OfZ%NinxY}AxLw7GU@Nmg?!gzHR;qPmlol87>99Jj z@Rhy`a#L-QXKCn$XUheN;0{+(GzEo%Lh${Pugu+Rz~ZE3z6m#q^_>PPuu!Rgoogle.analytics.data.v1beta.AudienceDimension + */ +class AudienceDimension extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $dimension_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * Optional. The API name of the dimension. See the [API + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) + * for the list of dimension names. + * + * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php new file mode 100644 index 00000000000..8681ff01f47 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1beta.AudienceDimensionValue + */ +class AudienceDimensionValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Value as a string if the dimension type is a string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->readOneof(1); + } + + public function hasValue() + { + return $this->hasOneof(1); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php new file mode 100644 index 00000000000..3630d8dfb88 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php @@ -0,0 +1,473 @@ +google.analytics.data.v1beta.AudienceExport + */ +class AudienceExport extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The audience export resource name assigned during + * creation. This resource name identifies this `AudienceExport`. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $audience = ''; + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $audience_display_name = ''; + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + private $dimensions; + /** + * Output only. The current state for this AudienceExport. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = null; + /** + * Output only. The time when CreateAudienceExport was called and the + * AudienceExport began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $begin_creating_time = null; + /** + * Output only. The total quota tokens charged during creation of the + * AudienceExport. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceExport + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $creation_quota_tokens_charged = 0; + /** + * Output only. The total number of rows in the AudienceExport result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $row_count = null; + /** + * Output only. Error message is populated when an audience export fails + * during creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $error_message = null; + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $percentage_completed = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The audience export resource name assigned during + * creation. This resource name identifies this `AudienceExport`. + * Format: `properties/{property}/audienceExports/{audience_export}` + * @type string $audience + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * @type string $audience_display_name + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * @type array<\Google\Analytics\Data\V1beta\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * Required. The dimensions requested and displayed in the query response. + * @type int $state + * Output only. The current state for this AudienceExport. + * @type \Google\Protobuf\Timestamp $begin_creating_time + * Output only. The time when CreateAudienceExport was called and the + * AudienceExport began the `CREATING` state. + * @type int $creation_quota_tokens_charged + * Output only. The total quota tokens charged during creation of the + * AudienceExport. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceExport + * enters the `ACTIVE` or `FAILED` states. + * @type int $row_count + * Output only. The total number of rows in the AudienceExport result. + * @type string $error_message + * Output only. Error message is populated when an audience export fails + * during creation. A common reason for such a failure is quota exhaustion. + * @type float $percentage_completed + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The audience export resource name assigned during + * creation. This resource name identifies this `AudienceExport`. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The audience export resource name assigned during + * creation. This resource name identifies this `AudienceExport`. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getAudience() + { + return $this->audience; + } + + /** + * Required. The audience resource name. This resource name identifies the + * audience being listed and is shared between the Analytics Data & Admin + * APIs. + * Format: `properties/{property}/audiences/{audience}` + * + * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setAudience($var) + { + GPBUtil::checkString($var, True); + $this->audience = $var; + + return $this; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getAudienceDisplayName() + { + return $this->audience_display_name; + } + + /** + * Output only. The descriptive display name for this audience. For example, + * "Purchasers". + * + * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setAudienceDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->audience_display_name = $var; + + return $this; + } + + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * Required. The dimensions requested and displayed in the query response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Analytics\Data\V1beta\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceDimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * Output only. The current state for this AudienceExport. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return isset($this->state) ? $this->state : 0; + } + + public function hasState() + { + return isset($this->state); + } + + public function clearState() + { + unset($this->state); + } + + /** + * Output only. The current state for this AudienceExport. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\AudienceExport\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. The time when CreateAudienceExport was called and the + * AudienceExport began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBeginCreatingTime() + { + return $this->begin_creating_time; + } + + public function hasBeginCreatingTime() + { + return isset($this->begin_creating_time); + } + + public function clearBeginCreatingTime() + { + unset($this->begin_creating_time); + } + + /** + * Output only. The time when CreateAudienceExport was called and the + * AudienceExport began the `CREATING` state. + * + * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBeginCreatingTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->begin_creating_time = $var; + + return $this; + } + + /** + * Output only. The total quota tokens charged during creation of the + * AudienceExport. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceExport + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getCreationQuotaTokensCharged() + { + return $this->creation_quota_tokens_charged; + } + + /** + * Output only. The total quota tokens charged during creation of the + * AudienceExport. Because this token count is based on activity from the + * `CREATING` state, this tokens charged will be fixed once an AudienceExport + * enters the `ACTIVE` or `FAILED` states. + * + * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setCreationQuotaTokensCharged($var) + { + GPBUtil::checkInt32($var); + $this->creation_quota_tokens_charged = $var; + + return $this; + } + + /** + * Output only. The total number of rows in the AudienceExport result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getRowCount() + { + return isset($this->row_count) ? $this->row_count : 0; + } + + public function hasRowCount() + { + return isset($this->row_count); + } + + public function clearRowCount() + { + unset($this->row_count); + } + + /** + * Output only. The total number of rows in the AudienceExport result. + * + * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * Output only. Error message is populated when an audience export fails + * during creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getErrorMessage() + { + return isset($this->error_message) ? $this->error_message : ''; + } + + public function hasErrorMessage() + { + return isset($this->error_message); + } + + public function clearErrorMessage() + { + unset($this->error_message); + } + + /** + * Output only. Error message is populated when an audience export fails + * during creation. A common reason for such a failure is quota exhaustion. + * + * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setErrorMessage($var) + { + GPBUtil::checkString($var, True); + $this->error_message = $var; + + return $this; + } + + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return float + */ + public function getPercentageCompleted() + { + return isset($this->percentage_completed) ? $this->percentage_completed : 0.0; + } + + public function hasPercentageCompleted() + { + return isset($this->percentage_completed); + } + + public function clearPercentageCompleted() + { + unset($this->percentage_completed); + } + + /** + * Output only. The percentage completed for this audience export ranging + * between 0 to 100. + * + * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param float $var + * @return $this + */ + public function setPercentageCompleted($var) + { + GPBUtil::checkDouble($var); + $this->percentage_completed = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php new file mode 100644 index 00000000000..334e8a4212f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php @@ -0,0 +1,75 @@ +google.analytics.data.v1beta.AudienceExport.State + */ +class State +{ + /** + * Unspecified state will never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The AudienceExport is currently creating and will be available in the + * future. Creating occurs immediately after the CreateAudienceExport call. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * The AudienceExport is fully created and ready for querying. An + * AudienceExport is updated to active asynchronously from a request; this + * occurs some time (for example 15 minutes) after the initial create call. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The AudienceExport failed to be created. It is possible that + * re-requesting this audience export will succeed. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + self::FAILED => 'FAILED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Analytics\Data\V1beta\AudienceExport_State::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php new file mode 100644 index 00000000000..1b70d333184 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php @@ -0,0 +1,33 @@ +google.analytics.data.v1beta.AudienceExportMetadata + */ +class AudienceExportMetadata extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php new file mode 100644 index 00000000000..e30895ff219 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php @@ -0,0 +1,71 @@ +google.analytics.data.v1beta.AudienceRow + */ +class AudienceRow extends \Google\Protobuf\Internal\Message +{ + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; + */ + private $dimension_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionValues() + { + return $this->dimension_values; + } + + /** + * Each dimension value attribute for an audience user. One dimension value + * will be added for each dimension column requested. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; + * @param array<\Google\Analytics\Data\V1beta\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceDimensionValue::class); + $this->dimension_values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php new file mode 100644 index 00000000000..1d487d14e74 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php @@ -0,0 +1,133 @@ +google.analytics.data.v1beta.BatchRunPivotReportsRequest + */ +class BatchRunPivotReportsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * 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). + * This property must be specified for the batch. The property within + * RunPivotReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * Individual requests. Each request has a separate pivot report response. + * Each batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; + */ + private $requests; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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). + * This property must be specified for the batch. The property within + * RunPivotReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * @type array<\Google\Analytics\Data\V1beta\RunPivotReportRequest>|\Google\Protobuf\Internal\RepeatedField $requests + * Individual requests. Each request has a separate pivot report response. + * Each batch request is allowed up to 5 requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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). + * This property must be specified for the batch. The property within + * RunPivotReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->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). + * This property must be specified for the batch. The property within + * RunPivotReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * Individual requests. Each request has a separate pivot report response. + * Each batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Individual requests. Each request has a separate pivot report response. + * Each batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; + * @param array<\Google\Analytics\Data\V1beta\RunPivotReportRequest>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunPivotReportRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php new file mode 100644 index 00000000000..3b7abe9c8ac --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php @@ -0,0 +1,109 @@ +google.analytics.data.v1beta.BatchRunPivotReportsResponse + */ +class BatchRunPivotReportsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Individual responses. Each response has a separate pivot report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; + */ + private $pivot_reports; + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 2; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\RunPivotReportResponse>|\Google\Protobuf\Internal\RepeatedField $pivot_reports + * Individual responses. Each response has a separate pivot report request. + * @type string $kind + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish + * between response types in JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Individual responses. Each response has a separate pivot report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPivotReports() + { + return $this->pivot_reports; + } + + /** + * Individual responses. Each response has a separate pivot report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; + * @param array<\Google\Analytics\Data\V1beta\RunPivotReportResponse>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPivotReports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunPivotReportResponse::class); + $this->pivot_reports = $arr; + + return $this; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 2; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 2; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php new file mode 100644 index 00000000000..5eebae015a4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php @@ -0,0 +1,133 @@ +google.analytics.data.v1beta.BatchRunReportsRequest + */ +class BatchRunReportsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * 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). + * This property must be specified for the batch. The property within + * RunReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * Individual requests. Each request has a separate report response. Each + * batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; + */ + private $requests; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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). + * This property must be specified for the batch. The property within + * RunReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * @type array<\Google\Analytics\Data\V1beta\RunReportRequest>|\Google\Protobuf\Internal\RepeatedField $requests + * Individual requests. Each request has a separate report response. Each + * batch request is allowed up to 5 requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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). + * This property must be specified for the batch. The property within + * RunReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->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). + * This property must be specified for the batch. The property within + * RunReportRequest may either be unspecified or consistent with this + * property. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * Individual requests. Each request has a separate report response. Each + * batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Individual requests. Each request has a separate report response. Each + * batch request is allowed up to 5 requests. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; + * @param array<\Google\Analytics\Data\V1beta\RunReportRequest>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunReportRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php new file mode 100644 index 00000000000..f45db6b80c2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php @@ -0,0 +1,109 @@ +google.analytics.data.v1beta.BatchRunReportsResponse + */ +class BatchRunReportsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Individual responses. Each response has a separate report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; + */ + private $reports; + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunReports". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 2; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\RunReportResponse>|\Google\Protobuf\Internal\RepeatedField $reports + * Individual responses. Each response has a separate report request. + * @type string $kind + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunReports". Useful to distinguish between + * response types in JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Individual responses. Each response has a separate report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getReports() + { + return $this->reports; + } + + /** + * Individual responses. Each response has a separate report request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; + * @param array<\Google\Analytics\Data\V1beta\RunReportResponse>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setReports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunReportResponse::class); + $this->reports = $arr; + + return $this; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunReports". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 2; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#batchRunReports". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 2; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php new file mode 100644 index 00000000000..dffa0b43fe7 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php @@ -0,0 +1,300 @@ +google.analytics.data.v1beta.CheckCompatibilityRequest + */ +class CheckCompatibilityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * A Google Analytics GA4 property identifier whose events are tracked. To + * learn more, see [where to find your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * `property` should be the same value as in your `runReport` request. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * The dimensions in this report. `dimensions` should be the same value as in + * your `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + */ + private $dimensions; + /** + * The metrics in this report. `metrics` should be the same value as in your + * `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + */ + private $metrics; + /** + * The filter clause of dimensions. `dimensionFilter` should be the same value + * as in your `runReport` request. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + */ + protected $dimension_filter = null; + /** + * The filter clause of metrics. `metricFilter` should be the same value as in + * your `runReport` request + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + */ + protected $metric_filter = null; + /** + * Filters the dimensions and metrics in the response to just this + * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` + * to only return compatible dimensions & metrics. + * + * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; + */ + protected $compatibility_filter = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $property + * A Google Analytics GA4 property identifier whose events are tracked. To + * learn more, see [where to find your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * `property` should be the same value as in your `runReport` request. + * Example: properties/1234 + * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * The dimensions in this report. `dimensions` should be the same value as in + * your `runReport` request. + * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics + * The metrics in this report. `metrics` should be the same value as in your + * `runReport` request. + * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter + * The filter clause of dimensions. `dimensionFilter` should be the same value + * as in your `runReport` request. + * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter + * The filter clause of metrics. `metricFilter` should be the same value as in + * your `runReport` request + * @type int $compatibility_filter + * Filters the dimensions and metrics in the response to just this + * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` + * to only return compatible dimensions & metrics. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * A Google Analytics GA4 property identifier whose events are tracked. To + * learn more, see [where to find your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * `property` should be the same value as in your `runReport` request. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->property; + } + + /** + * A Google Analytics GA4 property identifier whose events are tracked. To + * learn more, see [where to find your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * `property` should be the same value as in your `runReport` request. + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * The dimensions in this report. `dimensions` should be the same value as in + * your `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * The dimensions in this report. `dimensions` should be the same value as in + * your `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * The metrics in this report. `metrics` should be the same value as in your + * `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * The metrics in this report. `metrics` should be the same value as in your + * `runReport` request. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); + $this->metrics = $arr; + + return $this; + } + + /** + * The filter clause of dimensions. `dimensionFilter` should be the same value + * as in your `runReport` request. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * The filter clause of dimensions. `dimensionFilter` should be the same value + * as in your `runReport` request. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * The filter clause of metrics. `metricFilter` should be the same value as in + * your `runReport` request + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getMetricFilter() + { + return $this->metric_filter; + } + + public function hasMetricFilter() + { + return isset($this->metric_filter); + } + + public function clearMetricFilter() + { + unset($this->metric_filter); + } + + /** + * The filter clause of metrics. `metricFilter` should be the same value as in + * your `runReport` request + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setMetricFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->metric_filter = $var; + + return $this; + } + + /** + * Filters the dimensions and metrics in the response to just this + * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` + * to only return compatible dimensions & metrics. + * + * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; + * @return int + */ + public function getCompatibilityFilter() + { + return $this->compatibility_filter; + } + + /** + * Filters the dimensions and metrics in the response to just this + * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` + * to only return compatible dimensions & metrics. + * + * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; + * @param int $var + * @return $this + */ + public function setCompatibilityFilter($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); + $this->compatibility_filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php new file mode 100644 index 00000000000..09d73dc1bcd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php @@ -0,0 +1,101 @@ +google.analytics.data.v1beta.CheckCompatibilityResponse + */ +class CheckCompatibilityResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The compatibility of each dimension. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; + */ + private $dimension_compatibilities; + /** + * The compatibility of each metric. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; + */ + private $metric_compatibilities; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\DimensionCompatibility>|\Google\Protobuf\Internal\RepeatedField $dimension_compatibilities + * The compatibility of each dimension. + * @type array<\Google\Analytics\Data\V1beta\MetricCompatibility>|\Google\Protobuf\Internal\RepeatedField $metric_compatibilities + * The compatibility of each metric. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * The compatibility of each dimension. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionCompatibilities() + { + return $this->dimension_compatibilities; + } + + /** + * The compatibility of each dimension. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionCompatibility>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionCompatibilities($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionCompatibility::class); + $this->dimension_compatibilities = $arr; + + return $this; + } + + /** + * The compatibility of each metric. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricCompatibilities() + { + return $this->metric_compatibilities; + } + + /** + * The compatibility of each metric. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; + * @param array<\Google\Analytics\Data\V1beta\MetricCompatibility>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricCompatibilities($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricCompatibility::class); + $this->metric_compatibilities = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php new file mode 100644 index 00000000000..2af25ee8e36 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php @@ -0,0 +1,215 @@ +google.analytics.data.v1beta.Cohort + */ +class Cohort extends \Google\Protobuf\Internal\Message +{ + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + */ + protected $dimension = ''; + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; + */ + protected $date_range = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * @type string $dimension + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * @type \Google\Analytics\Data\V1beta\DateRange $date_range + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Assigns a name to this cohort. The dimension `cohort` is valued to this + * name in a report response. If set, cannot begin with `cohort_` or + * `RESERVED_`. If not set, cohorts are named by their zero based index + * `cohort_0`, `cohort_1`, etc. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + * @return string + */ + public function getDimension() + { + return $this->dimension; + } + + /** + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. + * + * Generated from protobuf field string dimension = 2; + * @param string $var + * @return $this + */ + public function setDimension($var) + { + GPBUtil::checkString($var, True); + $this->dimension = $var; + + return $this; + } + + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; + * @return \Google\Analytics\Data\V1beta\DateRange|null + */ + public function getDateRange() + { + return $this->date_range; + } + + public function hasDateRange() + { + return isset($this->date_range); + } + + public function clearDateRange() + { + unset($this->date_range); + } + + /** + * The cohort selects users whose first touch date is between start date and + * end date defined in the `dateRange`. This `dateRange` does not specify the + * full date range of event data that is present in a cohort report. In a + * cohort report, this `dateRange` is extended by the granularity and offset + * present in the `cohortsRange`; event data for the extended reporting date + * range is present in a cohort report. + * In a cohort request, this `dateRange` is required and the `dateRanges` in + * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. + * This `dateRange` should generally be aligned with the cohort's granularity. + * If `CohortsRange` uses daily granularity, this `dateRange` can be a single + * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be + * aligned to a week boundary, starting at Sunday and ending Saturday. If + * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to + * a month, starting at the first and ending on the last day of the month. + * + * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; + * @param \Google\Analytics\Data\V1beta\DateRange $var + * @return $this + */ + public function setDateRange($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DateRange::class); + $this->date_range = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php new file mode 100644 index 00000000000..18831386174 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php @@ -0,0 +1,71 @@ +google.analytics.data.v1beta.CohortReportSettings + */ +class CohortReportSettings extends \Google\Protobuf\Internal\Message +{ + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + */ + protected $accumulate = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $accumulate + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + * @return bool + */ + public function getAccumulate() + { + return $this->accumulate; + } + + /** + * If true, accumulates the result from first touch day to the end day. Not + * supported in `RunReportRequest`. + * + * Generated from protobuf field bool accumulate = 1; + * @param bool $var + * @return $this + */ + public function setAccumulate($var) + { + GPBUtil::checkBool($var); + $this->accumulate = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php new file mode 100644 index 00000000000..3fb245a459c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php @@ -0,0 +1,179 @@ +google.analytics.data.v1beta.CohortSpec + */ +class CohortSpec extends \Google\Protobuf\Internal\Message +{ + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; + */ + private $cohorts; + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; + */ + protected $cohorts_range = null; + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; + */ + protected $cohort_report_settings = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\Cohort>|\Google\Protobuf\Internal\RepeatedField $cohorts + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * @type \Google\Analytics\Data\V1beta\CohortsRange $cohorts_range + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * @type \Google\Analytics\Data\V1beta\CohortReportSettings $cohort_report_settings + * Optional settings for a cohort report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCohorts() + { + return $this->cohorts; + } + + /** + * Defines the selection criteria to group users into cohorts. + * Most cohort reports define only a single cohort. If multiple cohorts are + * specified, each cohort can be recognized in the report by their name. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; + * @param array<\Google\Analytics\Data\V1beta\Cohort>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCohorts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Cohort::class); + $this->cohorts = $arr; + + return $this; + } + + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; + * @return \Google\Analytics\Data\V1beta\CohortsRange|null + */ + public function getCohortsRange() + { + return $this->cohorts_range; + } + + public function hasCohortsRange() + { + return isset($this->cohorts_range); + } + + public function clearCohortsRange() + { + unset($this->cohorts_range); + } + + /** + * Cohort reports follow cohorts over an extended reporting date range. This + * range specifies an offset duration to follow the cohorts over. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; + * @param \Google\Analytics\Data\V1beta\CohortsRange $var + * @return $this + */ + public function setCohortsRange($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortsRange::class); + $this->cohorts_range = $var; + + return $this; + } + + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; + * @return \Google\Analytics\Data\V1beta\CohortReportSettings|null + */ + public function getCohortReportSettings() + { + return $this->cohort_report_settings; + } + + public function hasCohortReportSettings() + { + return isset($this->cohort_report_settings); + } + + public function clearCohortReportSettings() + { + unset($this->cohort_report_settings); + } + + /** + * Optional settings for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; + * @param \Google\Analytics\Data\V1beta\CohortReportSettings $var + * @return $this + */ + public function setCohortReportSettings($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortReportSettings::class); + $this->cohort_report_settings = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php new file mode 100644 index 00000000000..2877e4dbc3a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php @@ -0,0 +1,208 @@ +google.analytics.data.v1beta.CohortsRange + */ +class CohortsRange extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; + */ + protected $granularity = 0; + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + */ + protected $start_offset = 0; + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + */ + protected $end_offset = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $granularity + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * @type int $start_offset + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * @type int $end_offset + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; + * @return int + */ + public function getGranularity() + { + return $this->granularity; + } + + /** + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; + * @param int $var + * @return $this + */ + public function setGranularity($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\CohortsRange\Granularity::class); + $this->granularity = $var; + + return $this; + } + + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + * @return int + */ + public function getStartOffset() + { + return $this->start_offset; + } + + /** + * `startOffset` specifies the start date of the extended reporting date range + * for a cohort report. `startOffset` is commonly set to 0 so that reports + * contain data from the acquisition of the cohort forward. + * If `granularity` is `DAILY`, the `startDate` of the extended reporting date + * range is `startDate` of the cohort plus `startOffset` days. + * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 7` days. + * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting + * date range is `startDate` of the cohort plus `startOffset * 30` days. + * + * Generated from protobuf field int32 start_offset = 2; + * @param int $var + * @return $this + */ + public function setStartOffset($var) + { + GPBUtil::checkInt32($var); + $this->start_offset = $var; + + return $this; + } + + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + * @return int + */ + public function getEndOffset() + { + return $this->end_offset; + } + + /** + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is + * commonly set to 5 to 10 so that reports contain data on the cohort for the + * next several granularity time periods. + * If `granularity` is `DAILY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset` days. + * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 7` days. + * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date + * range is `endDate` of the cohort plus `endOffset * 30` days. + * + * Generated from protobuf field int32 end_offset = 3; + * @param int $var + * @return $this + */ + public function setEndOffset($var) + { + GPBUtil::checkInt32($var); + $this->end_offset = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php new file mode 100644 index 00000000000..541e282e316 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php @@ -0,0 +1,76 @@ +google.analytics.data.v1beta.CohortsRange.Granularity + */ +class Granularity +{ + /** + * Should never be specified. + * + * Generated from protobuf enum GRANULARITY_UNSPECIFIED = 0; + */ + const GRANULARITY_UNSPECIFIED = 0; + /** + * Daily granularity. Commonly used if the cohort's `dateRange` is a single + * day and the request contains `cohortNthDay`. + * + * Generated from protobuf enum DAILY = 1; + */ + const DAILY = 1; + /** + * Weekly granularity. Commonly used if the cohort's `dateRange` is a week + * in duration (starting on Sunday and ending on Saturday) and the request + * contains `cohortNthWeek`. + * + * Generated from protobuf enum WEEKLY = 2; + */ + const WEEKLY = 2; + /** + * Monthly granularity. Commonly used if the cohort's `dateRange` is a month + * in duration and the request contains `cohortNthMonth`. + * + * Generated from protobuf enum MONTHLY = 3; + */ + const MONTHLY = 3; + + private static $valueToName = [ + self::GRANULARITY_UNSPECIFIED => 'GRANULARITY_UNSPECIFIED', + self::DAILY => 'DAILY', + self::WEEKLY => 'WEEKLY', + self::MONTHLY => 'MONTHLY', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Granularity::class, \Google\Analytics\Data\V1beta\CohortsRange_Granularity::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php new file mode 100644 index 00000000000..6a97b7928ec --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php @@ -0,0 +1,63 @@ +google.analytics.data.v1beta.Compatibility + */ +class Compatibility +{ + /** + * Unspecified compatibility. + * + * Generated from protobuf enum COMPATIBILITY_UNSPECIFIED = 0; + */ + const COMPATIBILITY_UNSPECIFIED = 0; + /** + * The dimension or metric is compatible. This dimension or metric can be + * successfully added to a report. + * + * Generated from protobuf enum COMPATIBLE = 1; + */ + const COMPATIBLE = 1; + /** + * The dimension or metric is incompatible. This dimension or metric cannot be + * successfully added to a report. + * + * Generated from protobuf enum INCOMPATIBLE = 2; + */ + const INCOMPATIBLE = 2; + + private static $valueToName = [ + self::COMPATIBILITY_UNSPECIFIED => 'COMPATIBILITY_UNSPECIFIED', + self::COMPATIBLE => 'COMPATIBLE', + self::INCOMPATIBLE => 'INCOMPATIBLE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php new file mode 100644 index 00000000000..5fbfebf75fd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php @@ -0,0 +1,132 @@ +google.analytics.data.v1beta.CreateAudienceExportRequest + */ +class CreateAudienceExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The audience export to create. + * + * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $audience_export = null; + + /** + * @param string $parent Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * Please see {@see BetaAnalyticsDataClient::propertyName()} for help formatting this field. + * @param \Google\Analytics\Data\V1beta\AudienceExport $audienceExport Required. The audience export to create. + * + * @return \Google\Analytics\Data\V1beta\CreateAudienceExportRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Analytics\Data\V1beta\AudienceExport $audienceExport): self + { + return (new self()) + ->setParent($parent) + ->setAudienceExport($audienceExport); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * @type \Google\Analytics\Data\V1beta\AudienceExport $audience_export + * Required. The audience export to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The audience export to create. + * + * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Analytics\Data\V1beta\AudienceExport|null + */ + public function getAudienceExport() + { + return $this->audience_export; + } + + public function hasAudienceExport() + { + return isset($this->audience_export); + } + + public function clearAudienceExport() + { + unset($this->audience_export); + } + + /** + * Required. The audience export to create. + * + * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Analytics\Data\V1beta\AudienceExport $var + * @return $this + */ + public function setAudienceExport($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\AudienceExport::class); + $this->audience_export = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php new file mode 100644 index 00000000000..9c0ef0525f6 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php @@ -0,0 +1,172 @@ +google.analytics.data.v1beta.DateRange + */ +class DateRange extends \Google\Protobuf\Internal\Message +{ + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + */ + protected $start_date = ''; + /** + * 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. + * + * Generated from protobuf field string end_date = 2; + */ + protected $end_date = ''; + /** + * 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. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $start_date + * 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. + * @type string $end_date + * 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. + * @type string $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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + * @return string + */ + public function getStartDate() + { + return $this->start_date; + } + + /** + * 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. + * + * Generated from protobuf field string start_date = 1; + * @param string $var + * @return $this + */ + public function setStartDate($var) + { + GPBUtil::checkString($var, True); + $this->start_date = $var; + + 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. + * + * Generated from protobuf field string end_date = 2; + * @return string + */ + public function getEndDate() + { + return $this->end_date; + } + + /** + * 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. + * + * Generated from protobuf field string end_date = 2; + * @param string $var + * @return $this + */ + public function setEndDate($var) + { + GPBUtil::checkString($var, True); + $this->end_date = $var; + + 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. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->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. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php new file mode 100644 index 00000000000..4fe7c3aed86 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php @@ -0,0 +1,190 @@ +google.analytics.data.v1beta.Dimension + */ +class Dimension extends \Google\Protobuf\Internal\Message +{ + /** + * 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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; + */ + protected $dimension_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * @type \Google\Analytics\Data\V1beta\DimensionExpression $dimension_expression + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->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 supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) + * for the list of dimension names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) + * for the list of dimension names supported by the `runFunnelReport` + * method. + * 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`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; + * @return \Google\Analytics\Data\V1beta\DimensionExpression|null + */ + public function getDimensionExpression() + { + return $this->dimension_expression; + } + + public function hasDimensionExpression() + { + return isset($this->dimension_expression); + } + + public function clearDimensionExpression() + { + unset($this->dimension_expression); + } + + /** + * One dimension can be the result of an expression of multiple dimensions. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; + * @param \Google\Analytics\Data\V1beta\DimensionExpression $var + * @return $this + */ + public function setDimensionExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression::class); + $this->dimension_expression = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php new file mode 100644 index 00000000000..ff6d5ae0fc6 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php @@ -0,0 +1,133 @@ +google.analytics.data.v1beta.DimensionCompatibility + */ +class DimensionCompatibility extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension metadata contains the API name for this compatibility + * information. The dimension metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; + */ + protected $dimension_metadata = null; + /** + * The compatibility of this dimension. If the compatibility is COMPATIBLE, + * this dimension can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + */ + protected $compatibility = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\DimensionMetadata $dimension_metadata + * The dimension metadata contains the API name for this compatibility + * information. The dimension metadata also contains other helpful information + * like the UI name and description. + * @type int $compatibility + * The compatibility of this dimension. If the compatibility is COMPATIBLE, + * this dimension can be successfully added to the report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension metadata contains the API name for this compatibility + * information. The dimension metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; + * @return \Google\Analytics\Data\V1beta\DimensionMetadata|null + */ + public function getDimensionMetadata() + { + return $this->dimension_metadata; + } + + public function hasDimensionMetadata() + { + return isset($this->dimension_metadata); + } + + public function clearDimensionMetadata() + { + unset($this->dimension_metadata); + } + + /** + * The dimension metadata contains the API name for this compatibility + * information. The dimension metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; + * @param \Google\Analytics\Data\V1beta\DimensionMetadata $var + * @return $this + */ + public function setDimensionMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionMetadata::class); + $this->dimension_metadata = $var; + + return $this; + } + + /** + * The compatibility of this dimension. If the compatibility is COMPATIBLE, + * this dimension can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + * @return int + */ + public function getCompatibility() + { + return isset($this->compatibility) ? $this->compatibility : 0; + } + + public function hasCompatibility() + { + return isset($this->compatibility); + } + + public function clearCompatibility() + { + unset($this->compatibility); + } + + /** + * The compatibility of this dimension. If the compatibility is COMPATIBLE, + * this dimension can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + * @param int $var + * @return $this + */ + public function setCompatibility($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); + $this->compatibility = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php new file mode 100644 index 00000000000..c7819e050c8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php @@ -0,0 +1,147 @@ +google.analytics.data.v1beta.DimensionExpression + */ +class DimensionExpression extends \Google\Protobuf\Internal\Message +{ + protected $one_expression; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $lower_case + * Used to convert a dimension value to lower case. + * @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $upper_case + * Used to convert a dimension value to upper case. + * @type \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $concatenate + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Used to convert a dimension value to lower case. + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4; + * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null + */ + public function getLowerCase() + { + return $this->readOneof(4); + } + + public function hasLowerCase() + { + return $this->hasOneof(4); + } + + /** + * Used to convert a dimension value to lower case. + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4; + * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var + * @return $this + */ + public function setLowerCase($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Used to convert a dimension value to upper case. + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5; + * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null + */ + public function getUpperCase() + { + return $this->readOneof(5); + } + + public function hasUpperCase() + { + return $this->hasOneof(5); + } + + /** + * Used to convert a dimension value to upper case. + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5; + * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var + * @return $this + */ + public function setUpperCase($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6; + * @return \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression|null + */ + public function getConcatenate() + { + return $this->readOneof(6); + } + + public function hasConcatenate() + { + return $this->hasOneof(6); + } + + /** + * Used to combine dimension values to a single dimension. + * For example, dimension "country, city": concatenate(country, ", ", city). + * + * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6; + * @param \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $var + * @return $this + */ + public function setConcatenate($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneExpression() + { + return $this->whichOneof("one_expression"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php new file mode 100644 index 00000000000..af1e679e55d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php @@ -0,0 +1,74 @@ +google.analytics.data.v1beta.DimensionExpression.CaseExpression + */ +class CaseExpression extends \Google\Protobuf\Internal\Message +{ + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + */ + protected $dimension_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * Name of a dimension. The name must refer back to a name in dimensions + * field of the request. + * + * Generated from protobuf field string dimension_name = 1; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CaseExpression::class, \Google\Analytics\Data\V1beta\DimensionExpression_CaseExpression::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php new file mode 100644 index 00000000000..9d7a101bddd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php @@ -0,0 +1,128 @@ +google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression + */ +class ConcatenateExpression extends \Google\Protobuf\Internal\Message +{ + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + */ + private $dimension_names; + /** + * 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". + * + * Generated from protobuf field string delimiter = 2; + */ + protected $delimiter = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $dimension_names + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * @type string $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". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionNames() + { + return $this->dimension_names; + } + + /** + * Names of dimensions. The names must refer back to names in the dimensions + * field of the request. + * + * Generated from protobuf field repeated string dimension_names = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->dimension_names = $arr; + + 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". + * + * Generated from protobuf field string delimiter = 2; + * @return string + */ + public function getDelimiter() + { + return $this->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". + * + * Generated from protobuf field string delimiter = 2; + * @param string $var + * @return $this + */ + public function setDelimiter($var) + { + GPBUtil::checkString($var, True); + $this->delimiter = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ConcatenateExpression::class, \Google\Analytics\Data\V1beta\DimensionExpression_ConcatenateExpression::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php new file mode 100644 index 00000000000..fe4f90d2a87 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php @@ -0,0 +1,70 @@ +google.analytics.data.v1beta.DimensionHeader + */ +class DimensionHeader extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The dimension's name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The dimension's name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php new file mode 100644 index 00000000000..bb0ccba25fd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php @@ -0,0 +1,261 @@ +google.analytics.data.v1beta.DimensionMetadata + */ +class DimensionMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For + * example, `eventName`. + * + * Generated from protobuf field string api_name = 1; + */ + protected $api_name = ''; + /** + * This dimension's name within the Google Analytics user interface. For + * example, `Event name`. + * + * Generated from protobuf field string ui_name = 2; + */ + protected $ui_name = ''; + /** + * Description of how this dimension is used and calculated. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Still usable but deprecated names for this dimension. If populated, this + * dimension is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the dimension will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + */ + private $deprecated_api_names; + /** + * True if the dimension is a custom dimension for this property. + * + * Generated from protobuf field bool custom_definition = 5; + */ + protected $custom_definition = false; + /** + * The display name of the category that this dimension belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 7; + */ + protected $category = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $api_name + * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For + * example, `eventName`. + * @type string $ui_name + * This dimension's name within the Google Analytics user interface. For + * example, `Event name`. + * @type string $description + * Description of how this dimension is used and calculated. + * @type array|\Google\Protobuf\Internal\RepeatedField $deprecated_api_names + * Still usable but deprecated names for this dimension. If populated, this + * dimension is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the dimension will be + * available only by `apiName`. + * @type bool $custom_definition + * True if the dimension is a custom dimension for this property. + * @type string $category + * The display name of the category that this dimension belongs to. Similar + * dimensions and metrics are categorized together. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For + * example, `eventName`. + * + * Generated from protobuf field string api_name = 1; + * @return string + */ + public function getApiName() + { + return $this->api_name; + } + + /** + * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For + * example, `eventName`. + * + * Generated from protobuf field string api_name = 1; + * @param string $var + * @return $this + */ + public function setApiName($var) + { + GPBUtil::checkString($var, True); + $this->api_name = $var; + + return $this; + } + + /** + * This dimension's name within the Google Analytics user interface. For + * example, `Event name`. + * + * Generated from protobuf field string ui_name = 2; + * @return string + */ + public function getUiName() + { + return $this->ui_name; + } + + /** + * This dimension's name within the Google Analytics user interface. For + * example, `Event name`. + * + * Generated from protobuf field string ui_name = 2; + * @param string $var + * @return $this + */ + public function setUiName($var) + { + GPBUtil::checkString($var, True); + $this->ui_name = $var; + + return $this; + } + + /** + * Description of how this dimension is used and calculated. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of how this dimension is used and calculated. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Still usable but deprecated names for this dimension. If populated, this + * dimension is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the dimension will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDeprecatedApiNames() + { + return $this->deprecated_api_names; + } + + /** + * Still usable but deprecated names for this dimension. If populated, this + * dimension is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the dimension will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDeprecatedApiNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->deprecated_api_names = $arr; + + return $this; + } + + /** + * True if the dimension is a custom dimension for this property. + * + * Generated from protobuf field bool custom_definition = 5; + * @return bool + */ + public function getCustomDefinition() + { + return $this->custom_definition; + } + + /** + * True if the dimension is a custom dimension for this property. + * + * Generated from protobuf field bool custom_definition = 5; + * @param bool $var + * @return $this + */ + public function setCustomDefinition($var) + { + GPBUtil::checkBool($var); + $this->custom_definition = $var; + + return $this; + } + + /** + * The display name of the category that this dimension belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 7; + * @return string + */ + public function getCategory() + { + return $this->category; + } + + /** + * The display name of the category that this dimension belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 7; + * @param string $var + * @return $this + */ + public function setCategory($var) + { + GPBUtil::checkString($var, True); + $this->category = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php new file mode 100644 index 00000000000..7e0d684c982 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1beta.DimensionValue + */ +class DimensionValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Value as a string if the dimension type is a string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->readOneof(1); + } + + public function hasValue() + { + return $this->hasOneof(1); + } + + /** + * Value as a string if the dimension type is a string. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php new file mode 100644 index 00000000000..01c955105c4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php @@ -0,0 +1,224 @@ +google.analytics.data.v1beta.Filter + */ +class Filter extends \Google\Protobuf\Internal\Message +{ + /** + * The dimension name or metric name. + * In most methods, dimensions & metrics can be used for the first time in + * this field. However in a RunPivotReportRequest, this field must be + * additionally specified by name in the RunPivotReportRequest's dimensions or + * metrics. + * + * Generated from protobuf field string field_name = 1; + */ + protected $field_name = ''; + protected $one_filter; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field_name + * The dimension name or metric name. + * In most methods, dimensions & metrics can be used for the first time in + * this field. However in a RunPivotReportRequest, this field must be + * additionally specified by name in the RunPivotReportRequest's dimensions or + * metrics. + * @type \Google\Analytics\Data\V1beta\Filter\StringFilter $string_filter + * Strings related filter. + * @type \Google\Analytics\Data\V1beta\Filter\InListFilter $in_list_filter + * A filter for in list values. + * @type \Google\Analytics\Data\V1beta\Filter\NumericFilter $numeric_filter + * A filter for numeric or date values. + * @type \Google\Analytics\Data\V1beta\Filter\BetweenFilter $between_filter + * A filter for two values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The dimension name or metric name. + * In most methods, dimensions & metrics can be used for the first time in + * this field. However in a RunPivotReportRequest, this field must be + * additionally specified by name in the RunPivotReportRequest's dimensions or + * metrics. + * + * Generated from protobuf field string field_name = 1; + * @return string + */ + public function getFieldName() + { + return $this->field_name; + } + + /** + * The dimension name or metric name. + * In most methods, dimensions & metrics can be used for the first time in + * this field. However in a RunPivotReportRequest, this field must be + * additionally specified by name in the RunPivotReportRequest's dimensions or + * metrics. + * + * Generated from protobuf field string field_name = 1; + * @param string $var + * @return $this + */ + public function setFieldName($var) + { + GPBUtil::checkString($var, True); + $this->field_name = $var; + + return $this; + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter string_filter = 3; + * @return \Google\Analytics\Data\V1beta\Filter\StringFilter|null + */ + public function getStringFilter() + { + return $this->readOneof(3); + } + + public function hasStringFilter() + { + return $this->hasOneof(3); + } + + /** + * Strings related filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter string_filter = 3; + * @param \Google\Analytics\Data\V1beta\Filter\StringFilter $var + * @return $this + */ + public function setStringFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\StringFilter::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.InListFilter in_list_filter = 4; + * @return \Google\Analytics\Data\V1beta\Filter\InListFilter|null + */ + public function getInListFilter() + { + return $this->readOneof(4); + } + + public function hasInListFilter() + { + return $this->hasOneof(4); + } + + /** + * A filter for in list values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.InListFilter in_list_filter = 4; + * @param \Google\Analytics\Data\V1beta\Filter\InListFilter $var + * @return $this + */ + public function setInListFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\InListFilter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter numeric_filter = 5; + * @return \Google\Analytics\Data\V1beta\Filter\NumericFilter|null + */ + public function getNumericFilter() + { + return $this->readOneof(5); + } + + public function hasNumericFilter() + { + return $this->hasOneof(5); + } + + /** + * A filter for numeric or date values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter numeric_filter = 5; + * @param \Google\Analytics\Data\V1beta\Filter\NumericFilter $var + * @return $this + */ + public function setNumericFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\NumericFilter::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * A filter for two values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.BetweenFilter between_filter = 6; + * @return \Google\Analytics\Data\V1beta\Filter\BetweenFilter|null + */ + public function getBetweenFilter() + { + return $this->readOneof(6); + } + + public function hasBetweenFilter() + { + return $this->hasOneof(6); + } + + /** + * A filter for two values. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.BetweenFilter between_filter = 6; + * @param \Google\Analytics\Data\V1beta\Filter\BetweenFilter $var + * @return $this + */ + public function setBetweenFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\BetweenFilter::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneFilter() + { + return $this->whichOneof("one_filter"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php new file mode 100644 index 00000000000..39b91d0e3f6 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php @@ -0,0 +1,124 @@ +google.analytics.data.v1beta.Filter.BetweenFilter + */ +class BetweenFilter extends \Google\Protobuf\Internal\Message +{ + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; + */ + protected $from_value = null; + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; + */ + protected $to_value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\NumericValue $from_value + * Begins with this number. + * @type \Google\Analytics\Data\V1beta\NumericValue $to_value + * Ends with this number. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; + * @return \Google\Analytics\Data\V1beta\NumericValue|null + */ + public function getFromValue() + { + return $this->from_value; + } + + public function hasFromValue() + { + return isset($this->from_value); + } + + public function clearFromValue() + { + unset($this->from_value); + } + + /** + * Begins with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; + * @param \Google\Analytics\Data\V1beta\NumericValue $var + * @return $this + */ + public function setFromValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); + $this->from_value = $var; + + return $this; + } + + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; + * @return \Google\Analytics\Data\V1beta\NumericValue|null + */ + public function getToValue() + { + return $this->to_value; + } + + public function hasToValue() + { + return isset($this->to_value); + } + + public function clearToValue() + { + unset($this->to_value); + } + + /** + * Ends with this number. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; + * @param \Google\Analytics\Data\V1beta\NumericValue $var + * @return $this + */ + public function setToValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); + $this->to_value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(BetweenFilter::class, \Google\Analytics\Data\V1beta\Filter_BetweenFilter::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php new file mode 100644 index 00000000000..cad215417f8 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php @@ -0,0 +1,108 @@ +google.analytics.data.v1beta.Filter.InListFilter + */ +class InListFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + */ + private $values; + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + */ + protected $case_sensitive = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $values + * The list of string values. + * Must be non-empty. + * @type bool $case_sensitive + * If true, the string value is case sensitive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getValues() + { + return $this->values; + } + + /** + * The list of string values. + * Must be non-empty. + * + * Generated from protobuf field repeated string values = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->values = $arr; + + return $this; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + * @return bool + */ + public function getCaseSensitive() + { + return $this->case_sensitive; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 2; + * @param bool $var + * @return $this + */ + public function setCaseSensitive($var) + { + GPBUtil::checkBool($var); + $this->case_sensitive = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InListFilter::class, \Google\Analytics\Data\V1beta\Filter_InListFilter::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php new file mode 100644 index 00000000000..cd95e5399a2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php @@ -0,0 +1,114 @@ +google.analytics.data.v1beta.Filter.NumericFilter + */ +class NumericFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; + */ + protected $operation = 0; + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; + */ + protected $value = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $operation + * The operation type for this filter. + * @type \Google\Analytics\Data\V1beta\NumericValue $value + * A numeric value or a date value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; + * @return int + */ + public function getOperation() + { + return $this->operation; + } + + /** + * The operation type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; + * @param int $var + * @return $this + */ + public function setOperation($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Filter\NumericFilter\Operation::class); + $this->operation = $var; + + return $this; + } + + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; + * @return \Google\Analytics\Data\V1beta\NumericValue|null + */ + public function getValue() + { + return $this->value; + } + + public function hasValue() + { + return isset($this->value); + } + + public function clearValue() + { + unset($this->value); + } + + /** + * A numeric value or a date value. + * + * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; + * @param \Google\Analytics\Data\V1beta\NumericValue $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); + $this->value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NumericFilter::class, \Google\Analytics\Data\V1beta\Filter_NumericFilter::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php new file mode 100644 index 00000000000..4633829403b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php @@ -0,0 +1,85 @@ +google.analytics.data.v1beta.Filter.NumericFilter.Operation + */ +class Operation +{ + /** + * Unspecified. + * + * Generated from protobuf enum OPERATION_UNSPECIFIED = 0; + */ + const OPERATION_UNSPECIFIED = 0; + /** + * Equal + * + * Generated from protobuf enum EQUAL = 1; + */ + const EQUAL = 1; + /** + * Less than + * + * Generated from protobuf enum LESS_THAN = 2; + */ + const LESS_THAN = 2; + /** + * Less than or equal + * + * Generated from protobuf enum LESS_THAN_OR_EQUAL = 3; + */ + const LESS_THAN_OR_EQUAL = 3; + /** + * Greater than + * + * Generated from protobuf enum GREATER_THAN = 4; + */ + const GREATER_THAN = 4; + /** + * Greater than or equal + * + * Generated from protobuf enum GREATER_THAN_OR_EQUAL = 5; + */ + const GREATER_THAN_OR_EQUAL = 5; + + private static $valueToName = [ + self::OPERATION_UNSPECIFIED => 'OPERATION_UNSPECIFIED', + self::EQUAL => 'EQUAL', + self::LESS_THAN => 'LESS_THAN', + self::LESS_THAN_OR_EQUAL => 'LESS_THAN_OR_EQUAL', + self::GREATER_THAN => 'GREATER_THAN', + self::GREATER_THAN_OR_EQUAL => 'GREATER_THAN_OR_EQUAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Operation::class, \Google\Analytics\Data\V1beta\Filter_NumericFilter_Operation::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php new file mode 100644 index 00000000000..f4feeb9aff3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php @@ -0,0 +1,138 @@ +google.analytics.data.v1beta.Filter.StringFilter + */ +class StringFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; + */ + protected $match_type = 0; + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + */ + protected $value = ''; + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + */ + protected $case_sensitive = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $match_type + * The match type for this filter. + * @type string $value + * The string value used for the matching. + * @type bool $case_sensitive + * If true, the string value is case sensitive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; + * @return int + */ + public function getMatchType() + { + return $this->match_type; + } + + /** + * The match type for this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; + * @param int $var + * @return $this + */ + public function setMatchType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Filter\StringFilter\MatchType::class); + $this->match_type = $var; + + return $this; + } + + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * The string value used for the matching. + * + * Generated from protobuf field string value = 2; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @return bool + */ + public function getCaseSensitive() + { + return $this->case_sensitive; + } + + /** + * If true, the string value is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @param bool $var + * @return $this + */ + public function setCaseSensitive($var) + { + GPBUtil::checkBool($var); + $this->case_sensitive = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StringFilter::class, \Google\Analytics\Data\V1beta\Filter_StringFilter::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php new file mode 100644 index 00000000000..4e40f9c5c3b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php @@ -0,0 +1,92 @@ +google.analytics.data.v1beta.Filter.StringFilter.MatchType + */ +class MatchType +{ + /** + * Unspecified + * + * Generated from protobuf enum MATCH_TYPE_UNSPECIFIED = 0; + */ + const MATCH_TYPE_UNSPECIFIED = 0; + /** + * Exact match of the string value. + * + * Generated from protobuf enum EXACT = 1; + */ + const EXACT = 1; + /** + * Begins with the string value. + * + * Generated from protobuf enum BEGINS_WITH = 2; + */ + const BEGINS_WITH = 2; + /** + * Ends with the string value. + * + * Generated from protobuf enum ENDS_WITH = 3; + */ + const ENDS_WITH = 3; + /** + * Contains the string value. + * + * Generated from protobuf enum CONTAINS = 4; + */ + const CONTAINS = 4; + /** + * Full match for the regular expression with the string value. + * + * Generated from protobuf enum FULL_REGEXP = 5; + */ + const FULL_REGEXP = 5; + /** + * Partial match for the regular expression with the string value. + * + * Generated from protobuf enum PARTIAL_REGEXP = 6; + */ + const PARTIAL_REGEXP = 6; + + private static $valueToName = [ + self::MATCH_TYPE_UNSPECIFIED => 'MATCH_TYPE_UNSPECIFIED', + self::EXACT => 'EXACT', + self::BEGINS_WITH => 'BEGINS_WITH', + self::ENDS_WITH => 'ENDS_WITH', + self::CONTAINS => 'CONTAINS', + self::FULL_REGEXP => 'FULL_REGEXP', + self::PARTIAL_REGEXP => 'PARTIAL_REGEXP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MatchType::class, \Google\Analytics\Data\V1beta\Filter_StringFilter_MatchType::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php new file mode 100644 index 00000000000..99e554d09c3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php @@ -0,0 +1,178 @@ +google.analytics.data.v1beta.FilterExpression + */ +class FilterExpression extends \Google\Protobuf\Internal\Message +{ + protected $expr; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\FilterExpressionList $and_group + * The FilterExpressions in and_group have an AND relationship. + * @type \Google\Analytics\Data\V1beta\FilterExpressionList $or_group + * The FilterExpressions in or_group have an OR relationship. + * @type \Google\Analytics\Data\V1beta\FilterExpression $not_expression + * The FilterExpression is NOT of not_expression. + * @type \Google\Analytics\Data\V1beta\Filter $filter + * A primitive filter. In the same FilterExpression, all of the filter's + * field names need to be either all dimensions or all metrics. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The FilterExpressions in and_group have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList and_group = 1; + * @return \Google\Analytics\Data\V1beta\FilterExpressionList|null + */ + public function getAndGroup() + { + return $this->readOneof(1); + } + + public function hasAndGroup() + { + return $this->hasOneof(1); + } + + /** + * The FilterExpressions in and_group have an AND relationship. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList and_group = 1; + * @param \Google\Analytics\Data\V1beta\FilterExpressionList $var + * @return $this + */ + public function setAndGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpressionList::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The FilterExpressions in or_group have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList or_group = 2; + * @return \Google\Analytics\Data\V1beta\FilterExpressionList|null + */ + public function getOrGroup() + { + return $this->readOneof(2); + } + + public function hasOrGroup() + { + return $this->hasOneof(2); + } + + /** + * The FilterExpressions in or_group have an OR relationship. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList or_group = 2; + * @param \Google\Analytics\Data\V1beta\FilterExpressionList $var + * @return $this + */ + public function setOrGroup($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpressionList::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The FilterExpression is NOT of not_expression. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression not_expression = 3; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getNotExpression() + { + return $this->readOneof(3); + } + + public function hasNotExpression() + { + return $this->hasOneof(3); + } + + /** + * The FilterExpression is NOT of not_expression. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression not_expression = 3; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setNotExpression($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->writeOneof(3, $var); + + 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter filter = 4; + * @return \Google\Analytics\Data\V1beta\Filter|null + */ + public function getFilter() + { + return $this->readOneof(4); + } + + public function hasFilter() + { + return $this->hasOneof(4); + } + + /** + * A primitive filter. In the same FilterExpression, all of the filter's + * field names need to be either all dimensions or all metrics. + * + * Generated from protobuf field .google.analytics.data.v1beta.Filter filter = 4; + * @param \Google\Analytics\Data\V1beta\Filter $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getExpr() + { + return $this->whichOneof("expr"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php new file mode 100644 index 00000000000..d7eb56f9b25 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php @@ -0,0 +1,67 @@ +google.analytics.data.v1beta.FilterExpressionList + */ +class FilterExpressionList extends \Google\Protobuf\Internal\Message +{ + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; + */ + private $expressions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions + * A list of filter expressions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getExpressions() + { + return $this->expressions; + } + + /** + * A list of filter expressions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; + * @param array<\Google\Analytics\Data\V1beta\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setExpressions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->expressions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php new file mode 100644 index 00000000000..766f05b4bf6 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php @@ -0,0 +1,87 @@ +google.analytics.data.v1beta.GetAudienceExportRequest + */ +class GetAudienceExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * Please see {@see BetaAnalyticsDataClient::audienceExportName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1beta\GetAudienceExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php new file mode 100644 index 00000000000..e2c983e6925 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php @@ -0,0 +1,123 @@ +google.analytics.data.v1beta.GetMetadataRequest + */ +class GetMetadataRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * Example: properties/1234/metadata + * 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. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * + * Example: properties/1234/metadata + * + * 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. Please see + * {@see BetaAnalyticsDataClient::metadataName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1beta\GetMetadataRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * Example: properties/1234/metadata + * 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * Example: properties/1234/metadata + * 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. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * Example: properties/1234/metadata + * 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. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php new file mode 100644 index 00000000000..33ef5680867 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php @@ -0,0 +1,178 @@ +google.analytics.data.v1beta.ListAudienceExportsRequest + */ +class ListAudienceExportsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. The maximum number of audience exports to return. The service may + * return fewer than this value. If unspecified, at most 200 audience exports + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. A page token, received from a previous `ListAudienceExports` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * Please see {@see BetaAnalyticsDataClient::propertyName()} for help formatting this field. + * + * @return \Google\Analytics\Data\V1beta\ListAudienceExportsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * @type int $page_size + * Optional. The maximum number of audience exports to return. The service may + * return fewer than this value. If unspecified, at most 200 audience exports + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * @type string $page_token + * Optional. A page token, received from a previous `ListAudienceExports` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceExports` + * must match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Optional. The maximum number of audience exports to return. The service may + * return fewer than this value. If unspecified, at most 200 audience exports + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The maximum number of audience exports to return. The service may + * return fewer than this value. If unspecified, at most 200 audience exports + * will be returned. The maximum value is 1000 (higher values will be coerced + * to the maximum). + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. A page token, received from a previous `ListAudienceExports` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. A page token, received from a previous `ListAudienceExports` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListAudienceExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php new file mode 100644 index 00000000000..36ed768b89f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php @@ -0,0 +1,115 @@ +google.analytics.data.v1beta.ListAudienceExportsResponse + */ +class ListAudienceExportsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Each audience export for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; + */ + private $audience_exports; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + */ + protected $next_page_token = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\AudienceExport>|\Google\Protobuf\Internal\RepeatedField $audience_exports + * Each audience export for a property. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Each audience export for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAudienceExports() + { + return $this->audience_exports; + } + + /** + * Each audience export for a property. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; + * @param array<\Google\Analytics\Data\V1beta\AudienceExport>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAudienceExports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceExport::class); + $this->audience_exports = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return isset($this->next_page_token) ? $this->next_page_token : ''; + } + + public function hasNextPageToken() + { + return isset($this->next_page_token); + } + + public function clearNextPageToken() + { + unset($this->next_page_token); + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field optional string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php new file mode 100644 index 00000000000..8897087638e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php @@ -0,0 +1,136 @@ +google.analytics.data.v1beta.Metadata + */ +class Metadata extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name of this metadata. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + /** + * The dimension descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; + */ + private $dimensions; + /** + * The metric descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; + */ + private $metrics; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource name of this metadata. + * @type array<\Google\Analytics\Data\V1beta\DimensionMetadata>|\Google\Protobuf\Internal\RepeatedField $dimensions + * The dimension descriptions. + * @type array<\Google\Analytics\Data\V1beta\MetricMetadata>|\Google\Protobuf\Internal\RepeatedField $metrics + * The metric descriptions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Resource name of this metadata. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource name of this metadata. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The dimension descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * The dimension descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionMetadata::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * The metric descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * The metric descriptions. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; + * @param array<\Google\Analytics\Data\V1beta\MetricMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricMetadata::class); + $this->metrics = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php new file mode 100644 index 00000000000..d58fd9f004d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php @@ -0,0 +1,221 @@ +google.analytics.data.v1beta.Metric + */ +class Metric extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + */ + protected $expression = ''; + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + */ + protected $invisible = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * @type string $expression + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * @type bool $invisible + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the metric. See the [API + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. + * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric + * `expression`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + * @return string + */ + public function getExpression() + { + return $this->expression; + } + + /** + * A mathematical expression for derived metrics. For example, the metric + * Event count per user is `eventCount/totalUsers`. + * + * Generated from protobuf field string expression = 2; + * @param string $var + * @return $this + */ + public function setExpression($var) + { + GPBUtil::checkString($var, True); + $this->expression = $var; + + return $this; + } + + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + * @return bool + */ + public function getInvisible() + { + return $this->invisible; + } + + /** + * Indicates if a metric is invisible in the report response. If a metric is + * invisible, the metric will not produce a column in the response, but can be + * used in `metricFilter`, `orderBys`, or a metric `expression`. + * + * Generated from protobuf field bool invisible = 3; + * @param bool $var + * @return $this + */ + public function setInvisible($var) + { + GPBUtil::checkBool($var); + $this->invisible = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php new file mode 100644 index 00000000000..af5158b3729 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php @@ -0,0 +1,75 @@ +google.analytics.data.v1beta.MetricAggregation + */ +class MetricAggregation +{ + /** + * Unspecified operator. + * + * Generated from protobuf enum METRIC_AGGREGATION_UNSPECIFIED = 0; + */ + const METRIC_AGGREGATION_UNSPECIFIED = 0; + /** + * SUM operator. + * + * Generated from protobuf enum TOTAL = 1; + */ + const TOTAL = 1; + /** + * Minimum operator. + * + * Generated from protobuf enum MINIMUM = 5; + */ + const MINIMUM = 5; + /** + * Maximum operator. + * + * Generated from protobuf enum MAXIMUM = 6; + */ + const MAXIMUM = 6; + /** + * Count operator. + * + * Generated from protobuf enum COUNT = 4; + */ + const COUNT = 4; + + private static $valueToName = [ + self::METRIC_AGGREGATION_UNSPECIFIED => 'METRIC_AGGREGATION_UNSPECIFIED', + self::TOTAL => 'TOTAL', + self::MINIMUM => 'MINIMUM', + self::MAXIMUM => 'MAXIMUM', + self::COUNT => 'COUNT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php new file mode 100644 index 00000000000..f76bff55631 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php @@ -0,0 +1,133 @@ +google.analytics.data.v1beta.MetricCompatibility + */ +class MetricCompatibility extends \Google\Protobuf\Internal\Message +{ + /** + * The metric metadata contains the API name for this compatibility + * information. The metric metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; + */ + protected $metric_metadata = null; + /** + * The compatibility of this metric. If the compatibility is COMPATIBLE, + * this metric can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + */ + protected $compatibility = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\MetricMetadata $metric_metadata + * The metric metadata contains the API name for this compatibility + * information. The metric metadata also contains other helpful information + * like the UI name and description. + * @type int $compatibility + * The compatibility of this metric. If the compatibility is COMPATIBLE, + * this metric can be successfully added to the report. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The metric metadata contains the API name for this compatibility + * information. The metric metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; + * @return \Google\Analytics\Data\V1beta\MetricMetadata|null + */ + public function getMetricMetadata() + { + return $this->metric_metadata; + } + + public function hasMetricMetadata() + { + return isset($this->metric_metadata); + } + + public function clearMetricMetadata() + { + unset($this->metric_metadata); + } + + /** + * The metric metadata contains the API name for this compatibility + * information. The metric metadata also contains other helpful information + * like the UI name and description. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; + * @param \Google\Analytics\Data\V1beta\MetricMetadata $var + * @return $this + */ + public function setMetricMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\MetricMetadata::class); + $this->metric_metadata = $var; + + return $this; + } + + /** + * The compatibility of this metric. If the compatibility is COMPATIBLE, + * this metric can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + * @return int + */ + public function getCompatibility() + { + return isset($this->compatibility) ? $this->compatibility : 0; + } + + public function hasCompatibility() + { + return isset($this->compatibility); + } + + public function clearCompatibility() + { + unset($this->compatibility); + } + + /** + * The compatibility of this metric. If the compatibility is COMPATIBLE, + * this metric can be successfully added to the report. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; + * @param int $var + * @return $this + */ + public function setCompatibility($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); + $this->compatibility = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php new file mode 100644 index 00000000000..db125c0ae60 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php @@ -0,0 +1,104 @@ +google.analytics.data.v1beta.MetricHeader + */ +class MetricHeader extends \Google\Protobuf\Internal\Message +{ + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; + */ + protected $type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The metric's name. + * @type int $type + * The metric's data type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The metric's name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The metric's data type. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\MetricType::class); + $this->type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php new file mode 100644 index 00000000000..9ef96ff2bc1 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php @@ -0,0 +1,395 @@ +google.analytics.data.v1beta.MetricMetadata + */ +class MetricMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * A metric name. Useable in [Metric](#Metric)'s `name`. For example, + * `eventCount`. + * + * Generated from protobuf field string api_name = 1; + */ + protected $api_name = ''; + /** + * This metric's name within the Google Analytics user interface. For example, + * `Event count`. + * + * Generated from protobuf field string ui_name = 2; + */ + protected $ui_name = ''; + /** + * Description of how this metric is used and calculated. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Still usable but deprecated names for this metric. If populated, this + * metric is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the metric will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + */ + private $deprecated_api_names; + /** + * The type of this metric. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; + */ + protected $type = 0; + /** + * The mathematical expression for this derived metric. Can be used in + * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics + * are not expressions, and for non-expressions, this field is empty. + * + * Generated from protobuf field string expression = 6; + */ + protected $expression = ''; + /** + * True if the metric is a custom metric for this property. + * + * Generated from protobuf field bool custom_definition = 7; + */ + protected $custom_definition = false; + /** + * If reasons are specified, your access is blocked to this metric for this + * property. API requests from you to this property for this metric will + * succeed; however, the report will contain only zeros for this metric. API + * requests with metric filters on blocked metrics will fail. If reasons are + * empty, you have access to this metric. + * To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; + */ + private $blocked_reasons; + /** + * The display name of the category that this metrics belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 10; + */ + protected $category = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $api_name + * A metric name. Useable in [Metric](#Metric)'s `name`. For example, + * `eventCount`. + * @type string $ui_name + * This metric's name within the Google Analytics user interface. For example, + * `Event count`. + * @type string $description + * Description of how this metric is used and calculated. + * @type array|\Google\Protobuf\Internal\RepeatedField $deprecated_api_names + * Still usable but deprecated names for this metric. If populated, this + * metric is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the metric will be + * available only by `apiName`. + * @type int $type + * The type of this metric. + * @type string $expression + * The mathematical expression for this derived metric. Can be used in + * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics + * are not expressions, and for non-expressions, this field is empty. + * @type bool $custom_definition + * True if the metric is a custom metric for this property. + * @type array|\Google\Protobuf\Internal\RepeatedField $blocked_reasons + * If reasons are specified, your access is blocked to this metric for this + * property. API requests from you to this property for this metric will + * succeed; however, the report will contain only zeros for this metric. API + * requests with metric filters on blocked metrics will fail. If reasons are + * empty, you have access to this metric. + * To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * @type string $category + * The display name of the category that this metrics belongs to. Similar + * dimensions and metrics are categorized together. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * A metric name. Useable in [Metric](#Metric)'s `name`. For example, + * `eventCount`. + * + * Generated from protobuf field string api_name = 1; + * @return string + */ + public function getApiName() + { + return $this->api_name; + } + + /** + * A metric name. Useable in [Metric](#Metric)'s `name`. For example, + * `eventCount`. + * + * Generated from protobuf field string api_name = 1; + * @param string $var + * @return $this + */ + public function setApiName($var) + { + GPBUtil::checkString($var, True); + $this->api_name = $var; + + return $this; + } + + /** + * This metric's name within the Google Analytics user interface. For example, + * `Event count`. + * + * Generated from protobuf field string ui_name = 2; + * @return string + */ + public function getUiName() + { + return $this->ui_name; + } + + /** + * This metric's name within the Google Analytics user interface. For example, + * `Event count`. + * + * Generated from protobuf field string ui_name = 2; + * @param string $var + * @return $this + */ + public function setUiName($var) + { + GPBUtil::checkString($var, True); + $this->ui_name = $var; + + return $this; + } + + /** + * Description of how this metric is used and calculated. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of how this metric is used and calculated. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Still usable but deprecated names for this metric. If populated, this + * metric is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the metric will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDeprecatedApiNames() + { + return $this->deprecated_api_names; + } + + /** + * Still usable but deprecated names for this metric. If populated, this + * metric is available by either `apiName` or one of `deprecatedApiNames` + * for a period of time. After the deprecation period, the metric will be + * available only by `apiName`. + * + * Generated from protobuf field repeated string deprecated_api_names = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDeprecatedApiNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->deprecated_api_names = $arr; + + return $this; + } + + /** + * The type of this metric. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * The type of this metric. + * + * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\MetricType::class); + $this->type = $var; + + return $this; + } + + /** + * The mathematical expression for this derived metric. Can be used in + * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics + * are not expressions, and for non-expressions, this field is empty. + * + * Generated from protobuf field string expression = 6; + * @return string + */ + public function getExpression() + { + return $this->expression; + } + + /** + * The mathematical expression for this derived metric. Can be used in + * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics + * are not expressions, and for non-expressions, this field is empty. + * + * Generated from protobuf field string expression = 6; + * @param string $var + * @return $this + */ + public function setExpression($var) + { + GPBUtil::checkString($var, True); + $this->expression = $var; + + return $this; + } + + /** + * True if the metric is a custom metric for this property. + * + * Generated from protobuf field bool custom_definition = 7; + * @return bool + */ + public function getCustomDefinition() + { + return $this->custom_definition; + } + + /** + * True if the metric is a custom metric for this property. + * + * Generated from protobuf field bool custom_definition = 7; + * @param bool $var + * @return $this + */ + public function setCustomDefinition($var) + { + GPBUtil::checkBool($var); + $this->custom_definition = $var; + + return $this; + } + + /** + * If reasons are specified, your access is blocked to this metric for this + * property. API requests from you to this property for this metric will + * succeed; however, the report will contain only zeros for this metric. API + * requests with metric filters on blocked metrics will fail. If reasons are + * empty, you have access to this metric. + * To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBlockedReasons() + { + return $this->blocked_reasons; + } + + /** + * If reasons are specified, your access is blocked to this metric for this + * property. API requests from you to this property for this metric will + * succeed; however, the report will contain only zeros for this metric. API + * requests with metric filters on blocked metrics will fail. If reasons are + * empty, you have access to this metric. + * To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBlockedReasons($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricMetadata\BlockedReason::class); + $this->blocked_reasons = $arr; + + return $this; + } + + /** + * The display name of the category that this metrics belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 10; + * @return string + */ + public function getCategory() + { + return $this->category; + } + + /** + * The display name of the category that this metrics belongs to. Similar + * dimensions and metrics are categorized together. + * + * Generated from protobuf field string category = 10; + * @param string $var + * @return $this + */ + public function setCategory($var) + { + GPBUtil::checkString($var, True); + $this->category = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php new file mode 100644 index 00000000000..1b6aaf8bdc0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php @@ -0,0 +1,66 @@ +google.analytics.data.v1beta.MetricMetadata.BlockedReason + */ +class BlockedReason +{ + /** + * Will never be specified in API response. + * + * Generated from protobuf enum BLOCKED_REASON_UNSPECIFIED = 0; + */ + const BLOCKED_REASON_UNSPECIFIED = 0; + /** + * If present, your access is blocked to revenue related metrics for this + * property, and this metric is revenue related. + * + * Generated from protobuf enum NO_REVENUE_METRICS = 1; + */ + const NO_REVENUE_METRICS = 1; + /** + * If present, your access is blocked to cost related metrics for this + * property, and this metric is cost related. + * + * Generated from protobuf enum NO_COST_METRICS = 2; + */ + const NO_COST_METRICS = 2; + + private static $valueToName = [ + self::BLOCKED_REASON_UNSPECIFIED => 'BLOCKED_REASON_UNSPECIFIED', + self::NO_REVENUE_METRICS => 'NO_REVENUE_METRICS', + self::NO_COST_METRICS => 'NO_COST_METRICS', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(BlockedReason::class, \Google\Analytics\Data\V1beta\MetricMetadata_BlockedReason::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php new file mode 100644 index 00000000000..641bfa44a62 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php @@ -0,0 +1,131 @@ +google.analytics.data.v1beta.MetricType + */ +class MetricType +{ + /** + * Unspecified type. + * + * Generated from protobuf enum METRIC_TYPE_UNSPECIFIED = 0; + */ + const METRIC_TYPE_UNSPECIFIED = 0; + /** + * Integer type. + * + * Generated from protobuf enum TYPE_INTEGER = 1; + */ + const TYPE_INTEGER = 1; + /** + * Floating point type. + * + * Generated from protobuf enum TYPE_FLOAT = 2; + */ + const TYPE_FLOAT = 2; + /** + * A duration of seconds; a special floating point type. + * + * Generated from protobuf enum TYPE_SECONDS = 4; + */ + const TYPE_SECONDS = 4; + /** + * A duration in milliseconds; a special floating point type. + * + * Generated from protobuf enum TYPE_MILLISECONDS = 5; + */ + const TYPE_MILLISECONDS = 5; + /** + * A duration in minutes; a special floating point type. + * + * Generated from protobuf enum TYPE_MINUTES = 6; + */ + const TYPE_MINUTES = 6; + /** + * A duration in hours; a special floating point type. + * + * Generated from protobuf enum TYPE_HOURS = 7; + */ + const TYPE_HOURS = 7; + /** + * A custom metric of standard type; a special floating point type. + * + * Generated from protobuf enum TYPE_STANDARD = 8; + */ + const TYPE_STANDARD = 8; + /** + * An amount of money; a special floating point type. + * + * Generated from protobuf enum TYPE_CURRENCY = 9; + */ + const TYPE_CURRENCY = 9; + /** + * A length in feet; a special floating point type. + * + * Generated from protobuf enum TYPE_FEET = 10; + */ + const TYPE_FEET = 10; + /** + * A length in miles; a special floating point type. + * + * Generated from protobuf enum TYPE_MILES = 11; + */ + const TYPE_MILES = 11; + /** + * A length in meters; a special floating point type. + * + * Generated from protobuf enum TYPE_METERS = 12; + */ + const TYPE_METERS = 12; + /** + * A length in kilometers; a special floating point type. + * + * Generated from protobuf enum TYPE_KILOMETERS = 13; + */ + const TYPE_KILOMETERS = 13; + + private static $valueToName = [ + self::METRIC_TYPE_UNSPECIFIED => 'METRIC_TYPE_UNSPECIFIED', + self::TYPE_INTEGER => 'TYPE_INTEGER', + self::TYPE_FLOAT => 'TYPE_FLOAT', + self::TYPE_SECONDS => 'TYPE_SECONDS', + self::TYPE_MILLISECONDS => 'TYPE_MILLISECONDS', + self::TYPE_MINUTES => 'TYPE_MINUTES', + self::TYPE_HOURS => 'TYPE_HOURS', + self::TYPE_STANDARD => 'TYPE_STANDARD', + self::TYPE_CURRENCY => 'TYPE_CURRENCY', + self::TYPE_FEET => 'TYPE_FEET', + self::TYPE_MILES => 'TYPE_MILES', + self::TYPE_METERS => 'TYPE_METERS', + self::TYPE_KILOMETERS => 'TYPE_KILOMETERS', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php new file mode 100644 index 00000000000..5ae81b6fc47 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php @@ -0,0 +1,75 @@ +google.analytics.data.v1beta.MetricValue + */ +class MetricValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * Measurement value. See MetricHeader for type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Measurement value. See MetricHeader for type. + * + * Generated from protobuf field string value = 4; + * @return string + */ + public function getValue() + { + return $this->readOneof(4); + } + + public function hasValue() + { + return $this->hasOneof(4); + } + + /** + * Measurement value. See MetricHeader for type. + * + * Generated from protobuf field string value = 4; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php new file mode 100644 index 00000000000..d71a5cdffb4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php @@ -0,0 +1,220 @@ +google.analytics.data.v1beta.MinuteRange + */ +class MinuteRange extends \Google\Protobuf\Internal\Message +{ + /** + * The inclusive start minute for the query as a number of minutes before now. + * For example, `"startMinutesAgo": 29` specifies the report should include + * 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`). + * + * Generated from protobuf field optional int32 start_minutes_ago = 1; + */ + protected $start_minutes_ago = null; + /** + * The inclusive end minute for the query as a number of minutes before now. + * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` + * specifies the report should include event data from prior to 15 minutes + * 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`). + * + * Generated from protobuf field optional int32 end_minutes_ago = 2; + */ + protected $end_minutes_ago = null; + /** + * Assigns a name to this minute 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, minute ranges are named by their zero based index + * in the request: `date_range_0`, `date_range_1`, etc. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $start_minutes_ago + * The inclusive start minute for the query as a number of minutes before now. + * For example, `"startMinutesAgo": 29` specifies the report should include + * 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`). + * @type int $end_minutes_ago + * The inclusive end minute for the query as a number of minutes before now. + * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` + * specifies the report should include event data from prior to 15 minutes + * 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`). + * @type string $name + * Assigns a name to this minute 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, minute ranges are named by their zero based index + * in the request: `date_range_0`, `date_range_1`, etc. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The inclusive start minute for the query as a number of minutes before now. + * For example, `"startMinutesAgo": 29` specifies the report should include + * 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`). + * + * Generated from protobuf field optional int32 start_minutes_ago = 1; + * @return int + */ + public function getStartMinutesAgo() + { + return isset($this->start_minutes_ago) ? $this->start_minutes_ago : 0; + } + + public function hasStartMinutesAgo() + { + return isset($this->start_minutes_ago); + } + + public function clearStartMinutesAgo() + { + unset($this->start_minutes_ago); + } + + /** + * The inclusive start minute for the query as a number of minutes before now. + * For example, `"startMinutesAgo": 29` specifies the report should include + * 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`). + * + * Generated from protobuf field optional int32 start_minutes_ago = 1; + * @param int $var + * @return $this + */ + public function setStartMinutesAgo($var) + { + GPBUtil::checkInt32($var); + $this->start_minutes_ago = $var; + + return $this; + } + + /** + * The inclusive end minute for the query as a number of minutes before now. + * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` + * specifies the report should include event data from prior to 15 minutes + * 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`). + * + * Generated from protobuf field optional int32 end_minutes_ago = 2; + * @return int + */ + public function getEndMinutesAgo() + { + return isset($this->end_minutes_ago) ? $this->end_minutes_ago : 0; + } + + public function hasEndMinutesAgo() + { + return isset($this->end_minutes_ago); + } + + public function clearEndMinutesAgo() + { + unset($this->end_minutes_ago); + } + + /** + * The inclusive end minute for the query as a number of minutes before now. + * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` + * specifies the report should include event data from prior to 15 minutes + * 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`). + * + * Generated from protobuf field optional int32 end_minutes_ago = 2; + * @param int $var + * @return $this + */ + public function setEndMinutesAgo($var) + { + GPBUtil::checkInt32($var); + $this->end_minutes_ago = $var; + + return $this; + } + + /** + * Assigns a name to this minute 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, minute ranges are named by their zero based index + * in the request: `date_range_0`, `date_range_1`, etc. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Assigns a name to this minute 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, minute ranges are named by their zero based index + * in the request: `date_range_0`, `date_range_1`, etc. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php new file mode 100644 index 00000000000..ac466fe4865 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php @@ -0,0 +1,108 @@ +google.analytics.data.v1beta.NumericValue + */ +class NumericValue extends \Google\Protobuf\Internal\Message +{ + protected $one_value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $int64_value + * Integer value + * @type float $double_value + * Double value + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Integer value + * + * Generated from protobuf field int64 int64_value = 1; + * @return int|string + */ + public function getInt64Value() + { + return $this->readOneof(1); + } + + public function hasInt64Value() + { + return $this->hasOneof(1); + } + + /** + * Integer value + * + * Generated from protobuf field int64 int64_value = 1; + * @param int|string $var + * @return $this + */ + public function setInt64Value($var) + { + GPBUtil::checkInt64($var); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Double value + * + * Generated from protobuf field double double_value = 2; + * @return float + */ + public function getDoubleValue() + { + return $this->readOneof(2); + } + + public function hasDoubleValue() + { + return $this->hasOneof(2); + } + + /** + * Double value + * + * Generated from protobuf field double double_value = 2; + * @param float $var + * @return $this + */ + public function setDoubleValue($var) + { + GPBUtil::checkDouble($var); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getOneValue() + { + return $this->whichOneof("one_value"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php new file mode 100644 index 00000000000..bf52aa38f37 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php @@ -0,0 +1,177 @@ +google.analytics.data.v1beta.OrderBy + */ +class OrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + */ + protected $desc = false; + protected $one_order_by; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy $metric + * Sorts results by a metric's values. + * @type \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy $dimension + * Sorts results by a dimension's values. + * @type \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy $pivot + * Sorts results by a metric's values within a pivot column group. + * @type bool $desc + * If true, sorts by descending order. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Sorts results by a metric's values. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.MetricOrderBy metric = 1; + * @return \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy|null + */ + public function getMetric() + { + return $this->readOneof(1); + } + + public function hasMetric() + { + return $this->hasOneof(1); + } + + /** + * Sorts results by a metric's values. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.MetricOrderBy metric = 1; + * @param \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy $var + * @return $this + */ + public function setMetric($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Sorts results by a dimension's values. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy dimension = 2; + * @return \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy|null + */ + public function getDimension() + { + return $this->readOneof(2); + } + + public function hasDimension() + { + return $this->hasOneof(2); + } + + /** + * Sorts results by a dimension's values. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy dimension = 2; + * @param \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy $var + * @return $this + */ + public function setDimension($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Sorts results by a metric's values within a pivot column group. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.PivotOrderBy pivot = 3; + * @return \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy|null + */ + public function getPivot() + { + return $this->readOneof(3); + } + + public function hasPivot() + { + return $this->hasOneof(3); + } + + /** + * Sorts results by a metric's values within a pivot column group. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.PivotOrderBy pivot = 3; + * @param \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy $var + * @return $this + */ + public function setPivot($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + * @return bool + */ + public function getDesc() + { + return $this->desc; + } + + /** + * If true, sorts by descending order. + * + * Generated from protobuf field bool desc = 4; + * @param bool $var + * @return $this + */ + public function setDesc($var) + { + GPBUtil::checkBool($var); + $this->desc = $var; + + return $this; + } + + /** + * @return string + */ + public function getOneOrderBy() + { + return $this->whichOneof("one_order_by"); + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php new file mode 100644 index 00000000000..caaffd85a29 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php @@ -0,0 +1,104 @@ +google.analytics.data.v1beta.OrderBy.DimensionOrderBy + */ +class DimensionOrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + */ + protected $dimension_name = ''; + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; + */ + protected $order_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * A dimension name in the request to order by. + * @type int $order_type + * Controls the rule for dimension value ordering. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * A dimension name in the request to order by. + * + * Generated from protobuf field string dimension_name = 1; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; + * @return int + */ + public function getOrderType() + { + return $this->order_type; + } + + /** + * Controls the rule for dimension value ordering. + * + * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; + * @param int $var + * @return $this + */ + public function setOrderType($var) + { + GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy\OrderType::class); + $this->order_type = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DimensionOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_DimensionOrderBy::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php new file mode 100644 index 00000000000..d0ce40c9141 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php @@ -0,0 +1,76 @@ +google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType + */ +class OrderType +{ + /** + * Unspecified. + * + * Generated from protobuf enum ORDER_TYPE_UNSPECIFIED = 0; + */ + const ORDER_TYPE_UNSPECIFIED = 0; + /** + * Alphanumeric sort by Unicode code point. For example, "2" < "A" < "X" < + * "b" < "z". + * + * Generated from protobuf enum ALPHANUMERIC = 1; + */ + const ALPHANUMERIC = 1; + /** + * Case insensitive alphanumeric sort by lower case Unicode code point. + * For example, "2" < "A" < "b" < "X" < "z". + * + * Generated from protobuf enum CASE_INSENSITIVE_ALPHANUMERIC = 2; + */ + const CASE_INSENSITIVE_ALPHANUMERIC = 2; + /** + * Dimension values are converted to numbers before sorting. For example + * in NUMERIC sort, "25" < "100", and in `ALPHANUMERIC` sort, "100" < + * "25". Non-numeric dimension values all have equal ordering value below + * all numeric values. + * + * Generated from protobuf enum NUMERIC = 3; + */ + const NUMERIC = 3; + + private static $valueToName = [ + self::ORDER_TYPE_UNSPECIFIED => 'ORDER_TYPE_UNSPECIFIED', + self::ALPHANUMERIC => 'ALPHANUMERIC', + self::CASE_INSENSITIVE_ALPHANUMERIC => 'CASE_INSENSITIVE_ALPHANUMERIC', + self::NUMERIC => 'NUMERIC', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(OrderType::class, \Google\Analytics\Data\V1beta\OrderBy_DimensionOrderBy_OrderType::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php new file mode 100644 index 00000000000..27ab3306a35 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php @@ -0,0 +1,70 @@ +google.analytics.data.v1beta.OrderBy.MetricOrderBy + */ +class MetricOrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + */ + protected $metric_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $metric_name + * A metric name in the request to order by. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + * @return string + */ + public function getMetricName() + { + return $this->metric_name; + } + + /** + * A metric name in the request to order by. + * + * Generated from protobuf field string metric_name = 1; + * @param string $var + * @return $this + */ + public function setMetricName($var) + { + GPBUtil::checkString($var, True); + $this->metric_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MetricOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_MetricOrderBy::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php new file mode 100644 index 00000000000..4fd1c22f4b2 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php @@ -0,0 +1,120 @@ +google.analytics.data.v1beta.OrderBy.PivotOrderBy + */ +class PivotOrderBy extends \Google\Protobuf\Internal\Message +{ + /** + * In the response to order by, order rows by this column. Must be a metric + * name from the request. + * + * Generated from protobuf field string metric_name = 1; + */ + protected $metric_name = ''; + /** + * Used to select a dimension name and value pivot. If multiple pivot + * selections are given, the sort occurs on rows where all pivot selection + * dimension name and value pairs match the row's dimension name and value + * pair. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; + */ + private $pivot_selections; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $metric_name + * In the response to order by, order rows by this column. Must be a metric + * name from the request. + * @type array<\Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection>|\Google\Protobuf\Internal\RepeatedField $pivot_selections + * Used to select a dimension name and value pivot. If multiple pivot + * selections are given, the sort occurs on rows where all pivot selection + * dimension name and value pairs match the row's dimension name and value + * pair. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * In the response to order by, order rows by this column. Must be a metric + * name from the request. + * + * Generated from protobuf field string metric_name = 1; + * @return string + */ + public function getMetricName() + { + return $this->metric_name; + } + + /** + * In the response to order by, order rows by this column. Must be a metric + * name from the request. + * + * Generated from protobuf field string metric_name = 1; + * @param string $var + * @return $this + */ + public function setMetricName($var) + { + GPBUtil::checkString($var, True); + $this->metric_name = $var; + + return $this; + } + + /** + * Used to select a dimension name and value pivot. If multiple pivot + * selections are given, the sort occurs on rows where all pivot selection + * dimension name and value pairs match the row's dimension name and value + * pair. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPivotSelections() + { + return $this->pivot_selections; + } + + /** + * Used to select a dimension name and value pivot. If multiple pivot + * selections are given, the sort occurs on rows where all pivot selection + * dimension name and value pairs match the row's dimension name and value + * pair. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; + * @param array<\Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPivotSelections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection::class); + $this->pivot_selections = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PivotOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_PivotOrderBy::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php new file mode 100644 index 00000000000..d50a7262d48 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php @@ -0,0 +1,117 @@ +google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection + */ +class PivotSelection extends \Google\Protobuf\Internal\Message +{ + /** + * Must be a dimension name from the request. + * + * Generated from protobuf field string dimension_name = 1; + */ + protected $dimension_name = ''; + /** + * Order by only when the named dimension is this value. + * + * Generated from protobuf field string dimension_value = 2; + */ + protected $dimension_value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dimension_name + * Must be a dimension name from the request. + * @type string $dimension_value + * Order by only when the named dimension is this value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Must be a dimension name from the request. + * + * Generated from protobuf field string dimension_name = 1; + * @return string + */ + public function getDimensionName() + { + return $this->dimension_name; + } + + /** + * Must be a dimension name from the request. + * + * Generated from protobuf field string dimension_name = 1; + * @param string $var + * @return $this + */ + public function setDimensionName($var) + { + GPBUtil::checkString($var, True); + $this->dimension_name = $var; + + return $this; + } + + /** + * Order by only when the named dimension is this value. + * + * Generated from protobuf field string dimension_value = 2; + * @return string + */ + public function getDimensionValue() + { + return $this->dimension_value; + } + + /** + * Order by only when the named dimension is this value. + * + * Generated from protobuf field string dimension_value = 2; + * @param string $var + * @return $this + */ + public function setDimensionValue($var) + { + GPBUtil::checkString($var, True); + $this->dimension_value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PivotSelection::class, \Google\Analytics\Data\V1beta\OrderBy_PivotOrderBy_PivotSelection::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php new file mode 100644 index 00000000000..1569a761e9b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php @@ -0,0 +1,255 @@ +google.analytics.data.v1beta.Pivot + */ +class Pivot extends \Google\Protobuf\Internal\Message +{ + /** + * Dimension names for visible columns in the report response. Including + * "dateRange" produces a date range column; for each row in the response, + * dimension values in the date range column will indicate the corresponding + * date range from the request. + * + * Generated from protobuf field repeated string field_names = 1; + */ + private $field_names; + /** + * Specifies how dimensions are ordered in the pivot. In the first Pivot, the + * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent + * Pivots, the OrderBys determine only PivotDimensionHeader ordering. + * Dimensions specified in these OrderBys must be a subset of + * Pivot.field_names. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; + */ + private $order_bys; + /** + * The row count of the start row. The first row is counted as row 0. + * + * Generated from protobuf field int64 offset = 3; + */ + protected $offset = 0; + /** + * The number of unique combinations of dimension values to return in this + * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for + * single pivot requests. + * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` + * must not exceed 250,000. For example, a two pivot request with `limit: + * 1000` in each pivot will fail because the product is `1,000,000`. + * + * Generated from protobuf field int64 limit = 4; + */ + protected $limit = 0; + /** + * Aggregate the metrics by dimensions in this pivot using the specified + * metric_aggregations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; + */ + private $metric_aggregations; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $field_names + * Dimension names for visible columns in the report response. Including + * "dateRange" produces a date range column; for each row in the response, + * dimension values in the date range column will indicate the corresponding + * date range from the request. + * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys + * Specifies how dimensions are ordered in the pivot. In the first Pivot, the + * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent + * Pivots, the OrderBys determine only PivotDimensionHeader ordering. + * Dimensions specified in these OrderBys must be a subset of + * Pivot.field_names. + * @type int|string $offset + * The row count of the start row. The first row is counted as row 0. + * @type int|string $limit + * The number of unique combinations of dimension values to return in this + * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for + * single pivot requests. + * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` + * must not exceed 250,000. For example, a two pivot request with `limit: + * 1000` in each pivot will fail because the product is `1,000,000`. + * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations + * Aggregate the metrics by dimensions in this pivot using the specified + * metric_aggregations. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Dimension names for visible columns in the report response. Including + * "dateRange" produces a date range column; for each row in the response, + * dimension values in the date range column will indicate the corresponding + * date range from the request. + * + * Generated from protobuf field repeated string field_names = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFieldNames() + { + return $this->field_names; + } + + /** + * Dimension names for visible columns in the report response. Including + * "dateRange" produces a date range column; for each row in the response, + * dimension values in the date range column will indicate the corresponding + * date range from the request. + * + * Generated from protobuf field repeated string field_names = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFieldNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->field_names = $arr; + + return $this; + } + + /** + * Specifies how dimensions are ordered in the pivot. In the first Pivot, the + * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent + * Pivots, the OrderBys determine only PivotDimensionHeader ordering. + * Dimensions specified in these OrderBys must be a subset of + * Pivot.field_names. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrderBys() + { + return $this->order_bys; + } + + /** + * Specifies how dimensions are ordered in the pivot. In the first Pivot, the + * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent + * Pivots, the OrderBys determine only PivotDimensionHeader ordering. + * Dimensions specified in these OrderBys must be a subset of + * Pivot.field_names. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; + * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrderBys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); + $this->order_bys = $arr; + + return $this; + } + + /** + * The row count of the start row. The first row is counted as row 0. + * + * Generated from protobuf field int64 offset = 3; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * The row count of the start row. The first row is counted as row 0. + * + * Generated from protobuf field int64 offset = 3; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * The number of unique combinations of dimension values to return in this + * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for + * single pivot requests. + * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` + * must not exceed 250,000. For example, a two pivot request with `limit: + * 1000` in each pivot will fail because the product is `1,000,000`. + * + * Generated from protobuf field int64 limit = 4; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * The number of unique combinations of dimension values to return in this + * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for + * single pivot requests. + * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` + * must not exceed 250,000. For example, a two pivot request with `limit: + * 1000` in each pivot will fail because the product is `1,000,000`. + * + * Generated from protobuf field int64 limit = 4; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + + /** + * Aggregate the metrics by dimensions in this pivot using the specified + * metric_aggregations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricAggregations() + { + return $this->metric_aggregations; + } + + /** + * Aggregate the metrics by dimensions in this pivot using the specified + * metric_aggregations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricAggregations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); + $this->metric_aggregations = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php new file mode 100644 index 00000000000..a96c75982ac --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php @@ -0,0 +1,67 @@ +google.analytics.data.v1beta.PivotDimensionHeader + */ +class PivotDimensionHeader extends \Google\Protobuf\Internal\Message +{ + /** + * Values of multiple dimensions in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + */ + private $dimension_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values + * Values of multiple dimensions in a pivot. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Values of multiple dimensions in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionValues() + { + return $this->dimension_values; + } + + /** + * Values of multiple dimensions in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionValue::class); + $this->dimension_values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php new file mode 100644 index 00000000000..e53d39b9c1f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php @@ -0,0 +1,113 @@ +google.analytics.data.v1beta.PivotHeader + */ +class PivotHeader extends \Google\Protobuf\Internal\Message +{ + /** + * The size is the same as the cardinality of the corresponding dimension + * combinations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; + */ + private $pivot_dimension_headers; + /** + * The cardinality of the pivot. The total number of rows for this pivot's + * fields regardless of how the parameters `offset` and `limit` are specified + * in the request. + * + * Generated from protobuf field int32 row_count = 2; + */ + protected $row_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\PivotDimensionHeader>|\Google\Protobuf\Internal\RepeatedField $pivot_dimension_headers + * The size is the same as the cardinality of the corresponding dimension + * combinations. + * @type int $row_count + * The cardinality of the pivot. The total number of rows for this pivot's + * fields regardless of how the parameters `offset` and `limit` are specified + * in the request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The size is the same as the cardinality of the corresponding dimension + * combinations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPivotDimensionHeaders() + { + return $this->pivot_dimension_headers; + } + + /** + * The size is the same as the cardinality of the corresponding dimension + * combinations. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; + * @param array<\Google\Analytics\Data\V1beta\PivotDimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPivotDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\PivotDimensionHeader::class); + $this->pivot_dimension_headers = $arr; + + return $this; + } + + /** + * The cardinality of the pivot. The total number of rows for this pivot's + * fields regardless of how the parameters `offset` and `limit` are specified + * in the request. + * + * Generated from protobuf field int32 row_count = 2; + * @return int + */ + public function getRowCount() + { + return $this->row_count; + } + + /** + * The cardinality of the pivot. The total number of rows for this pivot's + * fields regardless of how the parameters `offset` and `limit` are specified + * in the request. + * + * Generated from protobuf field int32 row_count = 2; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php new file mode 100644 index 00000000000..689ca28e00d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php @@ -0,0 +1,363 @@ +google.analytics.data.v1beta.PropertyQuota + */ +class PropertyQuota extends \Google\Protobuf\Internal\Message +{ + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; + */ + protected $tokens_per_day = null; + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; + */ + protected $tokens_per_hour = null; + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; + */ + protected $concurrent_requests = 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; + */ + protected $server_errors_per_project_per_hour = 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; + */ + protected $potentially_thresholded_requests_per_hour = null; + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; + */ + protected $tokens_per_project_per_hour = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_day + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_hour + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * @type \Google\Analytics\Data\V1beta\QuotaStatus $concurrent_requests + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * @type \Google\Analytics\Data\V1beta\QuotaStatus $server_errors_per_project_per_hour + * 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. + * @type \Google\Analytics\Data\V1beta\QuotaStatus $potentially_thresholded_requests_per_hour + * 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. + * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_project_per_hour + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getTokensPerDay() + { + return $this->tokens_per_day; + } + + public function hasTokensPerDay() + { + return isset($this->tokens_per_day); + } + + public function clearTokensPerDay() + { + unset($this->tokens_per_day); + } + + /** + * Standard Analytics Properties can use up to 200,000 tokens per day; + * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests + * consume fewer than 10 tokens. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setTokensPerDay($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->tokens_per_day = $var; + + return $this; + } + + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getTokensPerHour() + { + return $this->tokens_per_hour; + } + + public function hasTokensPerHour() + { + return isset($this->tokens_per_hour); + } + + public function clearTokensPerHour() + { + unset($this->tokens_per_hour); + } + + /** + * Standard Analytics Properties can use up to 40,000 tokens per hour; + * Analytics 360 Properties can use 400,000 tokens per hour. An API request + * consumes a single number of tokens, and that number is deducted from all of + * the hourly, daily, and per project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setTokensPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->tokens_per_hour = $var; + + return $this; + } + + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getConcurrentRequests() + { + return $this->concurrent_requests; + } + + public function hasConcurrentRequests() + { + return isset($this->concurrent_requests); + } + + public function clearConcurrentRequests() + { + unset($this->concurrent_requests); + } + + /** + * Standard Analytics Properties can send up to 10 concurrent requests; + * Analytics 360 Properties can use up to 50 concurrent requests. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setConcurrentRequests($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->concurrent_requests = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getServerErrorsPerProjectPerHour() + { + return $this->server_errors_per_project_per_hour; + } + + public function hasServerErrorsPerProjectPerHour() + { + return isset($this->server_errors_per_project_per_hour); + } + + public function clearServerErrorsPerProjectPerHour() + { + unset($this->server_errors_per_project_per_hour); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setServerErrorsPerProjectPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->server_errors_per_project_per_hour = $var; + + 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getPotentiallyThresholdedRequestsPerHour() + { + return $this->potentially_thresholded_requests_per_hour; + } + + public function hasPotentiallyThresholdedRequestsPerHour() + { + return isset($this->potentially_thresholded_requests_per_hour); + } + + public function clearPotentiallyThresholdedRequestsPerHour() + { + unset($this->potentially_thresholded_requests_per_hour); + } + + /** + * 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. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setPotentiallyThresholdedRequestsPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->potentially_thresholded_requests_per_hour = $var; + + return $this; + } + + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; + * @return \Google\Analytics\Data\V1beta\QuotaStatus|null + */ + public function getTokensPerProjectPerHour() + { + return $this->tokens_per_project_per_hour; + } + + public function hasTokensPerProjectPerHour() + { + return isset($this->tokens_per_project_per_hour); + } + + public function clearTokensPerProjectPerHour() + { + unset($this->tokens_per_project_per_hour); + } + + /** + * Analytics Properties can use up to 35% of their tokens per project per + * hour. This amounts to standard Analytics Properties can use up to 14,000 + * tokens per project per hour, and Analytics 360 Properties can use 140,000 + * tokens per project per hour. An API request consumes a single number of + * tokens, and that number is deducted from all of the hourly, daily, and per + * project hourly quotas. + * + * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; + * @param \Google\Analytics\Data\V1beta\QuotaStatus $var + * @return $this + */ + public function setTokensPerProjectPerHour($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); + $this->tokens_per_project_per_hour = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php new file mode 100644 index 00000000000..2c72532b7d9 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php @@ -0,0 +1,205 @@ +google.analytics.data.v1beta.QueryAudienceExportRequest + */ +class QueryAudienceExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $name = ''; + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $offset = 0; + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $limit = 0; + + /** + * @param string $name Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * @return \Google\Analytics\Data\V1beta\QueryAudienceExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * @type int|string $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int|string $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * Optional. The row count of the start row. The first row is counted as row + * 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php new file mode 100644 index 00000000000..71591a68897 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php @@ -0,0 +1,191 @@ +google.analytics.data.v1beta.QueryAudienceExportResponse + */ +class QueryAudienceExportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Configuration data about AudienceExport being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceExport correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; + */ + protected $audience_export = null; + /** + * Rows for each user in an audience export. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; + */ + private $audience_rows; + /** + * The total number of rows in the AudienceExport result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + */ + protected $row_count = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Analytics\Data\V1beta\AudienceExport $audience_export + * Configuration data about AudienceExport being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceExport correspond to the columns in the AudienceRows. + * @type array<\Google\Analytics\Data\V1beta\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $audience_rows + * Rows for each user in an audience export. The number of rows in this + * response will be less than or equal to request's page size. + * @type int $row_count + * The total number of rows in the AudienceExport result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Configuration data about AudienceExport being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceExport correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; + * @return \Google\Analytics\Data\V1beta\AudienceExport|null + */ + public function getAudienceExport() + { + return $this->audience_export; + } + + public function hasAudienceExport() + { + return isset($this->audience_export); + } + + public function clearAudienceExport() + { + unset($this->audience_export); + } + + /** + * Configuration data about AudienceExport being queried. Returned to help + * interpret the audience rows in this response. For example, the dimensions + * in this AudienceExport correspond to the columns in the AudienceRows. + * + * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; + * @param \Google\Analytics\Data\V1beta\AudienceExport $var + * @return $this + */ + public function setAudienceExport($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\AudienceExport::class); + $this->audience_export = $var; + + return $this; + } + + /** + * Rows for each user in an audience export. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAudienceRows() + { + return $this->audience_rows; + } + + /** + * Rows for each user in an audience export. The number of rows in this + * response will be less than or equal to request's page size. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; + * @param array<\Google\Analytics\Data\V1beta\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAudienceRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceRow::class); + $this->audience_rows = $arr; + + return $this; + } + + /** + * The total number of rows in the AudienceExport result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @return int + */ + public function getRowCount() + { + return isset($this->row_count) ? $this->row_count : 0; + } + + public function hasRowCount() + { + return isset($this->row_count); + } + + public function clearRowCount() + { + unset($this->row_count); + } + + /** + * The total number of rows in the AudienceExport result. `rowCount` is + * independent of the number of rows returned in the response, the `limit` + * request parameter, and the `offset` request parameter. For example if a + * query returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field optional int32 row_count = 3; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php new file mode 100644 index 00000000000..77a8b488f2e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php @@ -0,0 +1,121 @@ +google.analytics.data.v1beta.QuotaStatus + */ +class QuotaStatus extends \Google\Protobuf\Internal\Message +{ + /** + * Quota consumed by this request. + * + * Generated from protobuf field optional int32 consumed = 1; + */ + protected $consumed = null; + /** + * Quota remaining after this request. + * + * Generated from protobuf field optional int32 remaining = 2; + */ + protected $remaining = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $consumed + * Quota consumed by this request. + * @type int $remaining + * Quota remaining after this request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * Quota consumed by this request. + * + * Generated from protobuf field optional int32 consumed = 1; + * @return int + */ + public function getConsumed() + { + return isset($this->consumed) ? $this->consumed : 0; + } + + public function hasConsumed() + { + return isset($this->consumed); + } + + public function clearConsumed() + { + unset($this->consumed); + } + + /** + * Quota consumed by this request. + * + * Generated from protobuf field optional int32 consumed = 1; + * @param int $var + * @return $this + */ + public function setConsumed($var) + { + GPBUtil::checkInt32($var); + $this->consumed = $var; + + return $this; + } + + /** + * Quota remaining after this request. + * + * Generated from protobuf field optional int32 remaining = 2; + * @return int + */ + public function getRemaining() + { + return isset($this->remaining) ? $this->remaining : 0; + } + + public function hasRemaining() + { + return isset($this->remaining); + } + + public function clearRemaining() + { + unset($this->remaining); + } + + /** + * Quota remaining after this request. + * + * Generated from protobuf field optional int32 remaining = 2; + * @param int $var + * @return $this + */ + public function setRemaining($var) + { + GPBUtil::checkInt32($var); + $this->remaining = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php new file mode 100644 index 00000000000..a2642b63961 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php @@ -0,0 +1,457 @@ +google.analytics.data.v1beta.ResponseMetaData + */ +class ResponseMetaData extends \Google\Protobuf\Internal\Message +{ + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + */ + protected $data_loss_from_other_row = false; + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + */ + protected $schema_restriction_response = null; + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + */ + protected $currency_code = null; + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + */ + protected $time_zone = null; + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + */ + protected $empty_reason = null; + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + */ + protected $subject_to_thresholding = null; + /** + * If this report results is + * [sampled](https://support.google.com/analytics/answer/13331292), this + * describes the percentage of events used in this 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; + */ + private $sampling_metadatas; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $data_loss_from_other_row + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * @type \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse $schema_restriction_response + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * @type string $currency_code + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * @type string $time_zone + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * @type string $empty_reason + * If empty reason is specified, the report is empty for this reason. + * @type bool $subject_to_thresholding + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630). + * @type array<\Google\Analytics\Data\V1beta\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $sampling_metadatas + * If this report results is + * [sampled](https://support.google.com/analytics/answer/13331292), this + * describes the percentage of events used in this 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. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + * @return bool + */ + public function getDataLossFromOtherRow() + { + return $this->data_loss_from_other_row; + } + + /** + * If true, indicates some buckets of dimension combinations are rolled into + * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * + * Generated from protobuf field bool data_loss_from_other_row = 3; + * @param bool $var + * @return $this + */ + public function setDataLossFromOtherRow($var) + { + GPBUtil::checkBool($var); + $this->data_loss_from_other_row = $var; + + return $this; + } + + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @return \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse|null + */ + public function getSchemaRestrictionResponse() + { + return $this->schema_restriction_response; + } + + public function hasSchemaRestrictionResponse() + { + return isset($this->schema_restriction_response); + } + + public function clearSchemaRestrictionResponse() + { + unset($this->schema_restriction_response); + } + + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @param \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse $var + * @return $this + */ + public function setSchemaRestrictionResponse($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse::class); + $this->schema_restriction_response = $var; + + return $this; + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @return string + */ + public function getCurrencyCode() + { + return isset($this->currency_code) ? $this->currency_code : ''; + } + + public function hasCurrencyCode() + { + return isset($this->currency_code); + } + + public function clearCurrencyCode() + { + unset($this->currency_code); + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @return string + */ + public function getTimeZone() + { + return isset($this->time_zone) ? $this->time_zone : ''; + } + + public function hasTimeZone() + { + return isset($this->time_zone); + } + + public function clearTimeZone() + { + unset($this->time_zone); + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @param string $var + * @return $this + */ + public function setTimeZone($var) + { + GPBUtil::checkString($var, True); + $this->time_zone = $var; + + return $this; + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @return string + */ + public function getEmptyReason() + { + return isset($this->empty_reason) ? $this->empty_reason : ''; + } + + public function hasEmptyReason() + { + return isset($this->empty_reason); + } + + public function clearEmptyReason() + { + unset($this->empty_reason); + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @param string $var + * @return $this + */ + public function setEmptyReason($var) + { + GPBUtil::checkString($var, True); + $this->empty_reason = $var; + + return $this; + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @return bool + */ + public function getSubjectToThresholding() + { + return isset($this->subject_to_thresholding) ? $this->subject_to_thresholding : false; + } + + public function hasSubjectToThresholding() + { + return isset($this->subject_to_thresholding); + } + + public function clearSubjectToThresholding() + { + unset($this->subject_to_thresholding); + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @param bool $var + * @return $this + */ + public function setSubjectToThresholding($var) + { + GPBUtil::checkBool($var); + $this->subject_to_thresholding = $var; + + return $this; + } + + /** + * If this report results is + * [sampled](https://support.google.com/analytics/answer/13331292), this + * describes the percentage of events used in this 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSamplingMetadatas() + { + return $this->sampling_metadatas; + } + + /** + * If this report results is + * [sampled](https://support.google.com/analytics/answer/13331292), this + * describes the percentage of events used in this 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. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; + * @param array<\Google\Analytics\Data\V1beta\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSamplingMetadatas($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\SamplingMetadata::class); + $this->sampling_metadatas = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php new file mode 100644 index 00000000000..38739908def --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php @@ -0,0 +1,84 @@ +google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse + */ +class SchemaRestrictionResponse extends \Google\Protobuf\Internal\Message +{ + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + */ + private $active_metric_restrictions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $active_metric_restrictions + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getActiveMetricRestrictions() + { + return $this->active_metric_restrictions; + } + + /** + * All restrictions actively enforced in creating the report. For example, + * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. + * However, this active response restriction is only populated if the user's + * custom role disallows access to `REVENUE_DATA`. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; + * @param array<\Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setActiveMetricRestrictions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction::class); + $this->active_metric_restrictions = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SchemaRestrictionResponse::class, \Google\Analytics\Data\V1beta\ResponseMetaData_SchemaRestrictionResponse::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php new file mode 100644 index 00000000000..246f6d81d0c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php @@ -0,0 +1,114 @@ +google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction + */ +class ActiveMetricRestriction extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + */ + protected $metric_name = null; + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; + */ + private $restricted_metric_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $metric_name + * The name of the restricted metric. + * @type array|\Google\Protobuf\Internal\RepeatedField $restricted_metric_types + * The reason for this metric's restriction. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + * @return string + */ + public function getMetricName() + { + return isset($this->metric_name) ? $this->metric_name : ''; + } + + public function hasMetricName() + { + return isset($this->metric_name); + } + + public function clearMetricName() + { + unset($this->metric_name); + } + + /** + * The name of the restricted metric. + * + * Generated from protobuf field optional string metric_name = 1; + * @param string $var + * @return $this + */ + public function setMetricName($var) + { + GPBUtil::checkString($var, True); + $this->metric_name = $var; + + return $this; + } + + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRestrictedMetricTypes() + { + return $this->restricted_metric_types; + } + + /** + * The reason for this metric's restriction. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRestrictedMetricTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\RestrictedMetricType::class); + $this->restricted_metric_types = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ActiveMetricRestriction::class, \Google\Analytics\Data\V1beta\ResponseMetaData_SchemaRestrictionResponse_ActiveMetricRestriction::class); + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php new file mode 100644 index 00000000000..4d77bccc258 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php @@ -0,0 +1,62 @@ +google.analytics.data.v1beta.RestrictedMetricType + */ +class RestrictedMetricType +{ + /** + * Unspecified type. + * + * Generated from protobuf enum RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; + */ + const RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; + /** + * Cost metrics such as `adCost`. + * + * Generated from protobuf enum COST_DATA = 1; + */ + const COST_DATA = 1; + /** + * Revenue metrics such as `purchaseRevenue`. + * + * Generated from protobuf enum REVENUE_DATA = 2; + */ + const REVENUE_DATA = 2; + + private static $valueToName = [ + self::RESTRICTED_METRIC_TYPE_UNSPECIFIED => 'RESTRICTED_METRIC_TYPE_UNSPECIFIED', + self::COST_DATA => 'COST_DATA', + self::REVENUE_DATA => 'REVENUE_DATA', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php new file mode 100644 index 00000000000..fb28b01a352 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php @@ -0,0 +1,138 @@ +google.analytics.data.v1beta.Row + */ +class Row extends \Google\Protobuf\Internal\Message +{ + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + */ + private $dimension_values; + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; + */ + private $metric_values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * @type array<\Google\Analytics\Data\V1beta\MetricValue>|\Google\Protobuf\Internal\RepeatedField $metric_values + * List of requested visible metric values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionValues() + { + return $this->dimension_values; + } + + /** + * List of requested dimension values. In a PivotReport, dimension_values + * are only listed for dimensions included in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionValue::class); + $this->dimension_values = $arr; + + return $this; + } + + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricValues() + { + return $this->metric_values; + } + + /** + * List of requested visible metric values. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; + * @param array<\Google\Analytics\Data\V1beta\MetricValue>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricValue::class); + $this->metric_values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php new file mode 100644 index 00000000000..e08a64ae635 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php @@ -0,0 +1,553 @@ +google.analytics.data.v1beta.RunPivotReportRequest + */ +class RunPivotReportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * 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 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * The dimensions requested. All defined dimensions must be used by one of the + * following: dimension_expression, dimension_filter, pivots, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + */ + private $dimensions; + /** + * The metrics requested, at least one metric needs to be specified. All + * defined metrics must be used by one of the following: metric_expression, + * metric_filter, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + */ + private $metrics; + /** + * The date range to retrieve event data for the report. If multiple date + * ranges are specified, event data from each date range is used in the + * report. A special dimension with field name "dateRange" can be included in + * a Pivot's field names; if included, the report compares between date + * ranges. In a cohort request, this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + */ + private $date_ranges; + /** + * Describes the visual format of the report's dimensions in columns or rows. + * The union of the fieldNames (dimension names) in all pivots must be a + * subset of dimension names defined in Dimensions. No two pivots can share a + * dimension. A dimension is only visible if it appears in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; + */ + private $pivots; + /** + * The filter clause of dimensions. Dimensions must be requested to be used in + * this filter. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; + */ + protected $dimension_filter = null; + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Metrics must be requested to be used in this filter. + * Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; + */ + protected $metric_filter = null; + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 8; + */ + protected $currency_code = ''; + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; + */ + protected $cohort_spec = null; + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 10; + */ + protected $keep_empty_rows = false; + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 11; + */ + protected $return_property_quota = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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 + * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * The dimensions requested. All defined dimensions must be used by one of the + * following: dimension_expression, dimension_filter, pivots, order_bys. + * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics + * The metrics requested, at least one metric needs to be specified. All + * defined metrics must be used by one of the following: metric_expression, + * metric_filter, order_bys. + * @type array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges + * The date range to retrieve event data for the report. If multiple date + * ranges are specified, event data from each date range is used in the + * report. A special dimension with field name "dateRange" can be included in + * a Pivot's field names; if included, the report compares between date + * ranges. In a cohort request, this `dateRanges` must be unspecified. + * @type array<\Google\Analytics\Data\V1beta\Pivot>|\Google\Protobuf\Internal\RepeatedField $pivots + * Describes the visual format of the report's dimensions in columns or rows. + * The union of the fieldNames (dimension names) in all pivots must be a + * subset of dimension names defined in Dimensions. No two pivots can share a + * dimension. A dimension is only visible if it appears in a pivot. + * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter + * The filter clause of dimensions. Dimensions must be requested to be used in + * this filter. Metrics cannot be used in this filter. + * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Metrics must be requested to be used in this filter. + * Dimensions cannot be used in this filter. + * @type string $currency_code + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * @type \Google\Analytics\Data\V1beta\CohortSpec $cohort_spec + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * @type bool $keep_empty_rows + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * @type bool $return_property_quota + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->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 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * The dimensions requested. All defined dimensions must be used by one of the + * following: dimension_expression, dimension_filter, pivots, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * The dimensions requested. All defined dimensions must be used by one of the + * following: dimension_expression, dimension_filter, pivots, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * The metrics requested, at least one metric needs to be specified. All + * defined metrics must be used by one of the following: metric_expression, + * metric_filter, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * The metrics requested, at least one metric needs to be specified. All + * defined metrics must be used by one of the following: metric_expression, + * metric_filter, order_bys. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); + $this->metrics = $arr; + + return $this; + } + + /** + * The date range to retrieve event data for the report. If multiple date + * ranges are specified, event data from each date range is used in the + * report. A special dimension with field name "dateRange" can be included in + * a Pivot's field names; if included, the report compares between date + * ranges. In a cohort request, this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDateRanges() + { + return $this->date_ranges; + } + + /** + * The date range to retrieve event data for the report. If multiple date + * ranges are specified, event data from each date range is used in the + * report. A special dimension with field name "dateRange" can be included in + * a Pivot's field names; if included, the report compares between date + * ranges. In a cohort request, this `dateRanges` must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + * @param array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDateRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DateRange::class); + $this->date_ranges = $arr; + + return $this; + } + + /** + * Describes the visual format of the report's dimensions in columns or rows. + * The union of the fieldNames (dimension names) in all pivots must be a + * subset of dimension names defined in Dimensions. No two pivots can share a + * dimension. A dimension is only visible if it appears in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPivots() + { + return $this->pivots; + } + + /** + * Describes the visual format of the report's dimensions in columns or rows. + * The union of the fieldNames (dimension names) in all pivots must be a + * subset of dimension names defined in Dimensions. No two pivots can share a + * dimension. A dimension is only visible if it appears in a pivot. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; + * @param array<\Google\Analytics\Data\V1beta\Pivot>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPivots($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Pivot::class); + $this->pivots = $arr; + + return $this; + } + + /** + * The filter clause of dimensions. Dimensions must be requested to be used in + * this filter. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * The filter clause of dimensions. Dimensions must be requested to be used in + * this filter. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Metrics must be requested to be used in this filter. + * Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getMetricFilter() + { + return $this->metric_filter; + } + + public function hasMetricFilter() + { + return isset($this->metric_filter); + } + + public function clearMetricFilter() + { + unset($this->metric_filter); + } + + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Metrics must be requested to be used in this filter. + * Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setMetricFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->metric_filter = $var; + + return $this; + } + + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 8; + * @return string + */ + public function getCurrencyCode() + { + return $this->currency_code; + } + + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 8; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; + * @return \Google\Analytics\Data\V1beta\CohortSpec|null + */ + public function getCohortSpec() + { + return $this->cohort_spec; + } + + public function hasCohortSpec() + { + return isset($this->cohort_spec); + } + + public function clearCohortSpec() + { + unset($this->cohort_spec); + } + + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; + * @param \Google\Analytics\Data\V1beta\CohortSpec $var + * @return $this + */ + public function setCohortSpec($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortSpec::class); + $this->cohort_spec = $var; + + return $this; + } + + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 10; + * @return bool + */ + public function getKeepEmptyRows() + { + return $this->keep_empty_rows; + } + + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 10; + * @param bool $var + * @return $this + */ + public function setKeepEmptyRows($var) + { + GPBUtil::checkBool($var); + $this->keep_empty_rows = $var; + + return $this; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 11; + * @return bool + */ + public function getReturnPropertyQuota() + { + return $this->return_property_quota; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 11; + * @param bool $var + * @return $this + */ + public function setReturnPropertyQuota($var) + { + GPBUtil::checkBool($var); + $this->return_property_quota = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php new file mode 100644 index 00000000000..959e315a49f --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php @@ -0,0 +1,481 @@ +google.analytics.data.v1beta.RunPivotReportResponse + */ +class RunPivotReportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Summarizes the columns and rows created by a pivot. Each pivot in the + * request produces one header in the response. If we have a request like + * this: + * "pivots": [{ + * "fieldNames": ["country", + * "city"] + * }, + * { + * "fieldNames": "eventName" + * }] + * We will have the following `pivotHeaders` in the response: + * "pivotHeaders" : [{ + * "dimensionHeaders": [{ + * "dimensionValues": [ + * { "value": "United Kingdom" }, + * { "value": "London" } + * ] + * }, + * { + * "dimensionValues": [ + * { "value": "Japan" }, + * { "value": "Osaka" } + * ] + * }] + * }, + * { + * "dimensionHeaders": [{ + * "dimensionValues": [{ "value": "session_start" }] + * }, + * { + * "dimensionValues": [{ "value": "scroll" }] + * }] + * }] + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; + */ + private $pivot_headers; + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; + */ + private $dimension_headers; + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; + */ + private $metric_headers; + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; + */ + private $rows; + /** + * Aggregation of metric values. Can be totals, minimums, or maximums. The + * returned aggregations are controlled by the metric_aggregations in the + * pivot. The type of aggregation returned in each row is shown by the + * dimension_values which are set to "RESERVED_". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; + */ + private $aggregates; + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; + */ + protected $metadata = null; + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; + */ + protected $property_quota = null; + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runPivotReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 8; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\PivotHeader>|\Google\Protobuf\Internal\RepeatedField $pivot_headers + * Summarizes the columns and rows created by a pivot. Each pivot in the + * request produces one header in the response. If we have a request like + * this: + * "pivots": [{ + * "fieldNames": ["country", + * "city"] + * }, + * { + * "fieldNames": "eventName" + * }] + * We will have the following `pivotHeaders` in the response: + * "pivotHeaders" : [{ + * "dimensionHeaders": [{ + * "dimensionValues": [ + * { "value": "United Kingdom" }, + * { "value": "London" } + * ] + * }, + * { + * "dimensionValues": [ + * { "value": "Japan" }, + * { "value": "Osaka" } + * ] + * }] + * }, + * { + * "dimensionHeaders": [{ + * "dimensionValues": [{ "value": "session_start" }] + * }, + * { + * "dimensionValues": [{ "value": "scroll" }] + * }] + * }] + * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of dimension value combinations and metric values in the report. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $aggregates + * Aggregation of metric values. Can be totals, minimums, or maximums. The + * returned aggregations are controlled by the metric_aggregations in the + * pivot. The type of aggregation returned in each row is shown by the + * dimension_values which are set to "RESERVED_". + * @type \Google\Analytics\Data\V1beta\ResponseMetaData $metadata + * Metadata for the report. + * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota + * This Analytics Property's quota state including this request. + * @type string $kind + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runPivotReport". Useful to distinguish between + * response types in JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Summarizes the columns and rows created by a pivot. Each pivot in the + * request produces one header in the response. If we have a request like + * this: + * "pivots": [{ + * "fieldNames": ["country", + * "city"] + * }, + * { + * "fieldNames": "eventName" + * }] + * We will have the following `pivotHeaders` in the response: + * "pivotHeaders" : [{ + * "dimensionHeaders": [{ + * "dimensionValues": [ + * { "value": "United Kingdom" }, + * { "value": "London" } + * ] + * }, + * { + * "dimensionValues": [ + * { "value": "Japan" }, + * { "value": "Osaka" } + * ] + * }] + * }, + * { + * "dimensionHeaders": [{ + * "dimensionValues": [{ "value": "session_start" }] + * }, + * { + * "dimensionValues": [{ "value": "scroll" }] + * }] + * }] + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPivotHeaders() + { + return $this->pivot_headers; + } + + /** + * Summarizes the columns and rows created by a pivot. Each pivot in the + * request produces one header in the response. If we have a request like + * this: + * "pivots": [{ + * "fieldNames": ["country", + * "city"] + * }, + * { + * "fieldNames": "eventName" + * }] + * We will have the following `pivotHeaders` in the response: + * "pivotHeaders" : [{ + * "dimensionHeaders": [{ + * "dimensionValues": [ + * { "value": "United Kingdom" }, + * { "value": "London" } + * ] + * }, + * { + * "dimensionValues": [ + * { "value": "Japan" }, + * { "value": "Osaka" } + * ] + * }] + * }, + * { + * "dimensionHeaders": [{ + * "dimensionValues": [{ "value": "session_start" }] + * }, + * { + * "dimensionValues": [{ "value": "scroll" }] + * }] + * }] + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; + * @param array<\Google\Analytics\Data\V1beta\PivotHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPivotHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\PivotHeader::class); + $this->pivot_headers = $arr; + + return $this; + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionHeaders() + { + return $this->dimension_headers; + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; + * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); + $this->dimension_headers = $arr; + + return $this; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricHeaders() + { + return $this->metric_headers; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; + * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); + $this->metric_headers = $arr; + + return $this; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->rows = $arr; + + return $this; + } + + /** + * Aggregation of metric values. Can be totals, minimums, or maximums. The + * returned aggregations are controlled by the metric_aggregations in the + * pivot. The type of aggregation returned in each row is shown by the + * dimension_values which are set to "RESERVED_". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAggregates() + { + return $this->aggregates; + } + + /** + * Aggregation of metric values. Can be totals, minimums, or maximums. The + * returned aggregations are controlled by the metric_aggregations in the + * pivot. The type of aggregation returned in each row is shown by the + * dimension_values which are set to "RESERVED_". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAggregates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->aggregates = $arr; + + return $this; + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; + * @return \Google\Analytics\Data\V1beta\ResponseMetaData|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; + * @param \Google\Analytics\Data\V1beta\ResponseMetaData $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData::class); + $this->metadata = $var; + + return $this; + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; + * @return \Google\Analytics\Data\V1beta\PropertyQuota|null + */ + public function getPropertyQuota() + { + return $this->property_quota; + } + + public function hasPropertyQuota() + { + return isset($this->property_quota); + } + + public function clearPropertyQuota() + { + unset($this->property_quota); + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; + * @param \Google\Analytics\Data\V1beta\PropertyQuota $var + * @return $this + */ + public function setPropertyQuota($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); + $this->property_quota = $var; + + return $this; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runPivotReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 8; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runPivotReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 8; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php new file mode 100644 index 00000000000..9d96cefe0a9 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php @@ -0,0 +1,465 @@ +google.analytics.data.v1beta.RunRealtimeReportRequest + */ +class RunRealtimeReportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * 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). + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + */ + private $dimensions; + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + */ + private $metrics; + /** + * The filter clause of dimensions. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + */ + protected $dimension_filter = null; + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + */ + protected $metric_filter = null; + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 6; + */ + protected $limit = 0; + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; + */ + private $metric_aggregations; + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; + */ + private $order_bys; + /** + * Toggles whether to return the current state of this Analytics Property's + * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 9; + */ + protected $return_property_quota = false; + /** + * The minute ranges of event data to read. If unspecified, one minute range + * for the last 30 minutes will be used. If multiple minute ranges are + * requested, each response row will contain a zero based minute range index. + * If two minute ranges overlap, the event data for the overlapping minutes is + * included in the response rows for both minute ranges. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; + */ + private $minute_ranges; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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). + * Example: properties/1234 + * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * The dimensions requested and displayed. + * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics + * The metrics requested and displayed. + * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter + * The filter clause of dimensions. Metrics cannot be used in this filter. + * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Dimensions cannot be used in this filter. + * @type int|string $limit + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys + * Specifies how rows are ordered in the response. + * @type bool $return_property_quota + * Toggles whether to return the current state of this Analytics Property's + * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * @type array<\Google\Analytics\Data\V1beta\MinuteRange>|\Google\Protobuf\Internal\RepeatedField $minute_ranges + * The minute ranges of event data to read. If unspecified, one minute range + * for the last 30 minutes will be used. If multiple minute ranges are + * requested, each response row will contain a zero based minute range index. + * If two minute ranges overlap, the event data for the overlapping minutes is + * included in the response rows for both minute ranges. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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). + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->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). + * Example: properties/1234 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); + $this->metrics = $arr; + + return $this; + } + + /** + * The filter clause of dimensions. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * The filter clause of dimensions. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getMetricFilter() + { + return $this->metric_filter; + } + + public function hasMetricFilter() + { + return isset($this->metric_filter); + } + + public function clearMetricFilter() + { + unset($this->metric_filter); + } + + /** + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setMetricFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->metric_filter = $var; + + return $this; + } + + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 6; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * + * Generated from protobuf field int64 limit = 6; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricAggregations() + { + return $this->metric_aggregations; + } + + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricAggregations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); + $this->metric_aggregations = $arr; + + return $this; + } + + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrderBys() + { + return $this->order_bys; + } + + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; + * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrderBys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); + $this->order_bys = $arr; + + return $this; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 9; + * @return bool + */ + public function getReturnPropertyQuota() + { + return $this->return_property_quota; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 9; + * @param bool $var + * @return $this + */ + public function setReturnPropertyQuota($var) + { + GPBUtil::checkBool($var); + $this->return_property_quota = $var; + + return $this; + } + + /** + * The minute ranges of event data to read. If unspecified, one minute range + * for the last 30 minutes will be used. If multiple minute ranges are + * requested, each response row will contain a zero based minute range index. + * If two minute ranges overlap, the event data for the overlapping minutes is + * included in the response rows for both minute ranges. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMinuteRanges() + { + return $this->minute_ranges; + } + + /** + * The minute ranges of event data to read. If unspecified, one minute range + * for the last 30 minutes will be used. If multiple minute ranges are + * requested, each response row will contain a zero based minute range index. + * If two minute ranges overlap, the event data for the overlapping minutes is + * included in the response rows for both minute ranges. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; + * @param array<\Google\Analytics\Data\V1beta\MinuteRange>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMinuteRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MinuteRange::class); + $this->minute_ranges = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php new file mode 100644 index 00000000000..4ff50b9d77b --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php @@ -0,0 +1,381 @@ +google.analytics.data.v1beta.RunRealtimeReportResponse + */ +class RunRealtimeReportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + */ + private $dimension_headers; + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + */ + private $metric_headers; + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + */ + private $rows; + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + */ + private $totals; + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + */ + private $maximums; + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + */ + private $minimums; + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response and the `limit` request + * parameter. For example if a query returns 175 rows and includes `limit` + * of 50 in the API request, the response will contain `rowCount` of 175 but + * only 50 rows. + * + * Generated from protobuf field int32 row_count = 7; + */ + protected $row_count = 0; + /** + * This Analytics Property's Realtime quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; + */ + protected $property_quota = null; + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runRealtimeReport". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 9; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of dimension value combinations and metric values in the report. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $totals + * If requested, the totaled values of metrics. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $maximums + * If requested, the maximum values of metrics. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $minimums + * If requested, the minimum values of metrics. + * @type int $row_count + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response and the `limit` request + * parameter. For example if a query returns 175 rows and includes `limit` + * of 50 in the API request, the response will contain `rowCount` of 175 but + * only 50 rows. + * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota + * This Analytics Property's Realtime quota state including this request. + * @type string $kind + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runRealtimeReport". Useful to distinguish + * between response types in JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionHeaders() + { + return $this->dimension_headers; + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); + $this->dimension_headers = $arr; + + return $this; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricHeaders() + { + return $this->metric_headers; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); + $this->metric_headers = $arr; + + return $this; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->rows = $arr; + + return $this; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTotals() + { + return $this->totals; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTotals($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->totals = $arr; + + return $this; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaximums() + { + return $this->maximums; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaximums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->maximums = $arr; + + return $this; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMinimums() + { + return $this->minimums; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMinimums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->minimums = $arr; + + return $this; + } + + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response and the `limit` request + * parameter. For example if a query returns 175 rows and includes `limit` + * of 50 in the API request, the response will contain `rowCount` of 175 but + * only 50 rows. + * + * Generated from protobuf field int32 row_count = 7; + * @return int + */ + public function getRowCount() + { + return $this->row_count; + } + + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response and the `limit` request + * parameter. For example if a query returns 175 rows and includes `limit` + * of 50 in the API request, the response will contain `rowCount` of 175 but + * only 50 rows. + * + * Generated from protobuf field int32 row_count = 7; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * This Analytics Property's Realtime quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; + * @return \Google\Analytics\Data\V1beta\PropertyQuota|null + */ + public function getPropertyQuota() + { + return $this->property_quota; + } + + public function hasPropertyQuota() + { + return isset($this->property_quota); + } + + public function clearPropertyQuota() + { + unset($this->property_quota); + } + + /** + * This Analytics Property's Realtime quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; + * @param \Google\Analytics\Data\V1beta\PropertyQuota $var + * @return $this + */ + public function setPropertyQuota($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); + $this->property_quota = $var; + + return $this; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runRealtimeReport". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 9; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runRealtimeReport". Useful to distinguish + * between response types in JSON. + * + * Generated from protobuf field string kind = 9; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php new file mode 100644 index 00000000000..6f0d9ba7a92 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php @@ -0,0 +1,699 @@ +google.analytics.data.v1beta.RunReportRequest + */ +class RunReportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * 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 + * + * Generated from protobuf field string property = 1; + */ + protected $property = ''; + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + */ + private $dimensions; + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + */ + private $metrics; + /** + * 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. In a cohort request, this `dateRanges` + * must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + */ + private $date_ranges; + /** + * Dimension filters let you ask for only specific dimension values in + * the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; + */ + protected $dimension_filter = null; + /** + * The filter clause of metrics. Applied after aggregating the report's rows, + * similar to SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; + */ + protected $metric_filter = null; + /** + * The row count of the start row. The first row is counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 7; + */ + protected $offset = 0; + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 8; + */ + protected $limit = 0; + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; + */ + private $metric_aggregations; + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; + */ + private $order_bys; + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11; + */ + protected $currency_code = ''; + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; + */ + protected $cohort_spec = null; + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13; + */ + protected $keep_empty_rows = false; + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 14; + */ + protected $return_property_quota = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $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 + * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions + * The dimensions requested and displayed. + * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics + * The metrics requested and displayed. + * @type array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges + * 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. In a cohort request, this `dateRanges` + * must be unspecified. + * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter + * Dimension filters let you ask for only specific dimension values in + * the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter + * The filter clause of metrics. Applied after aggregating the report's rows, + * similar to SQL having-clause. Dimensions cannot be used in this filter. + * @type int|string $offset + * The row count of the start row. The first row is counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int|string $limit + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys + * Specifies how rows are ordered in the response. + * @type string $currency_code + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * @type \Google\Analytics\Data\V1beta\CohortSpec $cohort_spec + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * @type bool $keep_empty_rows + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * @type bool $return_property_quota + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * 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 + * + * Generated from protobuf field string property = 1; + * @return string + */ + public function getProperty() + { + return $this->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 + * + * Generated from protobuf field string property = 1; + * @param string $var + * @return $this + */ + public function setProperty($var) + { + GPBUtil::checkString($var, True); + $this->property = $var; + + return $this; + } + + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * The dimensions requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; + * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); + $this->dimensions = $arr; + + return $this; + } + + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetrics() + { + return $this->metrics; + } + + /** + * The metrics requested and displayed. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; + * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetrics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); + $this->metrics = $arr; + + 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. In a cohort request, this `dateRanges` + * must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDateRanges() + { + return $this->date_ranges; + } + + /** + * 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. In a cohort request, this `dateRanges` + * must be unspecified. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; + * @param array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDateRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DateRange::class); + $this->date_ranges = $arr; + + return $this; + } + + /** + * Dimension filters let you ask for only specific dimension values in + * the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getDimensionFilter() + { + return $this->dimension_filter; + } + + public function hasDimensionFilter() + { + return isset($this->dimension_filter); + } + + public function clearDimensionFilter() + { + unset($this->dimension_filter); + } + + /** + * Dimension filters let you ask for only specific dimension values in + * the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setDimensionFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->dimension_filter = $var; + + return $this; + } + + /** + * The filter clause of metrics. Applied after aggregating the report's rows, + * similar to SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; + * @return \Google\Analytics\Data\V1beta\FilterExpression|null + */ + public function getMetricFilter() + { + return $this->metric_filter; + } + + public function hasMetricFilter() + { + return isset($this->metric_filter); + } + + public function clearMetricFilter() + { + unset($this->metric_filter); + } + + /** + * The filter clause of metrics. Applied after aggregating the report's rows, + * similar to SQL having-clause. Dimensions cannot be used in this filter. + * + * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; + * @param \Google\Analytics\Data\V1beta\FilterExpression $var + * @return $this + */ + public function setMetricFilter($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); + $this->metric_filter = $var; + + return $this; + } + + /** + * The row count of the start row. The first row is counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 7; + * @return int|string + */ + public function getOffset() + { + return $this->offset; + } + + /** + * The row count of the start row. The first row is counted as row 0. + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 offset = 7; + * @param int|string $var + * @return $this + */ + public function setOffset($var) + { + GPBUtil::checkInt64($var); + $this->offset = $var; + + return $this; + } + + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 8; + * @return int|string + */ + public function getLimit() + { + return $this->limit; + } + + /** + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int64 limit = 8; + * @param int|string $var + * @return $this + */ + public function setLimit($var) + { + GPBUtil::checkInt64($var); + $this->limit = $var; + + return $this; + } + + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricAggregations() + { + return $this->metric_aggregations; + } + + /** + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricAggregations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); + $this->metric_aggregations = $arr; + + return $this; + } + + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrderBys() + { + return $this->order_bys; + } + + /** + * Specifies how rows are ordered in the response. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; + * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrderBys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); + $this->order_bys = $arr; + + return $this; + } + + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11; + * @return string + */ + public function getCurrencyCode() + { + return $this->currency_code; + } + + /** + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * + * Generated from protobuf field string currency_code = 11; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; + * @return \Google\Analytics\Data\V1beta\CohortSpec|null + */ + public function getCohortSpec() + { + return $this->cohort_spec; + } + + public function hasCohortSpec() + { + return isset($this->cohort_spec); + } + + public function clearCohortSpec() + { + unset($this->cohort_spec); + } + + /** + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * + * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; + * @param \Google\Analytics\Data\V1beta\CohortSpec $var + * @return $this + */ + public function setCohortSpec($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortSpec::class); + $this->cohort_spec = $var; + + return $this; + } + + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13; + * @return bool + */ + public function getKeepEmptyRows() + { + return $this->keep_empty_rows; + } + + /** + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * + * Generated from protobuf field bool keep_empty_rows = 13; + * @param bool $var + * @return $this + */ + public function setKeepEmptyRows($var) + { + GPBUtil::checkBool($var); + $this->keep_empty_rows = $var; + + return $this; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 14; + * @return bool + */ + public function getReturnPropertyQuota() + { + return $this->return_property_quota; + } + + /** + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * + * Generated from protobuf field bool return_property_quota = 14; + * @param bool $var + * @return $this + */ + public function setReturnPropertyQuota($var) + { + GPBUtil::checkBool($var); + $this->return_property_quota = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php new file mode 100644 index 00000000000..6825d24eb51 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php @@ -0,0 +1,433 @@ +google.analytics.data.v1beta.RunReportResponse + */ +class RunReportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + */ + private $dimension_headers; + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + */ + private $metric_headers; + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + */ + private $rows; + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + */ + private $totals; + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + */ + private $maximums; + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + */ + private $minimums; + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response, the `limit` request + * parameter, and the `offset` request parameter. For example if a query + * returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int32 row_count = 7; + */ + protected $row_count = 0; + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; + */ + protected $metadata = null; + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; + */ + protected $property_quota = null; + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 10; + */ + protected $kind = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows + * Rows of dimension value combinations and metric values in the report. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $totals + * If requested, the totaled values of metrics. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $maximums + * If requested, the maximum values of metrics. + * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $minimums + * If requested, the minimum values of metrics. + * @type int $row_count + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response, the `limit` request + * parameter, and the `offset` request parameter. For example if a query + * returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type \Google\Analytics\Data\V1beta\ResponseMetaData $metadata + * Metadata for the report. + * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota + * This Analytics Property's quota state including this request. + * @type string $kind + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runReport". Useful to distinguish between + * response types in JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); + parent::__construct($data); + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDimensionHeaders() + { + return $this->dimension_headers; + } + + /** + * Describes dimension columns. The number of DimensionHeaders and ordering of + * DimensionHeaders matches the dimensions present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; + * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDimensionHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); + $this->dimension_headers = $arr; + + return $this; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMetricHeaders() + { + return $this->metric_headers; + } + + /** + * Describes metric columns. The number of MetricHeaders and ordering of + * MetricHeaders matches the metrics present in rows. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; + * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMetricHeaders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); + $this->metric_headers = $arr; + + return $this; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRows() + { + return $this->rows; + } + + /** + * Rows of dimension value combinations and metric values in the report. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRows($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->rows = $arr; + + return $this; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTotals() + { + return $this->totals; + } + + /** + * If requested, the totaled values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTotals($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->totals = $arr; + + return $this; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMaximums() + { + return $this->maximums; + } + + /** + * If requested, the maximum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMaximums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->maximums = $arr; + + return $this; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMinimums() + { + return $this->minimums; + } + + /** + * If requested, the minimum values of metrics. + * + * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; + * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMinimums($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); + $this->minimums = $arr; + + return $this; + } + + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response, the `limit` request + * parameter, and the `offset` request parameter. For example if a query + * returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int32 row_count = 7; + * @return int + */ + public function getRowCount() + { + return $this->row_count; + } + + /** + * The total number of rows in the query result. `rowCount` is independent of + * the number of rows returned in the response, the `limit` request + * parameter, and the `offset` request parameter. For example if a query + * returns 175 rows and includes `limit` of 50 in the API request, the + * response will contain `rowCount` of 175 but only 50 rows. + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * + * Generated from protobuf field int32 row_count = 7; + * @param int $var + * @return $this + */ + public function setRowCount($var) + { + GPBUtil::checkInt32($var); + $this->row_count = $var; + + return $this; + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; + * @return \Google\Analytics\Data\V1beta\ResponseMetaData|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata for the report. + * + * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; + * @param \Google\Analytics\Data\V1beta\ResponseMetaData $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData::class); + $this->metadata = $var; + + return $this; + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; + * @return \Google\Analytics\Data\V1beta\PropertyQuota|null + */ + public function getPropertyQuota() + { + return $this->property_quota; + } + + public function hasPropertyQuota() + { + return isset($this->property_quota); + } + + public function clearPropertyQuota() + { + unset($this->property_quota); + } + + /** + * This Analytics Property's quota state including this request. + * + * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; + * @param \Google\Analytics\Data\V1beta\PropertyQuota $var + * @return $this + */ + public function setPropertyQuota($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); + $this->property_quota = $var; + + return $this; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 10; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Identifies what kind of resource this message is. This `kind` is always the + * fixed string "analyticsData#runReport". Useful to distinguish between + * response types in JSON. + * + * Generated from protobuf field string kind = 10; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php new file mode 100644 index 00000000000..c85383ee02e --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php @@ -0,0 +1,133 @@ +google.analytics.data.v1beta.SamplingMetadata + */ +class SamplingMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * 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 report. + * + * Generated from protobuf field int64 samples_read_count = 1; + */ + protected $samples_read_count = 0; + /** + * The total number of events present in this property's data that could + * have been analyzed in this 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 + * report, compute `samplesReadCount/samplingSpaceSize`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + */ + protected $sampling_space_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $samples_read_count + * 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 report. + * @type int|string $sampling_space_size + * The total number of events present in this property's data that could + * have been analyzed in this 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 + * report, compute `samplesReadCount/samplingSpaceSize`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); + parent::__construct($data); + } + + /** + * 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 report. + * + * Generated from protobuf field int64 samples_read_count = 1; + * @return int|string + */ + public function getSamplesReadCount() + { + return $this->samples_read_count; + } + + /** + * 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 report. + * + * Generated from protobuf field int64 samples_read_count = 1; + * @param int|string $var + * @return $this + */ + public function setSamplesReadCount($var) + { + GPBUtil::checkInt64($var); + $this->samples_read_count = $var; + + return $this; + } + + /** + * The total number of events present in this property's data that could + * have been analyzed in this 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 + * report, compute `samplesReadCount/samplingSpaceSize`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + * @return int|string + */ + public function getSamplingSpaceSize() + { + return $this->sampling_space_size; + } + + /** + * The total number of events present in this property's data that could + * have been analyzed in this 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 + * report, compute `samplesReadCount/samplingSpaceSize`. + * + * Generated from protobuf field int64 sampling_space_size = 2; + * @param int|string $var + * @return $this + */ + public function setSamplingSpaceSize($var) + { + GPBUtil::checkInt64($var); + $this->sampling_space_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php new file mode 100644 index 00000000000..7c893afaa92 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php @@ -0,0 +1,58 @@ +batchRunPivotReports($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_BatchRunPivotReports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php new file mode 100644 index 00000000000..bf9615abcee --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php @@ -0,0 +1,58 @@ +batchRunReports($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_BatchRunReports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php new file mode 100644 index 00000000000..ae432f155d1 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php @@ -0,0 +1,66 @@ +checkCompatibility($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_CheckCompatibility_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php new file mode 100644 index 00000000000..820fcfed54a --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php @@ -0,0 +1,122 @@ +setAudience($audienceExportAudience) + ->setDimensions($audienceExportDimensions); + $request = (new CreateAudienceExportRequest()) + ->setParent($formattedParent) + ->setAudienceExport($audienceExport); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $betaAnalyticsDataClient->createAudienceExport($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var AudienceExport $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = BetaAnalyticsDataClient::propertyName('[PROPERTY]'); + $audienceExportAudience = '[AUDIENCE]'; + + create_audience_export_sample($formattedParent, $audienceExportAudience); +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_CreateAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php new file mode 100644 index 00000000000..24bff6ab36c --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php @@ -0,0 +1,83 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var AudienceExport $response */ + $response = $betaAnalyticsDataClient->getAudienceExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = BetaAnalyticsDataClient::audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + + get_audience_export_sample($formattedName); +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_GetAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php new file mode 100644 index 00000000000..b5680a0483d --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php @@ -0,0 +1,90 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Metadata $response */ + $response = $betaAnalyticsDataClient->getMetadata($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = BetaAnalyticsDataClient::metadataName('[PROPERTY]'); + + get_metadata_sample($formattedName); +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_GetMetadata_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php new file mode 100644 index 00000000000..53031ca6a20 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php @@ -0,0 +1,91 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $betaAnalyticsDataClient->listAudienceExports($request); + + /** @var AudienceExport $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = BetaAnalyticsDataClient::propertyName('[PROPERTY]'); + + list_audience_exports_sample($formattedParent); +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_ListAudienceExports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php new file mode 100644 index 00000000000..013f2bbb524 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php @@ -0,0 +1,89 @@ +setName($name); + + // Call the API and handle any network failures. + try { + /** @var QueryAudienceExportResponse $response */ + $response = $betaAnalyticsDataClient->queryAudienceExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $name = '[NAME]'; + + query_audience_export_sample($name); +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_QueryAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php new file mode 100644 index 00000000000..796aef3d116 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php @@ -0,0 +1,61 @@ +runPivotReport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunPivotReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php new file mode 100644 index 00000000000..4c1d9e225cd --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php @@ -0,0 +1,65 @@ +runRealtimeReport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunRealtimeReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php new file mode 100644 index 00000000000..b4c1d2fea06 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php @@ -0,0 +1,67 @@ +runReport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php new file mode 100644 index 00000000000..5d708159cb0 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php @@ -0,0 +1,36 @@ + self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/beta_analytics_data_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/beta_analytics_data_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/beta_analytics_data_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/beta_analytics_data_rest_client_config.php', + ], + ], + ]; + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + * + * @experimental + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + * + * @experimental + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * audience_export resource. + * + * @param string $property + * @param string $audienceExport + * + * @return string The formatted audience_export resource. + * + * @experimental + */ + public static function audienceExportName(string $property, string $audienceExport): string + { + return self::getPathTemplate('audienceExport')->render([ + 'property' => $property, + 'audience_export' => $audienceExport, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a metadata + * resource. + * + * @param string $property + * + * @return string The formatted metadata resource. + * + * @experimental + */ + public static function metadataName(string $property): string + { + return self::getPathTemplate('metadata')->render([ + 'property' => $property, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a property + * resource. + * + * @param string $property + * + * @return string The formatted property resource. + * + * @experimental + */ + public static function propertyName(string $property): string + { + return self::getPathTemplate('property')->render([ + 'property' => $property, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - audienceExport: properties/{property}/audienceExports/{audience_export} + * - metadata: properties/{property}/metadata + * - property: properties/{property} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + * + * @experimental + */ + public static function parseName(string $formattedName, string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'analyticsdata.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + * + * @experimental + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Returns multiple pivot reports in a batch. All reports must be for the same + * GA4 Property. + * + * The async variant is {@see BetaAnalyticsDataClient::batchRunPivotReportsAsync()} + * . + * + * @example samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php + * + * @param BatchRunPivotReportsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BatchRunPivotReportsResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function batchRunPivotReports(BatchRunPivotReportsRequest $request, array $callOptions = []): BatchRunPivotReportsResponse + { + return $this->startApiCall('BatchRunPivotReports', $request, $callOptions)->wait(); + } + + /** + * Returns multiple reports in a batch. All reports must be for the same + * GA4 Property. + * + * The async variant is {@see BetaAnalyticsDataClient::batchRunReportsAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php + * + * @param BatchRunReportsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BatchRunReportsResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function batchRunReports(BatchRunReportsRequest $request, array $callOptions = []): BatchRunReportsResponse + { + return $this->startApiCall('BatchRunReports', $request, $callOptions)->wait(); + } + + /** + * This compatibility method lists dimensions and metrics that can be added to + * a report request and maintain compatibility. This method fails if the + * request's dimensions and metrics are incompatible. + * + * In Google Analytics, reports fail if they request incompatible dimensions + * and/or metrics; in that case, you will need to remove dimensions and/or + * metrics from the incompatible report until the report is compatible. + * + * The Realtime and Core reports have different compatibility rules. This + * method checks compatibility for Core reports. + * + * The async variant is {@see BetaAnalyticsDataClient::checkCompatibilityAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php + * + * @param CheckCompatibilityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return CheckCompatibilityResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function checkCompatibility(CheckCompatibilityRequest $request, array $callOptions = []): CheckCompatibilityResponse + { + return $this->startApiCall('CheckCompatibility', $request, $callOptions)->wait(); + } + + /** + * Creates an audience export for later retrieval. This method quickly returns + * the audience export's resource name and initiates a long running + * asynchronous request to form an audience export. To export the users in an + * audience export, first create the audience export through this method and + * then send the audience resource name to the `QueryAudienceExport` method. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * An audience export is a snapshot of the users currently in the audience at + * the time of audience export creation. Creating audience exports for one + * audience on different days will return different results as users enter and + * exit the audience. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. Audience exports + * contain the users in each audience. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see BetaAnalyticsDataClient::createAudienceExportAsync()} + * . + * + * @example samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php + * + * @param CreateAudienceExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function createAudienceExport(CreateAudienceExportRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateAudienceExport', $request, $callOptions)->wait(); + } + + /** + * Gets configuration metadata about a specific audience export. This method + * can be used to understand an audience export after it has been created. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see BetaAnalyticsDataClient::getAudienceExportAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php + * + * @param GetAudienceExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return AudienceExport + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getAudienceExport(GetAudienceExportRequest $request, array $callOptions = []): AudienceExport + { + return $this->startApiCall('GetAudienceExport', $request, $callOptions)->wait(); + } + + /** + * Returns metadata for dimensions and metrics available in reporting methods. + * Used to explore the dimensions and metrics. In this method, a Google + * Analytics GA4 Property Identifier is specified in the request, and + * the metadata response includes Custom dimensions and metrics as well as + * Universal metadata. + * + * For example if a custom metric with parameter name `levels_unlocked` is + * registered to a property, the Metadata response will contain + * `customEvent:levels_unlocked`. Universal metadata are dimensions and + * metrics applicable to any property such as `country` and `totalUsers`. + * + * The async variant is {@see BetaAnalyticsDataClient::getMetadataAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/get_metadata.php + * + * @param GetMetadataRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Metadata + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getMetadata(GetMetadataRequest $request, array $callOptions = []): Metadata + { + return $this->startApiCall('GetMetadata', $request, $callOptions)->wait(); + } + + /** + * Lists all audience exports for a property. This method can be used for you + * to find and reuse existing audience exports rather than creating + * unnecessary new audience exports. The same audience can have multiple + * audience exports that represent the export of users that were in an + * audience on different days. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see BetaAnalyticsDataClient::listAudienceExportsAsync()} + * . + * + * @example samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php + * + * @param ListAudienceExportsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function listAudienceExports(ListAudienceExportsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListAudienceExports', $request, $callOptions); + } + + /** + * Retrieves an audience export of users. After creating an audience, the + * users are not immediately available for exporting. First, a request to + * `CreateAudienceExport` is necessary to create an audience export of users, + * and then second, this method is used to retrieve the users in the audience + * export. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * The async variant is {@see BetaAnalyticsDataClient::queryAudienceExportAsync()} + * . + * + * @example samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php + * + * @param QueryAudienceExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return QueryAudienceExportResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function queryAudienceExport(QueryAudienceExportRequest $request, array $callOptions = []): QueryAudienceExportResponse + { + return $this->startApiCall('QueryAudienceExport', $request, $callOptions)->wait(); + } + + /** + * Returns a customized pivot report of your Google Analytics event data. + * Pivot reports are more advanced and expressive formats than regular + * reports. In a pivot report, dimensions are only visible if they are + * included in a pivot. Multiple pivots can be specified to further dissect + * your data. + * + * The async variant is {@see BetaAnalyticsDataClient::runPivotReportAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php + * + * @param RunPivotReportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RunPivotReportResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function runPivotReport(RunPivotReportRequest $request, array $callOptions = []): RunPivotReportResponse + { + return $this->startApiCall('RunPivotReport', $request, $callOptions)->wait(); + } + + /** + * Returns a customized report of realtime event data for your property. + * Events appear in realtime reports seconds after they have been sent to + * the Google Analytics. Realtime reports show events and usage data for the + * periods of time ranging from the present moment to 30 minutes ago (up to + * 60 minutes for Google Analytics 360 properties). + * + * For a guide to constructing realtime requests & understanding responses, + * see [Creating a Realtime + * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-basics). + * + * The async variant is {@see BetaAnalyticsDataClient::runRealtimeReportAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php + * + * @param RunRealtimeReportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RunRealtimeReportResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function runRealtimeReport(RunRealtimeReportRequest $request, array $callOptions = []): RunRealtimeReportResponse + { + return $this->startApiCall('RunRealtimeReport', $request, $callOptions)->wait(); + } + + /** + * Returns a customized report of your Google Analytics event data. Reports + * contain statistics derived from data collected by the Google Analytics + * tracking code. The data returned from the API is as a table with columns + * for the requested dimensions and metrics. Metrics are individual + * measurements of user activity on your property, such as active users or + * event count. Dimensions break down metrics across some common criteria, + * such as country or event name. + * + * For a guide to constructing requests & understanding responses, see + * [Creating a + * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/basics). + * + * The async variant is {@see BetaAnalyticsDataClient::runReportAsync()} . + * + * @example samples/V1beta/BetaAnalyticsDataClient/run_report.php + * + * @param RunReportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return RunReportResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function runReport(RunReportRequest $request, array $callOptions = []): RunReportResponse + { + return $this->startApiCall('RunReport', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php new file mode 100644 index 00000000000..9549cc52397 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php @@ -0,0 +1,1431 @@ +batchRunPivotReports(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * 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 parseName method to extract the individual identifiers + * contained within formatted names that are returned by the API. + * + * @experimental + * + * @deprecated Please use the new service client {@see \Google\Analytics\Data\V1beta\Client\BetaAnalyticsDataClient}. + */ +class BetaAnalyticsDataGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'google.analytics.data.v1beta.BetaAnalyticsData'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + const SERVICE_ADDRESS = 'analyticsdata.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'analyticsdata.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/analytics', + 'https://www.googleapis.com/auth/analytics.readonly', + ]; + + private static $audienceExportNameTemplate; + + private static $metadataNameTemplate; + + private static $propertyNameTemplate; + + private static $pathTemplateMap; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/beta_analytics_data_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/beta_analytics_data_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/beta_analytics_data_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/beta_analytics_data_rest_client_config.php', + ], + ], + ]; + } + + private static function getAudienceExportNameTemplate() + { + if (self::$audienceExportNameTemplate == null) { + self::$audienceExportNameTemplate = new PathTemplate('properties/{property}/audienceExports/{audience_export}'); + } + + return self::$audienceExportNameTemplate; + } + + private static function getMetadataNameTemplate() + { + if (self::$metadataNameTemplate == null) { + self::$metadataNameTemplate = new PathTemplate('properties/{property}/metadata'); + } + + return self::$metadataNameTemplate; + } + + private static function getPropertyNameTemplate() + { + if (self::$propertyNameTemplate == null) { + self::$propertyNameTemplate = new PathTemplate('properties/{property}'); + } + + return self::$propertyNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'audienceExport' => self::getAudienceExportNameTemplate(), + 'metadata' => self::getMetadataNameTemplate(), + 'property' => self::getPropertyNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * audience_export resource. + * + * @param string $property + * @param string $audienceExport + * + * @return string The formatted audience_export resource. + * + * @experimental + */ + public static function audienceExportName($property, $audienceExport) + { + return self::getAudienceExportNameTemplate()->render([ + 'property' => $property, + 'audience_export' => $audienceExport, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a metadata + * resource. + * + * @param string $property + * + * @return string The formatted metadata resource. + * + * @experimental + */ + public static function metadataName($property) + { + return self::getMetadataNameTemplate()->render([ + 'property' => $property, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a property + * resource. + * + * @param string $property + * + * @return string The formatted property resource. + * + * @experimental + */ + public static function propertyName($property) + { + return self::getPropertyNameTemplate()->render([ + 'property' => $property, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - audienceExport: properties/{property}/audienceExports/{audience_export} + * - metadata: properties/{property}/metadata + * - property: properties/{property} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + * + * @experimental + */ + public static function parseName($formattedName, $template = null) + { + $templateMap = self::getPathTemplateMap(); + if ($template) { + if (!isset($templateMap[$template])) { + throw new ValidationException("Template name $template does not exist"); + } + + return $templateMap[$template]->match($formattedName); + } + + foreach ($templateMap as $templateName => $pathTemplate) { + try { + return $pathTemplate->match($formattedName); + } catch (ValidationException $ex) { + // Swallow the exception to continue trying other path templates + } + } + + throw new ValidationException("Input did not match any known format. Input: $formattedName"); + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + * + * @experimental + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + * + * @experimental + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'analyticsdata.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + * + * @experimental + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** + * Returns multiple pivot reports in a batch. All reports must be for the same + * GA4 Property. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->batchRunPivotReports(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $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). + * This property must be specified for the batch. The property within + * RunPivotReportRequest may either be unspecified or consistent with this + * property. + * + * Example: properties/1234 + * @type RunPivotReportRequest[] $requests + * Individual requests. Each request has a separate pivot report response. + * Each batch request is allowed up to 5 requests. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\BatchRunPivotReportsResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function batchRunPivotReports(array $optionalArgs = []) + { + $request = new BatchRunPivotReportsRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['requests'])) { + $request->setRequests($optionalArgs['requests']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('BatchRunPivotReports', BatchRunPivotReportsResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns multiple reports in a batch. All reports must be for the same + * GA4 Property. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->batchRunReports(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $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). + * This property must be specified for the batch. The property within + * RunReportRequest may either be unspecified or consistent with this + * property. + * + * Example: properties/1234 + * @type RunReportRequest[] $requests + * Individual requests. Each request has a separate report response. Each + * batch request is allowed up to 5 requests. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\BatchRunReportsResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function batchRunReports(array $optionalArgs = []) + { + $request = new BatchRunReportsRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['requests'])) { + $request->setRequests($optionalArgs['requests']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('BatchRunReports', BatchRunReportsResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * This compatibility method lists dimensions and metrics that can be added to + * a report request and maintain compatibility. This method fails if the + * request's dimensions and metrics are incompatible. + * + * In Google Analytics, reports fail if they request incompatible dimensions + * and/or metrics; in that case, you will need to remove dimensions and/or + * metrics from the incompatible report until the report is compatible. + * + * The Realtime and Core reports have different compatibility rules. This + * method checks compatibility for Core reports. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->checkCompatibility(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $property + * A Google Analytics GA4 property identifier whose events are tracked. To + * learn more, see [where to find your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * `property` should be the same value as in your `runReport` request. + * + * Example: properties/1234 + * @type Dimension[] $dimensions + * The dimensions in this report. `dimensions` should be the same value as in + * your `runReport` request. + * @type Metric[] $metrics + * The metrics in this report. `metrics` should be the same value as in your + * `runReport` request. + * @type FilterExpression $dimensionFilter + * The filter clause of dimensions. `dimensionFilter` should be the same value + * as in your `runReport` request. + * @type FilterExpression $metricFilter + * The filter clause of metrics. `metricFilter` should be the same value as in + * your `runReport` request + * @type int $compatibilityFilter + * Filters the dimensions and metrics in the response to just this + * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` + * to only return compatible dimensions & metrics. + * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\Compatibility} + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\CheckCompatibilityResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function checkCompatibility(array $optionalArgs = []) + { + $request = new CheckCompatibilityRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['dimensions'])) { + $request->setDimensions($optionalArgs['dimensions']); + } + + if (isset($optionalArgs['metrics'])) { + $request->setMetrics($optionalArgs['metrics']); + } + + if (isset($optionalArgs['dimensionFilter'])) { + $request->setDimensionFilter($optionalArgs['dimensionFilter']); + } + + if (isset($optionalArgs['metricFilter'])) { + $request->setMetricFilter($optionalArgs['metricFilter']); + } + + if (isset($optionalArgs['compatibilityFilter'])) { + $request->setCompatibilityFilter($optionalArgs['compatibilityFilter']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CheckCompatibility', CheckCompatibilityResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates an audience export for later retrieval. This method quickly returns + * the audience export's resource name and initiates a long running + * asynchronous request to form an audience export. To export the users in an + * audience export, first create the audience export through this method and + * then send the audience resource name to the `QueryAudienceExport` method. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * An audience export is a snapshot of the users currently in the audience at + * the time of audience export creation. Creating audience exports for one + * audience on different days will return different results as users enter and + * exit the audience. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. Audience exports + * contain the users in each audience. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $formattedParent = $betaAnalyticsDataClient->propertyName('[PROPERTY]'); + * $audienceExport = new AudienceExport(); + * $operationResponse = $betaAnalyticsDataClient->createAudienceExport($formattedParent, $audienceExport); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $betaAnalyticsDataClient->createAudienceExport($formattedParent, $audienceExport); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $betaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceExport'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent resource where this audience export will be created. + * Format: `properties/{property}` + * @param AudienceExport $audienceExport Required. The audience export to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createAudienceExport($parent, $audienceExport, array $optionalArgs = []) + { + $request = new CreateAudienceExportRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setAudienceExport($audienceExport); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('CreateAudienceExport', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Gets configuration metadata about a specific audience export. This method + * can be used to understand an audience export after it has been created. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $formattedName = $betaAnalyticsDataClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + * $response = $betaAnalyticsDataClient->getAudienceExport($formattedName); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The audience export resource name. + * Format: `properties/{property}/audienceExports/{audience_export}` + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\AudienceExport + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getAudienceExport($name, array $optionalArgs = []) + { + $request = new GetAudienceExportRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetAudienceExport', AudienceExport::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns metadata for dimensions and metrics available in reporting methods. + * Used to explore the dimensions and metrics. In this method, a Google + * Analytics GA4 Property Identifier is specified in the request, and + * the metadata response includes Custom dimensions and metrics as well as + * Universal metadata. + * + * For example if a custom metric with parameter name `levels_unlocked` is + * registered to a property, the Metadata response will contain + * `customEvent:levels_unlocked`. Universal metadata are dimensions and + * metrics applicable to any property such as `country` and `totalUsers`. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $formattedName = $betaAnalyticsDataClient->metadataName('[PROPERTY]'); + * $response = $betaAnalyticsDataClient->getMetadata($formattedName); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The resource name of the metadata to retrieve. This name field is + * specified in the URL path and not URL parameters. Property is a numeric + * Google Analytics GA4 Property identifier. To learn more, see [where to find + * your Property + * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). + * + * Example: properties/1234/metadata + * + * 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. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\Metadata + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getMetadata($name, array $optionalArgs = []) + { + $request = new GetMetadataRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetMetadata', Metadata::class, $optionalArgs, $request)->wait(); + } + + /** + * Lists all audience exports for a property. This method can be used for you + * to find and reuse existing audience exports rather than creating + * unnecessary new audience exports. The same audience can have multiple + * audience exports that represent the export of users that were in an + * audience on different days. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $formattedParent = $betaAnalyticsDataClient->propertyName('[PROPERTY]'); + * // Iterate over pages of elements + * $pagedResponse = $betaAnalyticsDataClient->listAudienceExports($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $betaAnalyticsDataClient->listAudienceExports($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. All audience exports for this property will be listed in the + * response. Format: `properties/{property}` + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listAudienceExports($parent, array $optionalArgs = []) + { + $request = new ListAudienceExportsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListAudienceExports', $optionalArgs, ListAudienceExportsResponse::class, $request); + } + + /** + * Retrieves an audience export of users. After creating an audience, the + * users are not immediately available for exporting. First, a request to + * `CreateAudienceExport` is necessary to create an audience export of users, + * and then second, this method is used to retrieve the users in the audience + * export. + * + * See [Creating an Audience + * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) + * for an introduction to Audience Exports with examples. + * + * Audiences in Google Analytics 4 allow you to segment your users in the ways + * that are important to your business. To learn more, see + * https://support.google.com/analytics/answer/9267572. + * + * Audience Export APIs have some methods at alpha and other methods at beta + * stability. The intention is to advance methods to beta stability after some + * feedback and adoption. To give your feedback on this API, complete the + * [Google Analytics Audience Export API + * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $name = 'name'; + * $response = $betaAnalyticsDataClient->queryAudienceExport($name); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the audience export to retrieve users from. + * Format: `properties/{property}/audienceExports/{audience_export}` + * @param array $optionalArgs { + * Optional. + * + * @type int $offset + * Optional. The row count of the start row. The first row is counted as row + * 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * Optional. The number of rows to return. If unspecified, 10,000 rows are + * returned. The API returns a maximum of 250,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`. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\QueryAudienceExportResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function queryAudienceExport($name, array $optionalArgs = []) + { + $request = new QueryAudienceExportRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('QueryAudienceExport', QueryAudienceExportResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns a customized pivot report of your Google Analytics event data. + * Pivot reports are more advanced and expressive formats than regular + * reports. In a pivot report, dimensions are only visible if they are + * included in a pivot. Multiple pivots can be specified to further dissect + * your data. + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->runPivotReport(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $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 + * @type Dimension[] $dimensions + * The dimensions requested. All defined dimensions must be used by one of the + * following: dimension_expression, dimension_filter, pivots, order_bys. + * @type Metric[] $metrics + * The metrics requested, at least one metric needs to be specified. All + * defined metrics must be used by one of the following: metric_expression, + * metric_filter, order_bys. + * @type DateRange[] $dateRanges + * The date range to retrieve event data for the report. If multiple date + * ranges are specified, event data from each date range is used in the + * report. A special dimension with field name "dateRange" can be included in + * a Pivot's field names; if included, the report compares between date + * ranges. In a cohort request, this `dateRanges` must be unspecified. + * @type Pivot[] $pivots + * Describes the visual format of the report's dimensions in columns or rows. + * The union of the fieldNames (dimension names) in all pivots must be a + * subset of dimension names defined in Dimensions. No two pivots can share a + * dimension. A dimension is only visible if it appears in a pivot. + * @type FilterExpression $dimensionFilter + * The filter clause of dimensions. Dimensions must be requested to be used in + * this filter. Metrics cannot be used in this filter. + * @type FilterExpression $metricFilter + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Metrics must be requested to be used in this filter. + * Dimensions cannot be used in this filter. + * @type string $currencyCode + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * @type CohortSpec $cohortSpec + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * @type bool $keepEmptyRows + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * @type bool $returnPropertyQuota + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\RunPivotReportResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function runPivotReport(array $optionalArgs = []) + { + $request = new RunPivotReportRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['dimensions'])) { + $request->setDimensions($optionalArgs['dimensions']); + } + + if (isset($optionalArgs['metrics'])) { + $request->setMetrics($optionalArgs['metrics']); + } + + if (isset($optionalArgs['dateRanges'])) { + $request->setDateRanges($optionalArgs['dateRanges']); + } + + if (isset($optionalArgs['pivots'])) { + $request->setPivots($optionalArgs['pivots']); + } + + if (isset($optionalArgs['dimensionFilter'])) { + $request->setDimensionFilter($optionalArgs['dimensionFilter']); + } + + if (isset($optionalArgs['metricFilter'])) { + $request->setMetricFilter($optionalArgs['metricFilter']); + } + + if (isset($optionalArgs['currencyCode'])) { + $request->setCurrencyCode($optionalArgs['currencyCode']); + } + + if (isset($optionalArgs['cohortSpec'])) { + $request->setCohortSpec($optionalArgs['cohortSpec']); + } + + if (isset($optionalArgs['keepEmptyRows'])) { + $request->setKeepEmptyRows($optionalArgs['keepEmptyRows']); + } + + if (isset($optionalArgs['returnPropertyQuota'])) { + $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('RunPivotReport', RunPivotReportResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns a customized report of realtime event data for your property. + * Events appear in realtime reports seconds after they have been sent to + * the Google Analytics. Realtime reports show events and usage data for the + * periods of time ranging from the present moment to 30 minutes ago (up to + * 60 minutes for Google Analytics 360 properties). + * + * For a guide to constructing realtime requests & understanding responses, + * see [Creating a Realtime + * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-basics). + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->runRealtimeReport(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $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). + * + * Example: properties/1234 + * @type Dimension[] $dimensions + * The dimensions requested and displayed. + * @type Metric[] $metrics + * The metrics requested and displayed. + * @type FilterExpression $dimensionFilter + * The filter clause of dimensions. Metrics cannot be used in this filter. + * @type FilterExpression $metricFilter + * The filter clause of metrics. Applied at post aggregation phase, similar to + * SQL having-clause. Dimensions cannot be used in this filter. + * @type int $limit + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * @type int[] $metricAggregations + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\MetricAggregation} + * @type OrderBy[] $orderBys + * Specifies how rows are ordered in the response. + * @type bool $returnPropertyQuota + * Toggles whether to return the current state of this Analytics Property's + * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * @type MinuteRange[] $minuteRanges + * The minute ranges of event data to read. If unspecified, one minute range + * for the last 30 minutes will be used. If multiple minute ranges are + * requested, each response row will contain a zero based minute range index. + * If two minute ranges overlap, the event data for the overlapping minutes is + * included in the response rows for both minute ranges. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\RunRealtimeReportResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function runRealtimeReport(array $optionalArgs = []) + { + $request = new RunRealtimeReportRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['dimensions'])) { + $request->setDimensions($optionalArgs['dimensions']); + } + + if (isset($optionalArgs['metrics'])) { + $request->setMetrics($optionalArgs['metrics']); + } + + if (isset($optionalArgs['dimensionFilter'])) { + $request->setDimensionFilter($optionalArgs['dimensionFilter']); + } + + if (isset($optionalArgs['metricFilter'])) { + $request->setMetricFilter($optionalArgs['metricFilter']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + if (isset($optionalArgs['metricAggregations'])) { + $request->setMetricAggregations($optionalArgs['metricAggregations']); + } + + if (isset($optionalArgs['orderBys'])) { + $request->setOrderBys($optionalArgs['orderBys']); + } + + if (isset($optionalArgs['returnPropertyQuota'])) { + $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); + } + + if (isset($optionalArgs['minuteRanges'])) { + $request->setMinuteRanges($optionalArgs['minuteRanges']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('RunRealtimeReport', RunRealtimeReportResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns a customized report of your Google Analytics event data. Reports + * contain statistics derived from data collected by the Google Analytics + * tracking code. The data returned from the API is as a table with columns + * for the requested dimensions and metrics. Metrics are individual + * measurements of user activity on your property, such as active users or + * event count. Dimensions break down metrics across some common criteria, + * such as country or event name. + * + * For a guide to constructing requests & understanding responses, see + * [Creating a + * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/basics). + * + * Sample code: + * ``` + * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); + * try { + * $response = $betaAnalyticsDataClient->runReport(); + * } finally { + * $betaAnalyticsDataClient->close(); + * } + * ``` + * + * @param array $optionalArgs { + * Optional. + * + * @type string $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 + * @type Dimension[] $dimensions + * The dimensions requested and displayed. + * @type Metric[] $metrics + * The metrics requested and displayed. + * @type DateRange[] $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. In a cohort request, this `dateRanges` + * must be unspecified. + * @type FilterExpression $dimensionFilter + * Dimension filters let you ask for only specific dimension values in + * the report. To learn more, see [Fundamentals of Dimension + * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) + * for examples. Metrics cannot be used in this filter. + * @type FilterExpression $metricFilter + * The filter clause of metrics. Applied after aggregating the report's rows, + * similar to SQL having-clause. Dimensions cannot be used in this filter. + * @type int $offset + * The row count of the start row. The first row is counted as row 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * The number of rows to return. If unspecified, 10,000 rows are returned. The + * API returns a maximum of 250,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`. For instance, there are + * fewer than 300 possible values for the dimension `country`, so when + * reporting on only `country`, you can't get more than 300 rows, even if you + * set `limit` to a higher value. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int[] $metricAggregations + * Aggregation of metrics. Aggregated metric values will be shown in rows + * where the dimension_values are set to "RESERVED_(MetricAggregation)". + * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\MetricAggregation} + * @type OrderBy[] $orderBys + * Specifies how rows are ordered in the response. + * @type string $currencyCode + * A currency code in ISO4217 format, such as "AED", "USD", "JPY". + * If the field is empty, the report uses the property's default currency. + * @type CohortSpec $cohortSpec + * Cohort group associated with this request. If there is a cohort group + * in the request the 'cohort' dimension must be present. + * @type bool $keepEmptyRows + * If false or unspecified, each row with all metrics equal to 0 will not be + * returned. If true, these rows will be returned if they are not separately + * removed by a filter. + * + * Regardless of this `keep_empty_rows` setting, only data recorded by the + * Google Analytics (GA4) property can be displayed in a report. + * + * For example if a property never logs a `purchase` event, then a query for + * the `eventName` dimension and `eventCount` metric will not have a row + * eventName: "purchase" and eventCount: 0. + * @type bool $returnPropertyQuota + * Toggles whether to return the current state of this Analytics Property's + * quota. Quota is returned in [PropertyQuota](#PropertyQuota). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1beta\RunReportResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function runReport(array $optionalArgs = []) + { + $request = new RunReportRequest(); + $requestParamHeaders = []; + if (isset($optionalArgs['property'])) { + $request->setProperty($optionalArgs['property']); + $requestParamHeaders['property'] = $optionalArgs['property']; + } + + if (isset($optionalArgs['dimensions'])) { + $request->setDimensions($optionalArgs['dimensions']); + } + + if (isset($optionalArgs['metrics'])) { + $request->setMetrics($optionalArgs['metrics']); + } + + if (isset($optionalArgs['dateRanges'])) { + $request->setDateRanges($optionalArgs['dateRanges']); + } + + if (isset($optionalArgs['dimensionFilter'])) { + $request->setDimensionFilter($optionalArgs['dimensionFilter']); + } + + if (isset($optionalArgs['metricFilter'])) { + $request->setMetricFilter($optionalArgs['metricFilter']); + } + + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + if (isset($optionalArgs['metricAggregations'])) { + $request->setMetricAggregations($optionalArgs['metricAggregations']); + } + + if (isset($optionalArgs['orderBys'])) { + $request->setOrderBys($optionalArgs['orderBys']); + } + + if (isset($optionalArgs['currencyCode'])) { + $request->setCurrencyCode($optionalArgs['currencyCode']); + } + + if (isset($optionalArgs['cohortSpec'])) { + $request->setCohortSpec($optionalArgs['cohortSpec']); + } + + if (isset($optionalArgs['keepEmptyRows'])) { + $request->setKeepEmptyRows($optionalArgs['keepEmptyRows']); + } + + if (isset($optionalArgs['returnPropertyQuota'])) { + $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('RunReport', RunReportResponse::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json new file mode 100644 index 00000000000..335b5f181e5 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json @@ -0,0 +1,73 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.analytics.data.v1beta", + "libraryPackage": "Google\\Analytics\\Data\\V1beta", + "services": { + "BetaAnalyticsData": { + "clients": { + "grpc": { + "libraryClient": "BetaAnalyticsDataGapicClient", + "rpcs": { + "BatchRunPivotReports": { + "methods": [ + "batchRunPivotReports" + ] + }, + "BatchRunReports": { + "methods": [ + "batchRunReports" + ] + }, + "CheckCompatibility": { + "methods": [ + "checkCompatibility" + ] + }, + "CreateAudienceExport": { + "methods": [ + "createAudienceExport" + ] + }, + "GetAudienceExport": { + "methods": [ + "getAudienceExport" + ] + }, + "GetMetadata": { + "methods": [ + "getMetadata" + ] + }, + "ListAudienceExports": { + "methods": [ + "listAudienceExports" + ] + }, + "QueryAudienceExport": { + "methods": [ + "queryAudienceExport" + ] + }, + "RunPivotReport": { + "methods": [ + "runPivotReport" + ] + }, + "RunRealtimeReport": { + "methods": [ + "runRealtimeReport" + ] + }, + "RunReport": { + "methods": [ + "runReport" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json new file mode 100644 index 00000000000..b0f3237c5d3 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json @@ -0,0 +1,99 @@ +{ + "interfaces": { + "google.analytics.data.v1beta.BetaAnalyticsData": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNKNOWN" + ], + "no_retry_1_codes": [] + }, + "retry_params": { + "no_retry_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 0, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 0, + "total_timeout_millis": 0 + }, + "retry_policy_1_params": { + "initial_retry_delay_millis": 1000, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 60000, + "initial_rpc_timeout_millis": 60000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 60000, + "total_timeout_millis": 60000 + }, + "no_retry_1_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 60000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 60000, + "total_timeout_millis": 60000 + } + }, + "methods": { + "BatchRunPivotReports": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "BatchRunReports": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CheckCompatibility": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateAudienceExport": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetAudienceExport": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetMetadata": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "ListAudienceExports": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "QueryAudienceExport": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "RunPivotReport": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "RunRealtimeReport": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "RunReport": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + } + } + } + } +} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php new file mode 100644 index 00000000000..d98545e8578 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php @@ -0,0 +1,180 @@ + [ + 'google.analytics.data.v1beta.BetaAnalyticsData' => [ + 'CreateAudienceExport' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Analytics\Data\V1beta\AudienceExport', + 'metadataReturnType' => '\Google\Analytics\Data\V1beta\AudienceExportMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'BatchRunPivotReports' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\BatchRunPivotReportsResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'BatchRunReports' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\BatchRunReportsResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'CheckCompatibility' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\CheckCompatibilityResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'GetAudienceExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\AudienceExport', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetMetadata' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\Metadata', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListAudienceExports' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getAudienceExports', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\ListAudienceExportsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'QueryAudienceExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\QueryAudienceExportResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'RunPivotReport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\RunPivotReportResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'RunRealtimeReport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\RunRealtimeReportResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'RunReport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1beta\RunReportResponse', + 'headerParams' => [ + [ + 'keyName' => 'property', + 'fieldAccessors' => [ + 'getProperty', + ], + ], + ], + ], + 'templateMap' => [ + 'audienceExport' => 'properties/{property}/audienceExports/{audience_export}', + 'metadata' => 'properties/{property}/metadata', + 'property' => 'properties/{property}', + ], + ], + ], +]; diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php new file mode 100644 index 00000000000..d4183f113c4 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php @@ -0,0 +1,158 @@ + [ + 'google.analytics.data.v1beta.BetaAnalyticsData' => [ + 'BatchRunPivotReports' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:batchRunPivotReports', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'BatchRunReports' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:batchRunReports', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'CheckCompatibility' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:checkCompatibility', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'CreateAudienceExport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{parent=properties/*}/audienceExports', + 'body' => 'audience_export', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'GetAudienceExport' => [ + 'method' => 'get', + 'uriTemplate' => '/v1beta/{name=properties/*/audienceExports/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetMetadata' => [ + 'method' => 'get', + 'uriTemplate' => '/v1beta/{name=properties/*/metadata}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListAudienceExports' => [ + 'method' => 'get', + 'uriTemplate' => '/v1beta/{parent=properties/*}/audienceExports', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'QueryAudienceExport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{name=properties/*/audienceExports/*}:query', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'RunPivotReport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:runPivotReport', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'RunRealtimeReport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:runRealtimeReport', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + 'RunReport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1beta/{property=properties/*}:runReport', + 'body' => '*', + 'placeholders' => [ + 'property' => [ + 'getters' => [ + 'getProperty', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php new file mode 100644 index 00000000000..7b3d2e65321 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php @@ -0,0 +1,803 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return BetaAnalyticsDataClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new BetaAnalyticsDataClient($options); + } + + /** @test */ + public function batchRunPivotReportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new BatchRunPivotReportsResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->batchRunPivotReports(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunPivotReportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->batchRunPivotReports(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunReportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new BatchRunReportsResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->batchRunReports(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunReports', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunReportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->batchRunReports(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function checkCompatibilityTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new CheckCompatibilityResponse(); + $transport->addResponse($expectedResponse); + $response = $gapicClient->checkCompatibility(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CheckCompatibility', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function checkCompatibilityExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->checkCompatibility(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createAudienceExportTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceExportTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $expectedResponse = new AudienceExport(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createAudienceExportTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceExport = new AudienceExport(); + $audienceExportAudience = 'audienceExportAudience1191136508'; + $audienceExport->setAudience($audienceExportAudience); + $audienceExportDimensions = []; + $audienceExport->setDimensions($audienceExportDimensions); + $response = $gapicClient->createAudienceExport($formattedParent, $audienceExport); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CreateAudienceExport', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getAudienceExport(); + $this->assertProtobufEquals($audienceExport, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createAudienceExportExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceExportTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceExport = new AudienceExport(); + $audienceExportAudience = 'audienceExportAudience1191136508'; + $audienceExport->setAudience($audienceExportAudience); + $audienceExportDimensions = []; + $audienceExport->setDimensions($audienceExportDimensions); + $response = $gapicClient->createAudienceExport($formattedParent, $audienceExport); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function getAudienceExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $expectedResponse = new AudienceExport(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + $response = $gapicClient->getAudienceExport($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetAudienceExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getAudienceExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + try { + $gapicClient->getAudienceExport($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMetadataTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Metadata(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->metadataName('[PROPERTY]'); + $response = $gapicClient->getMetadata($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetMetadata', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMetadataExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->metadataName('[PROPERTY]'); + try { + $gapicClient->getMetadata($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceExportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $audienceExportsElement = new AudienceExport(); + $audienceExports = [ + $audienceExportsElement, + ]; + $expectedResponse = new ListAudienceExportsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setAudienceExports($audienceExports); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $response = $gapicClient->listAudienceExports($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getAudienceExports()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/ListAudienceExports', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceExportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + try { + $gapicClient->listAudienceExports($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryAudienceExportResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $response = $gapicClient->queryAudienceExport($name); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/QueryAudienceExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + try { + $gapicClient->queryAudienceExport($name); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runPivotReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new RunPivotReportResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->runPivotReport(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunPivotReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runPivotReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->runPivotReport(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runRealtimeReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $kind = 'kind3292052'; + $expectedResponse = new RunRealtimeReportResponse(); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->runRealtimeReport(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunRealtimeReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runRealtimeReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->runRealtimeReport(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $kind = 'kind3292052'; + $expectedResponse = new RunReportResponse(); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $response = $gapicClient->runReport(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + try { + $gapicClient->runReport(); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php new file mode 100644 index 00000000000..57d3ff4db25 --- /dev/null +++ b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php @@ -0,0 +1,872 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return BetaAnalyticsDataClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new BetaAnalyticsDataClient($options); + } + + /** @test */ + public function batchRunPivotReportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new BatchRunPivotReportsResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new BatchRunPivotReportsRequest(); + $response = $gapicClient->batchRunPivotReports($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunPivotReportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new BatchRunPivotReportsRequest(); + try { + $gapicClient->batchRunPivotReports($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunReportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new BatchRunReportsResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new BatchRunReportsRequest(); + $response = $gapicClient->batchRunReports($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunReports', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunReportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new BatchRunReportsRequest(); + try { + $gapicClient->batchRunReports($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function checkCompatibilityTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new CheckCompatibilityResponse(); + $transport->addResponse($expectedResponse); + $request = new CheckCompatibilityRequest(); + $response = $gapicClient->checkCompatibility($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CheckCompatibility', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function checkCompatibilityExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new CheckCompatibilityRequest(); + try { + $gapicClient->checkCompatibility($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createAudienceExportTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceExportTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $expectedResponse = new AudienceExport(); + $expectedResponse->setName($name); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createAudienceExportTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceExport = new AudienceExport(); + $audienceExportAudience = 'audienceExportAudience1191136508'; + $audienceExport->setAudience($audienceExportAudience); + $audienceExportDimensions = []; + $audienceExport->setDimensions($audienceExportDimensions); + $request = (new CreateAudienceExportRequest()) + ->setParent($formattedParent) + ->setAudienceExport($audienceExport); + $response = $gapicClient->createAudienceExport($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CreateAudienceExport', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getAudienceExport(); + $this->assertProtobufEquals($audienceExport, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createAudienceExportExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createAudienceExportTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $audienceExport = new AudienceExport(); + $audienceExportAudience = 'audienceExportAudience1191136508'; + $audienceExport->setAudience($audienceExportAudience); + $audienceExportDimensions = []; + $audienceExport->setDimensions($audienceExportDimensions); + $request = (new CreateAudienceExportRequest()) + ->setParent($formattedParent) + ->setAudienceExport($audienceExport); + $response = $gapicClient->createAudienceExport($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function getAudienceExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $audience = 'audience975628804'; + $audienceDisplayName = 'audienceDisplayName406858307'; + $creationQuotaTokensCharged = 1232901266; + $rowCount = 1340416618; + $errorMessage = 'errorMessage-1938755376'; + $percentageCompleted = -1.29204764E8; + $expectedResponse = new AudienceExport(); + $expectedResponse->setName($name2); + $expectedResponse->setAudience($audience); + $expectedResponse->setAudienceDisplayName($audienceDisplayName); + $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setErrorMessage($errorMessage); + $expectedResponse->setPercentageCompleted($percentageCompleted); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + $request = (new GetAudienceExportRequest()) + ->setName($formattedName); + $response = $gapicClient->getAudienceExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetAudienceExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getAudienceExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); + $request = (new GetAudienceExportRequest()) + ->setName($formattedName); + try { + $gapicClient->getAudienceExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMetadataTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Metadata(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->metadataName('[PROPERTY]'); + $request = (new GetMetadataRequest()) + ->setName($formattedName); + $response = $gapicClient->getMetadata($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetMetadata', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMetadataExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->metadataName('[PROPERTY]'); + $request = (new GetMetadataRequest()) + ->setName($formattedName); + try { + $gapicClient->getMetadata($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceExportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $audienceExportsElement = new AudienceExport(); + $audienceExports = [ + $audienceExportsElement, + ]; + $expectedResponse = new ListAudienceExportsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setAudienceExports($audienceExports); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListAudienceExportsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listAudienceExports($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getAudienceExports()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/ListAudienceExports', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAudienceExportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListAudienceExportsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listAudienceExports($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryAudienceExportResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $request = (new QueryAudienceExportRequest()) + ->setName($name); + $response = $gapicClient->queryAudienceExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/QueryAudienceExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryAudienceExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + $request = (new QueryAudienceExportRequest()) + ->setName($name); + try { + $gapicClient->queryAudienceExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runPivotReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new RunPivotReportResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new RunPivotReportRequest(); + $response = $gapicClient->runPivotReport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunPivotReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runPivotReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new RunPivotReportRequest(); + try { + $gapicClient->runPivotReport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runRealtimeReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $kind = 'kind3292052'; + $expectedResponse = new RunRealtimeReportResponse(); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new RunRealtimeReportRequest(); + $response = $gapicClient->runRealtimeReport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunRealtimeReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runRealtimeReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new RunRealtimeReportRequest(); + try { + $gapicClient->runRealtimeReport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $kind = 'kind3292052'; + $expectedResponse = new RunReportResponse(); + $expectedResponse->setRowCount($rowCount); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new RunReportRequest(); + $response = $gapicClient->runReport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunReport', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runReportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + $request = new RunReportRequest(); + try { + $gapicClient->runReport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchRunPivotReportsAsyncTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $kind = 'kind3292052'; + $expectedResponse = new BatchRunPivotReportsResponse(); + $expectedResponse->setKind($kind); + $transport->addResponse($expectedResponse); + $request = new BatchRunPivotReportsRequest(); + $response = $gapicClient->batchRunPivotReportsAsync($request)->wait(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } +} From a5680909cf86cd927309f613a87c8546443483ca Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 7 May 2024 02:58:23 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- .../metadata/V1Alpha/AnalyticsDataApi.php | Bin 8530 -> 11945 bytes AnalyticsData/metadata/V1Alpha/Data.php | Bin 13305 -> 15349 bytes .../create_report_task.php | 0 .../get_report_task.php | 0 .../list_report_tasks.php | 0 .../query_report_task.php | 0 .../Client/AlphaAnalyticsDataClient.php | 151 ++ AnalyticsData/src/V1alpha/Cohort.php | 16 +- AnalyticsData/src/V1alpha/CohortSpec.php | 24 +- AnalyticsData/src/V1alpha/CohortsRange.php | 32 +- .../src}/V1alpha/CreateReportTaskRequest.php | 4 +- .../Gapic/AlphaAnalyticsDataGapicClient.php | 348 ++++ .../src}/V1alpha/GetReportTaskRequest.php | 2 +- .../src}/V1alpha/ListReportTasksRequest.php | 6 +- .../src}/V1alpha/ListReportTasksResponse.php | 2 +- AnalyticsData/src/V1alpha/Metric.php | 76 +- AnalyticsData/src/V1alpha/OrderBy.php | 37 +- .../src}/V1alpha/QueryReportTaskRequest.php | 6 +- .../src}/V1alpha/QueryReportTaskResponse.php | 4 +- .../src}/V1alpha/ReportTask.php | 6 +- .../V1alpha/ReportTask/ReportDefinition.php | 16 +- .../V1alpha/ReportTask/ReportMetadata.php | 14 +- .../ReportTask/ReportMetadata/State.php | 2 - .../src}/V1alpha/ReportTaskMetadata.php | 0 .../src/V1alpha/ResponseMetaData.php | 336 ++++ .../SchemaRestrictionResponse.php | 2 - .../ActiveMetricRestriction.php | 4 +- .../src}/V1alpha/RestrictedMetricType.php | 0 AnalyticsData/src/V1alpha/gapic_metadata.json | 20 + .../alpha_analytics_data_client_config.json | 20 + ...alpha_analytics_data_descriptor_config.php | 64 + ...lpha_analytics_data_rest_client_config.php | 46 + .../V1alpha/AlphaAnalyticsDataClientTest.php | 314 ++++ .../Client/AlphaAnalyticsDataClientTest.php | 336 ++++ .../Data/V1Alpha/AnalyticsDataApi.php | Bin 11945 -> 0 bytes .../Google/Analytics/Data/V1Alpha/Data.php | Bin 15349 -> 0 bytes .../Data/V1alpha/AudienceDimension.php | 76 - .../Data/V1alpha/AudienceDimensionValue.php | 75 - .../Analytics/Data/V1alpha/AudienceList.php | 621 ------- .../Data/V1alpha/AudienceList/State.php | 75 - .../Data/V1alpha/AudienceListMetadata.php | 33 - .../Analytics/Data/V1alpha/AudienceRow.php | 71 - .../Analytics/Data/V1alpha/BetweenFilter.php | 121 -- .../Google/Analytics/Data/V1alpha/Cohort.php | 215 --- .../Data/V1alpha/CohortReportSettings.php | 71 - .../Analytics/Data/V1alpha/CohortSpec.php | 179 -- .../Analytics/Data/V1alpha/CohortsRange.php | 208 --- .../Data/V1alpha/CohortsRange/Granularity.php | 76 - .../V1alpha/CreateAudienceListRequest.php | 132 -- .../CreateRecurringAudienceListRequest.php | 132 -- .../Analytics/Data/V1alpha/DateRange.php | 172 -- .../Analytics/Data/V1alpha/Dimension.php | 189 --- .../Data/V1alpha/DimensionExpression.php | 147 -- .../DimensionExpression/CaseExpression.php | 74 - .../ConcatenateExpression.php | 128 -- .../Data/V1alpha/DimensionHeader.php | 70 - .../Analytics/Data/V1alpha/DimensionValue.php | 75 - .../Data/V1alpha/EventCriteriaScoping.php | 56 - .../Data/V1alpha/EventExclusionDuration.php | 56 - .../Analytics/Data/V1alpha/EventSegment.php | 123 -- .../V1alpha/EventSegmentConditionGroup.php | 128 -- .../Data/V1alpha/EventSegmentCriteria.php | 72 - .../Data/V1alpha/EventSegmentExclusion.php | 123 -- .../Google/Analytics/Data/V1alpha/Filter.php | 212 --- .../Data/V1alpha/FilterExpression.php | 178 -- .../Data/V1alpha/FilterExpressionList.php | 67 - .../Google/Analytics/Data/V1alpha/Funnel.php | 115 -- .../Data/V1alpha/FunnelBreakdown.php | 137 -- .../Data/V1alpha/FunnelEventFilter.php | 140 -- .../Data/V1alpha/FunnelFieldFilter.php | 208 --- .../Data/V1alpha/FunnelFilterExpression.php | 216 --- .../V1alpha/FunnelFilterExpressionList.php | 67 - .../Data/V1alpha/FunnelNextAction.php | 154 -- .../Data/V1alpha/FunnelParameterFilter.php | 291 ---- .../FunnelParameterFilterExpression.php | 180 -- .../FunnelParameterFilterExpressionList.php | 67 - .../Data/V1alpha/FunnelResponseMetadata.php | 92 - .../Analytics/Data/V1alpha/FunnelStep.php | 243 --- .../Data/V1alpha/FunnelSubReport.php | 196 --- .../Data/V1alpha/GetAudienceListRequest.php | 86 - .../GetRecurringAudienceListRequest.php | 92 - .../Analytics/Data/V1alpha/InListFilter.php | 105 -- .../Data/V1alpha/ListAudienceListsRequest.php | 178 -- .../V1alpha/ListAudienceListsResponse.php | 115 -- .../ListRecurringAudienceListsRequest.php | 186 --- .../ListRecurringAudienceListsResponse.php | 115 -- .../Google/Analytics/Data/V1alpha/Metric.php | 221 --- .../Data/V1alpha/MetricAggregation.php | 75 - .../Analytics/Data/V1alpha/MetricHeader.php | 104 -- .../Analytics/Data/V1alpha/MetricType.php | 131 -- .../Analytics/Data/V1alpha/MetricValue.php | 75 - .../Analytics/Data/V1alpha/NumericFilter.php | 111 -- .../Data/V1alpha/NumericFilter/Operation.php | 85 - .../Analytics/Data/V1alpha/NumericValue.php | 108 -- .../Google/Analytics/Data/V1alpha/OrderBy.php | 144 -- .../Data/V1alpha/OrderBy/DimensionOrderBy.php | 104 -- .../OrderBy/DimensionOrderBy/OrderType.php | 76 - .../Data/V1alpha/OrderBy/MetricOrderBy.php | 70 - .../Analytics/Data/V1alpha/PropertyQuota.php | 363 ---- .../Data/V1alpha/QueryAudienceListRequest.php | 205 --- .../V1alpha/QueryAudienceListResponse.php | 191 --- .../Analytics/Data/V1alpha/QuotaStatus.php | 101 -- .../Data/V1alpha/RecurringAudienceList.php | 410 ----- .../Data/V1alpha/ResponseMetaData.php | 407 ----- .../src/Google/Analytics/Data/V1alpha/Row.php | 138 -- .../Data/V1alpha/RunFunnelReportRequest.php | 557 ------- .../FunnelVisualizationType.php | 67 - .../Data/V1alpha/RunFunnelReportResponse.php | 248 --- .../Data/V1alpha/SamplingMetadata.php | 134 -- .../Google/Analytics/Data/V1alpha/Segment.php | 198 --- .../Data/V1alpha/SegmentEventFilter.php | 140 -- .../Analytics/Data/V1alpha/SegmentFilter.php | 252 --- .../Data/V1alpha/SegmentFilterExpression.php | 216 --- .../V1alpha/SegmentFilterExpressionList.php | 67 - .../Data/V1alpha/SegmentFilterScoping.php | 118 -- .../Data/V1alpha/SegmentParameterFilter.php | 335 ---- .../SegmentParameterFilterExpression.php | 180 -- .../SegmentParameterFilterExpressionList.php | 67 - .../V1alpha/SegmentParameterFilterScoping.php | 158 -- .../Data/V1alpha/SessionCriteriaScoping.php | 64 - .../Data/V1alpha/SessionExclusionDuration.php | 64 - .../Analytics/Data/V1alpha/SessionSegment.php | 123 -- .../V1alpha/SessionSegmentConditionGroup.php | 164 -- .../Data/V1alpha/SessionSegmentCriteria.php | 72 - .../Data/V1alpha/SessionSegmentExclusion.php | 127 -- .../SheetExportAudienceListRequest.php | 206 --- .../SheetExportAudienceListResponse.php | 253 --- .../Analytics/Data/V1alpha/StringFilter.php | 135 -- .../Data/V1alpha/StringFilter/MatchType.php | 92 - .../Data/V1alpha/UserCriteriaScoping.php | 72 - .../Data/V1alpha/UserExclusionDuration.php | 64 - .../Analytics/Data/V1alpha/UserSegment.php | 123 -- .../V1alpha/UserSegmentConditionGroup.php | 164 -- .../Data/V1alpha/UserSegmentCriteria.php | 118 -- .../Data/V1alpha/UserSegmentExclusion.php | 127 -- .../Data/V1alpha/UserSegmentSequenceGroup.php | 202 --- .../Data/V1alpha/UserSequenceStep.php | 198 --- .../Data/V1alpha/WebhookNotification.php | 258 --- .../create_audience_list.php | 119 -- .../create_recurring_audience_list.php | 103 -- .../get_audience_list.php | 83 - .../get_recurring_audience_list.php | 86 - .../list_audience_lists.php | 90 - .../list_recurring_audience_lists.php | 88 - .../query_audience_list.php | 88 - .../run_funnel_report.php | 72 - .../sheet_export_audience_list.php | 90 - .../src/V1alpha/AlphaAnalyticsDataClient.php | 36 - .../Client/AlphaAnalyticsDataClient.php | 867 ---------- .../Gapic/AlphaAnalyticsDataGapicClient.php | 1477 ----------------- .../v1alpha/src/V1alpha/gapic_metadata.json | 83 - .../alpha_analytics_data_client_config.json | 109 -- ...alpha_analytics_data_descriptor_config.php | 228 --- ...lpha_analytics_data_rest_client_config.php | 179 -- .../V1alpha/AlphaAnalyticsDataClientTest.php | 1062 ------------ .../Client/AlphaAnalyticsDataClientTest.php | 1219 -------------- .../Data/V1Beta/AnalyticsDataApi.php | Bin 10331 -> 0 bytes .../Google/Analytics/Data/V1Beta/Data.php | Bin 8211 -> 0 bytes .../Data/V1beta/AudienceDimension.php | 76 - .../Data/V1beta/AudienceDimensionValue.php | 75 - .../Analytics/Data/V1beta/AudienceExport.php | 473 ------ .../Data/V1beta/AudienceExport/State.php | 75 - .../Data/V1beta/AudienceExportMetadata.php | 33 - .../Analytics/Data/V1beta/AudienceRow.php | 71 - .../V1beta/BatchRunPivotReportsRequest.php | 133 -- .../V1beta/BatchRunPivotReportsResponse.php | 109 -- .../Data/V1beta/BatchRunReportsRequest.php | 133 -- .../Data/V1beta/BatchRunReportsResponse.php | 109 -- .../Data/V1beta/CheckCompatibilityRequest.php | 300 ---- .../V1beta/CheckCompatibilityResponse.php | 101 -- .../Google/Analytics/Data/V1beta/Cohort.php | 215 --- .../Data/V1beta/CohortReportSettings.php | 71 - .../Analytics/Data/V1beta/CohortSpec.php | 179 -- .../Analytics/Data/V1beta/CohortsRange.php | 208 --- .../Data/V1beta/CohortsRange/Granularity.php | 76 - .../Analytics/Data/V1beta/Compatibility.php | 63 - .../V1beta/CreateAudienceExportRequest.php | 132 -- .../Analytics/Data/V1beta/DateRange.php | 172 -- .../Analytics/Data/V1beta/Dimension.php | 190 --- .../Data/V1beta/DimensionCompatibility.php | 133 -- .../Data/V1beta/DimensionExpression.php | 147 -- .../DimensionExpression/CaseExpression.php | 74 - .../ConcatenateExpression.php | 128 -- .../Analytics/Data/V1beta/DimensionHeader.php | 70 - .../Data/V1beta/DimensionMetadata.php | 261 --- .../Analytics/Data/V1beta/DimensionValue.php | 75 - .../Google/Analytics/Data/V1beta/Filter.php | 224 --- .../Data/V1beta/Filter/BetweenFilter.php | 124 -- .../Data/V1beta/Filter/InListFilter.php | 108 -- .../Data/V1beta/Filter/NumericFilter.php | 114 -- .../V1beta/Filter/NumericFilter/Operation.php | 85 - .../Data/V1beta/Filter/StringFilter.php | 138 -- .../V1beta/Filter/StringFilter/MatchType.php | 92 - .../Data/V1beta/FilterExpression.php | 178 -- .../Data/V1beta/FilterExpressionList.php | 67 - .../Data/V1beta/GetAudienceExportRequest.php | 87 - .../Data/V1beta/GetMetadataRequest.php | 123 -- .../V1beta/ListAudienceExportsRequest.php | 178 -- .../V1beta/ListAudienceExportsResponse.php | 115 -- .../Google/Analytics/Data/V1beta/Metadata.php | 136 -- .../Google/Analytics/Data/V1beta/Metric.php | 221 --- .../Data/V1beta/MetricAggregation.php | 75 - .../Data/V1beta/MetricCompatibility.php | 133 -- .../Analytics/Data/V1beta/MetricHeader.php | 104 -- .../Analytics/Data/V1beta/MetricMetadata.php | 395 ----- .../V1beta/MetricMetadata/BlockedReason.php | 66 - .../Analytics/Data/V1beta/MetricType.php | 131 -- .../Analytics/Data/V1beta/MetricValue.php | 75 - .../Analytics/Data/V1beta/MinuteRange.php | 220 --- .../Analytics/Data/V1beta/NumericValue.php | 108 -- .../Google/Analytics/Data/V1beta/OrderBy.php | 177 -- .../Data/V1beta/OrderBy/DimensionOrderBy.php | 104 -- .../OrderBy/DimensionOrderBy/OrderType.php | 76 - .../Data/V1beta/OrderBy/MetricOrderBy.php | 70 - .../Data/V1beta/OrderBy/PivotOrderBy.php | 120 -- .../OrderBy/PivotOrderBy/PivotSelection.php | 117 -- .../Google/Analytics/Data/V1beta/Pivot.php | 255 --- .../Data/V1beta/PivotDimensionHeader.php | 67 - .../Analytics/Data/V1beta/PivotHeader.php | 113 -- .../Analytics/Data/V1beta/PropertyQuota.php | 363 ---- .../V1beta/QueryAudienceExportRequest.php | 205 --- .../V1beta/QueryAudienceExportResponse.php | 191 --- .../Analytics/Data/V1beta/QuotaStatus.php | 121 -- .../Data/V1beta/ResponseMetaData.php | 457 ----- .../SchemaRestrictionResponse.php | 84 - .../ActiveMetricRestriction.php | 114 -- .../Data/V1beta/RestrictedMetricType.php | 62 - .../src/Google/Analytics/Data/V1beta/Row.php | 138 -- .../Data/V1beta/RunPivotReportRequest.php | 553 ------ .../Data/V1beta/RunPivotReportResponse.php | 481 ------ .../Data/V1beta/RunRealtimeReportRequest.php | 465 ------ .../Data/V1beta/RunRealtimeReportResponse.php | 381 ----- .../Data/V1beta/RunReportRequest.php | 699 -------- .../Data/V1beta/RunReportResponse.php | 433 ----- .../Data/V1beta/SamplingMetadata.php | 133 -- .../batch_run_pivot_reports.php | 58 - .../batch_run_reports.php | 58 - .../check_compatibility.php | 66 - .../create_audience_export.php | 122 -- .../get_audience_export.php | 83 - .../BetaAnalyticsDataClient/get_metadata.php | 90 - .../list_audience_exports.php | 91 - .../query_audience_export.php | 89 - .../run_pivot_report.php | 61 - .../run_realtime_report.php | 65 - .../BetaAnalyticsDataClient/run_report.php | 67 - .../src/V1beta/BetaAnalyticsDataClient.php | 36 - .../V1beta/Client/BetaAnalyticsDataClient.php | 749 --------- .../Gapic/BetaAnalyticsDataGapicClient.php | 1431 ---------------- .../v1beta/src/V1beta/gapic_metadata.json | 73 - .../beta_analytics_data_client_config.json | 99 -- .../beta_analytics_data_descriptor_config.php | 180 -- ...beta_analytics_data_rest_client_config.php | 158 -- .../V1beta/BetaAnalyticsDataClientTest.php | 803 --------- .../Client/BetaAnalyticsDataClientTest.php | 872 ---------- 255 files changed, 1766 insertions(+), 40030 deletions(-) rename {owl-bot-staging/AnalyticsData/v1alpha => AnalyticsData}/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php (100%) rename {owl-bot-staging/AnalyticsData/v1alpha => AnalyticsData}/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php (100%) rename {owl-bot-staging/AnalyticsData/v1alpha => AnalyticsData}/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php (100%) rename {owl-bot-staging/AnalyticsData/v1alpha => AnalyticsData}/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php (100%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/CreateReportTaskRequest.php (98%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/GetReportTaskRequest.php (99%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ListReportTasksRequest.php (98%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ListReportTasksResponse.php (98%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/QueryReportTaskRequest.php (99%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/QueryReportTaskResponse.php (99%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ReportTask.php (98%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ReportTask/ReportDefinition.php (98%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ReportTask/ReportMetadata.php (97%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ReportTask/ReportMetadata/State.php (91%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ReportTaskMetadata.php (100%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php (94%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php (92%) rename {owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data => AnalyticsData/src}/V1alpha/RestrictedMetricType.php (100%) delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Client/AlphaAnalyticsDataClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimension.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Client/BetaAnalyticsDataClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php delete mode 100644 owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php diff --git a/AnalyticsData/metadata/V1Alpha/AnalyticsDataApi.php b/AnalyticsData/metadata/V1Alpha/AnalyticsDataApi.php index d3e47e5ae49bacfc3542b7537134361b209ce38f..fce3ba97b7179fb6a742b0c8508cc93e69987adf 100644 GIT binary patch delta 1950 zcmaJ?O>7%g5Y~Ea#~%MB&vv{`9BMC^B&Lchw?wHUnyeEH0@y#c4@W-pLdiUb$;m`7?>6H2~2GGF$o@rk(tQ+KRD3^a7W=w9;TX?tKZQJc$ zR|yoPrC7B_zD=K8_u^N?&+SoMU4EcR=v7EL89LZDT83>XGJn6u-fvF4f6<9zujRR~ zLohv_7ij>kb_aJYS`7I-ymXdkjjh#<7z z?zC+s;@KLIc5)bddnVp9*zhbRN^44z+wo#aRHS)Mk?TA}du9up`kO;b0kWAbZM@9B z>qFt6gG6&+nz-8>>djsYD=~^06}~NqHG9`7gSyqnO(o7Jz0CT*yv6OWP_qclL+S>` zeI0lD_E0x_2bPkc;Suhg`&EXd7(A_#(}rGykY&@UDH07!R?oAnC;pQ^@^^em3Xpu_ z(i4pD5KAkg0wis!Ee1zxA9QUx`#Xt3B}7Ab3-XTqfh3_Kr0kw;?E3=4qbxf?axHm* zETx`|%s@(K3CT;Tg?R+i`q-=5+ka>lTw5eFun_lZMHTW_A^TRv9I4%^yemFxNlHmY(AoBz4AZ{{G%-+fnW3E%h z;ykT+QEX%ZH3P^qxn!tUVD|C=n?uh)R8kf# zlx@fg<+7lf?wS%9ug8#mw$H?kP zLqfo(eD%Ed%WoubPA!v_g<{$Lcd%-H0iz!zNR8=^Nb^Ny%;t=4j+ePK;S}Rg>qiH`W7_aly=E(=Sm#XpQuB8|5uGN83ltZwe`}g|yd!E0Cf4%%hj>W$8 z&q}ecV^7|PREGuL*d|#>IM#&8(zdjlCIoa{l)(MmXKVYOCB8`6XEggNI!GSzo^ zfgKezqUc2p;v6vFmJ=L6=|1F^nvz!`69S+YuPOZ@LE&nvxt@?WNFTuE&}lH6GV#uQ zRpAg$Z-P(}0Ta{9V@RJHqy!sXqoEqqJlI!hU+?X!b?vF9HVP}G09mEI-%|8`M>Vv1 zK_d5Hv##`1s_8vd?`fv?Or=XHTQQP>)u)xmINeerRTm37mfIE$G1mpvSlGbK3~`X z7n6UBPGTD}RZS@OYWqr$S6b+f>Y|L+%IA`V%FWp)p2r+}Ms0V%YIVJot?!OILHkk%9L}2-NAy!2w&O^`dL(xAue9r8E1}+Uo2y)~e4^U0=8m6ta z5|~!{J_fgM1V%oSpk(12Uog5@XY3Ne7y91KRIUH{+=?PPh6m%)?1AYOg?!US_0L0+|XL$bWe_`vvxQ9t`1D2uK+YJvOwsqDUFGI;x3BiYm>fp*H7# z?yc|P7MNXAY2y~)QR-;A*6DW&Nnt1-2_r=?sow4DW+8F*Ml~VrJfg53{bV+{csh9q rWkc=p8K&Bx^C#8Pb`H|@ZqK9*#Z+(z-b+J$rs{n)^u*?SkAL_VHem?G delta 38 wcmV+>0NMZbcll?q7y<&AW3w6pqyn@31VIIp6Aa$74-!u&v&T6D0h22`$}JHNR{#J2 diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php b/AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php rename to AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php b/AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php rename to AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php b/AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php rename to AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php b/AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php rename to AnalyticsData/samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php diff --git a/AnalyticsData/src/V1alpha/Client/AlphaAnalyticsDataClient.php b/AnalyticsData/src/V1alpha/Client/AlphaAnalyticsDataClient.php index 0d6549f6af1..6ef322b24f5 100644 --- a/AnalyticsData/src/V1alpha/Client/AlphaAnalyticsDataClient.php +++ b/AnalyticsData/src/V1alpha/Client/AlphaAnalyticsDataClient.php @@ -29,13 +29,19 @@ use Google\Analytics\Data\V1alpha\AudienceList; use Google\Analytics\Data\V1alpha\CreateAudienceListRequest; use Google\Analytics\Data\V1alpha\CreateRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\CreateReportTaskRequest; use Google\Analytics\Data\V1alpha\GetAudienceListRequest; use Google\Analytics\Data\V1alpha\GetRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\GetReportTaskRequest; use Google\Analytics\Data\V1alpha\ListAudienceListsRequest; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsRequest; +use Google\Analytics\Data\V1alpha\ListReportTasksRequest; use Google\Analytics\Data\V1alpha\QueryAudienceListRequest; use Google\Analytics\Data\V1alpha\QueryAudienceListResponse; +use Google\Analytics\Data\V1alpha\QueryReportTaskRequest; +use Google\Analytics\Data\V1alpha\QueryReportTaskResponse; use Google\Analytics\Data\V1alpha\RecurringAudienceList; +use Google\Analytics\Data\V1alpha\ReportTask; use Google\Analytics\Data\V1alpha\RunFunnelReportRequest; use Google\Analytics\Data\V1alpha\RunFunnelReportResponse; use Google\Analytics\Data\V1alpha\Segment; @@ -70,11 +76,15 @@ * * @method PromiseInterface createAudienceListAsync(CreateAudienceListRequest $request, array $optionalArgs = []) * @method PromiseInterface createRecurringAudienceListAsync(CreateRecurringAudienceListRequest $request, array $optionalArgs = []) + * @method PromiseInterface createReportTaskAsync(CreateReportTaskRequest $request, array $optionalArgs = []) * @method PromiseInterface getAudienceListAsync(GetAudienceListRequest $request, array $optionalArgs = []) * @method PromiseInterface getRecurringAudienceListAsync(GetRecurringAudienceListRequest $request, array $optionalArgs = []) + * @method PromiseInterface getReportTaskAsync(GetReportTaskRequest $request, array $optionalArgs = []) * @method PromiseInterface listAudienceListsAsync(ListAudienceListsRequest $request, array $optionalArgs = []) * @method PromiseInterface listRecurringAudienceListsAsync(ListRecurringAudienceListsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listReportTasksAsync(ListReportTasksRequest $request, array $optionalArgs = []) * @method PromiseInterface queryAudienceListAsync(QueryAudienceListRequest $request, array $optionalArgs = []) + * @method PromiseInterface queryReportTaskAsync(QueryReportTaskRequest $request, array $optionalArgs = []) * @method PromiseInterface runFunnelReportAsync(RunFunnelReportRequest $request, array $optionalArgs = []) * @method PromiseInterface sheetExportAudienceListAsync(SheetExportAudienceListRequest $request, array $optionalArgs = []) */ @@ -220,6 +230,25 @@ public static function recurringAudienceListName(string $property, string $recur ]); } + /** + * Formats a string containing the fully-qualified path to represent a report_task + * resource. + * + * @param string $property + * @param string $reportTask + * + * @return string The formatted report_task resource. + * + * @experimental + */ + public static function reportTaskName(string $property, string $reportTask): string + { + return self::getPathTemplate('reportTask')->render([ + 'property' => $property, + 'report_task' => $reportTask, + ]); + } + /** * Parses a formatted name string and returns an associative array of the components in the name. * The following name formats are supported: @@ -227,6 +256,7 @@ public static function recurringAudienceListName(string $property, string $recur * - audienceList: properties/{property}/audienceLists/{audience_list} * - property: properties/{property} * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} + * - reportTask: properties/{property}/reportTasks/{report_task} * * The optional $template argument can be supplied to specify a particular pattern, * and must match one of the templates listed above. If no $template argument is @@ -420,6 +450,37 @@ public function createRecurringAudienceList(CreateRecurringAudienceListRequest $ return $this->startApiCall('CreateRecurringAudienceList', $request, $callOptions)->wait(); } + /** + * Initiates the creation of a report task. This method quickly + * returns a report task and initiates a long running + * asynchronous request to form a customized report of your Google Analytics + * event data. + * + * The async variant is {@see AlphaAnalyticsDataClient::createReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php + * + * @param CreateReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function createReportTask(CreateReportTaskRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateReportTask', $request, $callOptions)->wait(); + } + /** * Gets configuration metadata about a specific audience list. This method * can be used to understand an audience list after it has been created. @@ -498,6 +559,36 @@ public function getRecurringAudienceList(GetRecurringAudienceListRequest $reques return $this->startApiCall('GetRecurringAudienceList', $request, $callOptions)->wait(); } + /** + * Gets report metadata about a specific report task. After creating a report + * task, use this method to check its processing state or inspect its + * report definition. + * + * The async variant is {@see AlphaAnalyticsDataClient::getReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php + * + * @param GetReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ReportTask + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function getReportTask(GetReportTaskRequest $request, array $callOptions = []): ReportTask + { + return $this->startApiCall('GetReportTask', $request, $callOptions)->wait(); + } + /** * Lists all audience lists for a property. This method can be used for you to * find and reuse existing audience lists rather than creating unnecessary new @@ -579,6 +670,34 @@ public function listRecurringAudienceLists(ListRecurringAudienceListsRequest $re return $this->startApiCall('ListRecurringAudienceLists', $request, $callOptions); } + /** + * Lists all report tasks for a property. + * + * The async variant is {@see AlphaAnalyticsDataClient::listReportTasksAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php + * + * @param ListReportTasksRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function listReportTasks(ListReportTasksRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListReportTasks', $request, $callOptions); + } + /** * Retrieves an audience list of users. After creating an audience, the users * are not immediately available for listing. First, a request to @@ -624,6 +743,38 @@ public function queryAudienceList(QueryAudienceListRequest $request, array $call return $this->startApiCall('QueryAudienceList', $request, $callOptions)->wait(); } + /** + * Retrieves a report task's content. After requesting the `CreateReportTask`, + * you are able to retrieve the report content once the report is + * ACTIVE. This method will return an error if the report task's state is not + * `ACTIVE`. A query response will return the tabular row & column values of + * the report. + * + * The async variant is {@see AlphaAnalyticsDataClient::queryReportTaskAsync()} . + * + * @example samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php + * + * @param QueryReportTaskRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return QueryReportTaskResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @experimental + */ + public function queryReportTask(QueryReportTaskRequest $request, array $callOptions = []): QueryReportTaskResponse + { + return $this->startApiCall('QueryReportTask', $request, $callOptions)->wait(); + } + /** * 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 diff --git a/AnalyticsData/src/V1alpha/Cohort.php b/AnalyticsData/src/V1alpha/Cohort.php index 1faef89f061..8594825d2ac 100644 --- a/AnalyticsData/src/V1alpha/Cohort.php +++ b/AnalyticsData/src/V1alpha/Cohort.php @@ -10,7 +10,7 @@ /** * Defines a cohort selection criteria. A cohort is a group of users who share - * a common characteristic. For example, users with the same `firstTouchDate` + * a common characteristic. For example, users with the same `firstSessionDate` * belong to the same cohort. * * Generated from protobuf message google.analytics.data.v1alpha.Cohort @@ -27,7 +27,8 @@ class Cohort extends \Google\Protobuf\Internal\Message */ private $name = ''; /** - * Dimension used by the cohort. Required and only supports `firstTouchDate`. + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. * * Generated from protobuf field string dimension = 2; */ @@ -64,7 +65,8 @@ class Cohort extends \Google\Protobuf\Internal\Message * `RESERVED_`. If not set, cohorts are named by their zero based index * `cohort_0`, `cohort_1`, etc. * @type string $dimension - * Dimension used by the cohort. Required and only supports `firstTouchDate`. + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. * @type \Google\Analytics\Data\V1alpha\DateRange $date_range * The cohort selects users whose first touch date is between start date and * end date defined in the `dateRange`. This `dateRange` does not specify the @@ -120,7 +122,8 @@ public function setName($var) } /** - * Dimension used by the cohort. Required and only supports `firstTouchDate`. + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. * * Generated from protobuf field string dimension = 2; * @return string @@ -131,7 +134,8 @@ public function getDimension() } /** - * Dimension used by the cohort. Required and only supports `firstTouchDate`. + * Dimension used by the cohort. Required and only supports + * `firstSessionDate`. * * Generated from protobuf field string dimension = 2; * @param string $var @@ -166,7 +170,7 @@ public function setDimension($var) */ public function getDateRange() { - return isset($this->date_range) ? $this->date_range : null; + return $this->date_range; } public function hasDateRange() diff --git a/AnalyticsData/src/V1alpha/CohortSpec.php b/AnalyticsData/src/V1alpha/CohortSpec.php index 70e225a5700..822fec521a6 100644 --- a/AnalyticsData/src/V1alpha/CohortSpec.php +++ b/AnalyticsData/src/V1alpha/CohortSpec.php @@ -9,13 +9,15 @@ use Google\Protobuf\Internal\GPBUtil; /** - * Specification of cohorts for a cohort report. - * Cohort reports can be used for example to create a time series of user - * retention for the cohort. For example, you could select the cohort of users - * that were acquired in the first week of September and follow that cohort for - * the next six weeks. Selecting the users acquired in the first week of - * September cohort is specified in the `cohort` object. Following that - * cohort for the next six weeks is specified in the `cohortsRange` object. + * The specification of cohorts for a cohort report. + * Cohort reports create a time series of user retention for the cohort. For + * example, you could select the cohort of users that were acquired in the first + * week of September and follow that cohort for the next six weeks. Selecting + * the users acquired in the first week of September cohort is specified in the + * `cohort` object. Following that cohort for the next six weeks is specified in + * the `cohortsRange` object. + * For examples, see [Cohort Report + * Examples](https://developers.google.com/analytics/devguides/reporting/data/v1/advanced#cohort_report_examples). * The report response could show a weekly time series where say your app has * retained 60% of this cohort after three weeks and 25% of this cohort after * six weeks. These two percentages can be calculated by the metric @@ -53,7 +55,7 @@ class CohortSpec extends \Google\Protobuf\Internal\Message * @param array $data { * Optional. Data for populating the Message object. * - * @type \Google\Analytics\Data\V1alpha\Cohort[]|\Google\Protobuf\Internal\RepeatedField $cohorts + * @type array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $cohorts * Defines the selection criteria to group users into cohorts. * Most cohort reports define only a single cohort. If multiple cohorts are * specified, each cohort can be recognized in the report by their name. @@ -88,7 +90,7 @@ public function getCohorts() * specified, each cohort can be recognized in the report by their name. * * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; - * @param \Google\Analytics\Data\V1alpha\Cohort[]|\Google\Protobuf\Internal\RepeatedField $var + * @param array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $var * @return $this */ public function setCohorts($var) @@ -108,7 +110,7 @@ public function setCohorts($var) */ public function getCohortsRange() { - return isset($this->cohorts_range) ? $this->cohorts_range : null; + return $this->cohorts_range; } public function hasCohortsRange() @@ -145,7 +147,7 @@ public function setCohortsRange($var) */ public function getCohortReportSettings() { - return isset($this->cohort_report_settings) ? $this->cohort_report_settings : null; + return $this->cohort_report_settings; } public function hasCohortReportSettings() diff --git a/AnalyticsData/src/V1alpha/CohortsRange.php b/AnalyticsData/src/V1alpha/CohortsRange.php index 660b47d38ff..796eaf0a311 100644 --- a/AnalyticsData/src/V1alpha/CohortsRange.php +++ b/AnalyticsData/src/V1alpha/CohortsRange.php @@ -17,8 +17,8 @@ class CohortsRange extends \Google\Protobuf\Internal\Message { /** - * The granularity used to interpret the `startOffset` and `endOffset` for the - * extended reporting date range for a cohort report. + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. * * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; */ @@ -38,8 +38,8 @@ class CohortsRange extends \Google\Protobuf\Internal\Message */ private $start_offset = 0; /** - * `endOffset` specifies the end date of the extended reporting date range - * for a cohort report. `endOffset` can be any positive integer but is + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is * commonly set to 5 to 10 so that reports contain data on the cohort for the * next several granularity time periods. * If `granularity` is `DAILY`, the `endDate` of the extended reporting date @@ -60,8 +60,8 @@ class CohortsRange extends \Google\Protobuf\Internal\Message * Optional. Data for populating the Message object. * * @type int $granularity - * The granularity used to interpret the `startOffset` and `endOffset` for the - * extended reporting date range for a cohort report. + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. * @type int $start_offset * `startOffset` specifies the start date of the extended reporting date range * for a cohort report. `startOffset` is commonly set to 0 so that reports @@ -73,8 +73,8 @@ class CohortsRange extends \Google\Protobuf\Internal\Message * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting * date range is `startDate` of the cohort plus `startOffset * 30` days. * @type int $end_offset - * `endOffset` specifies the end date of the extended reporting date range - * for a cohort report. `endOffset` can be any positive integer but is + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is * commonly set to 5 to 10 so that reports contain data on the cohort for the * next several granularity time periods. * If `granularity` is `DAILY`, the `endDate` of the extended reporting date @@ -91,8 +91,8 @@ public function __construct($data = NULL) { } /** - * The granularity used to interpret the `startOffset` and `endOffset` for the - * extended reporting date range for a cohort report. + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. * * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; * @return int @@ -103,8 +103,8 @@ public function getGranularity() } /** - * The granularity used to interpret the `startOffset` and `endOffset` for the - * extended reporting date range for a cohort report. + * Required. The granularity used to interpret the `startOffset` and + * `endOffset` for the extended reporting date range for a cohort report. * * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; * @param int $var @@ -161,8 +161,8 @@ public function setStartOffset($var) } /** - * `endOffset` specifies the end date of the extended reporting date range - * for a cohort report. `endOffset` can be any positive integer but is + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is * commonly set to 5 to 10 so that reports contain data on the cohort for the * next several granularity time periods. * If `granularity` is `DAILY`, the `endDate` of the extended reporting date @@ -181,8 +181,8 @@ public function getEndOffset() } /** - * `endOffset` specifies the end date of the extended reporting date range - * for a cohort report. `endOffset` can be any positive integer but is + * Required. `endOffset` specifies the end date of the extended reporting date + * range for a cohort report. `endOffset` can be any positive integer but is * commonly set to 5 to 10 so that reports contain data on the cohort for the * next several granularity time periods. * If `granularity` is `DAILY`, the `endDate` of the extended reporting date diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php b/AnalyticsData/src/V1alpha/CreateReportTaskRequest.php similarity index 98% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php rename to AnalyticsData/src/V1alpha/CreateReportTaskRequest.php index 7c87d8ddfb7..86b48a18bd5 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateReportTaskRequest.php +++ b/AnalyticsData/src/V1alpha/CreateReportTaskRequest.php @@ -21,13 +21,13 @@ class CreateReportTaskRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { */ - protected $parent = ''; + private $parent = ''; /** * Required. The report task configuration to create. * * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask report_task = 2 [(.google.api.field_behavior) = REQUIRED]; */ - protected $report_task = null; + private $report_task = null; /** * @param string $parent Required. The parent resource where this report task will be created. diff --git a/AnalyticsData/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php b/AnalyticsData/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php index 0ea1632b562..749a0cf0226 100644 --- a/AnalyticsData/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php +++ b/AnalyticsData/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php @@ -29,6 +29,7 @@ use Google\Analytics\Data\V1alpha\AudienceList; use Google\Analytics\Data\V1alpha\CreateAudienceListRequest; use Google\Analytics\Data\V1alpha\CreateRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\CreateReportTaskRequest; use Google\Analytics\Data\V1alpha\DateRange; use Google\Analytics\Data\V1alpha\FilterExpression; use Google\Analytics\Data\V1alpha\Funnel; @@ -36,13 +37,19 @@ use Google\Analytics\Data\V1alpha\FunnelNextAction; use Google\Analytics\Data\V1alpha\GetAudienceListRequest; use Google\Analytics\Data\V1alpha\GetRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\GetReportTaskRequest; use Google\Analytics\Data\V1alpha\ListAudienceListsRequest; use Google\Analytics\Data\V1alpha\ListAudienceListsResponse; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsRequest; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsResponse; +use Google\Analytics\Data\V1alpha\ListReportTasksRequest; +use Google\Analytics\Data\V1alpha\ListReportTasksResponse; use Google\Analytics\Data\V1alpha\QueryAudienceListRequest; use Google\Analytics\Data\V1alpha\QueryAudienceListResponse; +use Google\Analytics\Data\V1alpha\QueryReportTaskRequest; +use Google\Analytics\Data\V1alpha\QueryReportTaskResponse; use Google\Analytics\Data\V1alpha\RecurringAudienceList; +use Google\Analytics\Data\V1alpha\ReportTask; use Google\Analytics\Data\V1alpha\RunFunnelReportRequest; use Google\Analytics\Data\V1alpha\RunFunnelReportResponse; use Google\Analytics\Data\V1alpha\Segment; @@ -150,6 +157,8 @@ class AlphaAnalyticsDataGapicClient private static $recurringAudienceListNameTemplate; + private static $reportTaskNameTemplate; + private static $pathTemplateMap; private $operationsClient; @@ -214,6 +223,17 @@ private static function getRecurringAudienceListNameTemplate() return self::$recurringAudienceListNameTemplate; } + private static function getReportTaskNameTemplate() + { + if (self::$reportTaskNameTemplate == null) { + self::$reportTaskNameTemplate = new PathTemplate( + 'properties/{property}/reportTasks/{report_task}' + ); + } + + return self::$reportTaskNameTemplate; + } + private static function getPathTemplateMap() { if (self::$pathTemplateMap == null) { @@ -221,6 +241,7 @@ private static function getPathTemplateMap() 'audienceList' => self::getAudienceListNameTemplate(), 'property' => self::getPropertyNameTemplate(), 'recurringAudienceList' => self::getRecurringAudienceListNameTemplate(), + 'reportTask' => self::getReportTaskNameTemplate(), ]; } @@ -284,6 +305,25 @@ public static function recurringAudienceListName( ]); } + /** + * Formats a string containing the fully-qualified path to represent a report_task + * resource. + * + * @param string $property + * @param string $reportTask + * + * @return string The formatted report_task resource. + * + * @experimental + */ + public static function reportTaskName($property, $reportTask) + { + return self::getReportTaskNameTemplate()->render([ + 'property' => $property, + 'report_task' => $reportTask, + ]); + } + /** * Parses a formatted name string and returns an associative array of the components in the name. * The following name formats are supported: @@ -291,6 +331,7 @@ public static function recurringAudienceListName( * - audienceList: properties/{property}/audienceLists/{audience_list} * - property: properties/{property} * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} + * - reportTask: properties/{property}/reportTasks/{report_task} * * The optional $template argument can be supplied to specify a particular pattern, * and must match one of the templates listed above. If no $template argument is @@ -614,6 +655,91 @@ public function createRecurringAudienceList( )->wait(); } + /** + * Initiates the creation of a report task. This method quickly + * returns a report task and initiates a long running + * asynchronous request to form a customized report of your Google Analytics + * event data. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * $reportTask = new ReportTask(); + * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createReportTask'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent resource where this report task will be created. + * Format: `properties/{propertyId}` + * @param ReportTask $reportTask Required. The report task configuration to create. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createReportTask( + $parent, + $reportTask, + array $optionalArgs = [] + ) { + $request = new CreateReportTaskRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setReportTask($reportTask); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor( + $requestParamHeaders + ); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startOperationsCall( + 'CreateReportTask', + $optionalArgs, + $request, + $this->getOperationsClient() + )->wait(); + } + /** * Gets configuration metadata about a specific audience list. This method * can be used to understand an audience list after it has been created. @@ -738,6 +864,59 @@ public function getRecurringAudienceList($name, array $optionalArgs = []) )->wait(); } + /** + * Gets report metadata about a specific report task. After creating a report + * task, use this method to check its processing state or inspect its + * report definition. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedName = $alphaAnalyticsDataClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + * $response = $alphaAnalyticsDataClient->getReportTask($formattedName); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The report task resource name. + * Format: `properties/{property}/reportTasks/{report_task}` + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\ReportTask + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getReportTask($name, array $optionalArgs = []) + { + $request = new GetReportTaskRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor( + $requestParamHeaders + ); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startCall( + 'GetReportTask', + ReportTask::class, + $optionalArgs, + $request + )->wait(); + } + /** * Lists all audience lists for a property. This method can be used for you to * find and reuse existing audience lists rather than creating unnecessary new @@ -924,6 +1103,86 @@ public function listRecurringAudienceLists( ); } + /** + * Lists all report tasks for a property. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); + * // Iterate over pages of elements + * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $parent Required. All report tasks for this property will be listed in the + * response. Format: `properties/{property}` + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listReportTasks($parent, array $optionalArgs = []) + { + $request = new ListReportTasksRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor( + $requestParamHeaders + ); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->getPagedListResponse( + 'ListReportTasks', + $optionalArgs, + ListReportTasksResponse::class, + $request + ); + } + /** * Retrieves an audience list of users. After creating an audience, the users * are not immediately available for listing. First, a request to @@ -1021,6 +1280,95 @@ public function queryAudienceList($name, array $optionalArgs = []) )->wait(); } + /** + * Retrieves a report task's content. After requesting the `CreateReportTask`, + * you are able to retrieve the report content once the report is + * ACTIVE. This method will return an error if the report task's state is not + * `ACTIVE`. A query response will return the tabular row & column values of + * the report. + * + * Sample code: + * ``` + * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); + * try { + * $name = 'name'; + * $response = $alphaAnalyticsDataClient->queryReportTask($name); + * } finally { + * $alphaAnalyticsDataClient->close(); + * } + * ``` + * + * @param string $name Required. The report source name. + * Format: `properties/{property}/reportTasks/{report}` + * @param array $optionalArgs { + * Optional. + * + * @type int $offset + * Optional. The row count of the start row in the report. The first row is + * counted as row 0. + * + * When paging, the first request does not specify offset; or equivalently, + * sets offset to 0; the first request returns the first `limit` of rows. The + * second request sets offset to the `limit` of the first request; the second + * request returns the second `limit` of rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type int $limit + * Optional. The number of rows to return from the report. If unspecified, + * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows + * available to a QueryReportTaskRequest is further limited by the limit of + * the associated ReportTask. A query can retrieve at most ReportTask.limit + * rows. For example, if the ReportTask has a limit of 1,000, then a + * QueryReportTask request with offset=900 and limit=500 will return at most + * 100 rows. + * + * To learn more about this pagination parameter, see + * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Analytics\Data\V1alpha\QueryReportTaskResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function queryReportTask($name, array $optionalArgs = []) + { + $request = new QueryReportTaskRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + if (isset($optionalArgs['offset'])) { + $request->setOffset($optionalArgs['offset']); + } + + if (isset($optionalArgs['limit'])) { + $request->setLimit($optionalArgs['limit']); + } + + $requestParams = new RequestParamsHeaderDescriptor( + $requestParamHeaders + ); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startCall( + 'QueryReportTask', + QueryReportTaskResponse::class, + $optionalArgs, + $request + )->wait(); + } + /** * 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 diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php b/AnalyticsData/src/V1alpha/GetReportTaskRequest.php similarity index 99% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php rename to AnalyticsData/src/V1alpha/GetReportTaskRequest.php index b0bbbd7685c..e50713f7969 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetReportTaskRequest.php +++ b/AnalyticsData/src/V1alpha/GetReportTaskRequest.php @@ -21,7 +21,7 @@ class GetReportTaskRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { */ - protected $name = ''; + private $name = ''; /** * @param string $name Required. The report task resource name. diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php b/AnalyticsData/src/V1alpha/ListReportTasksRequest.php similarity index 98% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php rename to AnalyticsData/src/V1alpha/ListReportTasksRequest.php index 12429e405d1..5d2935453bf 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksRequest.php +++ b/AnalyticsData/src/V1alpha/ListReportTasksRequest.php @@ -21,20 +21,20 @@ class ListReportTasksRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { */ - protected $parent = ''; + private $parent = ''; /** * Optional. The maximum number of report tasks to return. * * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $page_size = 0; + private $page_size = 0; /** * Optional. A page token, received from a previous `ListReportTasks` call. * Provide this to retrieve the subsequent page. * * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $page_token = ''; + private $page_token = ''; /** * @param string $parent Required. All report tasks for this property will be listed in the diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php b/AnalyticsData/src/V1alpha/ListReportTasksResponse.php similarity index 98% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php rename to AnalyticsData/src/V1alpha/ListReportTasksResponse.php index 48be01c1d7a..a8917c89766 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListReportTasksResponse.php +++ b/AnalyticsData/src/V1alpha/ListReportTasksResponse.php @@ -27,7 +27,7 @@ class ListReportTasksResponse extends \Google\Protobuf\Internal\Message * * Generated from protobuf field optional string next_page_token = 2; */ - protected $next_page_token = null; + private $next_page_token = null; /** * Constructor. diff --git a/AnalyticsData/src/V1alpha/Metric.php b/AnalyticsData/src/V1alpha/Metric.php index 847c5c68e97..1ec6f928792 100644 --- a/AnalyticsData/src/V1alpha/Metric.php +++ b/AnalyticsData/src/V1alpha/Metric.php @@ -20,10 +20,21 @@ class Metric extends \Google\Protobuf\Internal\Message /** * The name of the metric. See the [API * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names. - * If `expression` is specified, `name` can be any string that you would like. - * For example if `expression` is `screenPageViews/sessions`, you could call - * that metric's name = `viewsPerSession`. + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric * `expression`. * @@ -55,10 +66,21 @@ class Metric extends \Google\Protobuf\Internal\Message * @type string $name * The name of the metric. See the [API * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names. - * If `expression` is specified, `name` can be any string that you would like. - * For example if `expression` is `screenPageViews/sessions`, you could call - * that metric's name = `viewsPerSession`. + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric * `expression`. * @type string $expression @@ -78,10 +100,21 @@ public function __construct($data = NULL) { /** * The name of the metric. See the [API * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names. - * If `expression` is specified, `name` can be any string that you would like. - * For example if `expression` is `screenPageViews/sessions`, you could call - * that metric's name = `viewsPerSession`. + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric * `expression`. * @@ -96,10 +129,21 @@ public function getName() /** * The name of the metric. See the [API * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names. - * If `expression` is specified, `name` can be any string that you would like. - * For example if `expression` is `screenPageViews/sessions`, you could call - * that metric's name = `viewsPerSession`. + * for the list of metric names supported by core reporting methods such + * as `runReport` and `batchRunReports`. See + * [Realtime + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) + * for the list of metric names supported by the `runRealtimeReport` + * method. See + * [Funnel + * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) + * for the list of metric names supported by the `runFunnelReport` + * method. + * If `expression` is specified, `name` can be any string that you would like + * within the allowed character set. For example if `expression` is + * `screenPageViews/sessions`, you could call that metric's name = + * `viewsPerSession`. Metric names that you choose must match the regular + * expression `^[a-zA-Z0-9_]$`. * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric * `expression`. * diff --git a/AnalyticsData/src/V1alpha/OrderBy.php b/AnalyticsData/src/V1alpha/OrderBy.php index 67341afaca3..b94bbe77863 100644 --- a/AnalyticsData/src/V1alpha/OrderBy.php +++ b/AnalyticsData/src/V1alpha/OrderBy.php @@ -9,7 +9,9 @@ use Google\Protobuf\Internal\GPBUtil; /** - * The sort options. + * Order bys define how rows will be sorted in the response. For example, + * ordering rows by descending event count is one ordering, and ordering rows by + * the event name string is a different ordering. * * Generated from protobuf message google.analytics.data.v1alpha.OrderBy */ @@ -33,8 +35,6 @@ class OrderBy extends \Google\Protobuf\Internal\Message * Sorts results by a metric's values. * @type \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy $dimension * Sorts results by a dimension's values. - * @type \Google\Analytics\Data\V1alpha\OrderBy\PivotOrderBy $pivot - * Sorts results by a metric's values within a pivot column group. * @type bool $desc * If true, sorts by descending order. * } @@ -106,37 +106,6 @@ public function setDimension($var) return $this; } - /** - * Sorts results by a metric's values within a pivot column group. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.PivotOrderBy pivot = 3; - * @return \Google\Analytics\Data\V1alpha\OrderBy\PivotOrderBy|null - */ - public function getPivot() - { - return $this->readOneof(3); - } - - public function hasPivot() - { - return $this->hasOneof(3); - } - - /** - * Sorts results by a metric's values within a pivot column group. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.PivotOrderBy pivot = 3; - * @param \Google\Analytics\Data\V1alpha\OrderBy\PivotOrderBy $var - * @return $this - */ - public function setPivot($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\OrderBy\PivotOrderBy::class); - $this->writeOneof(3, $var); - - return $this; - } - /** * If true, sorts by descending order. * diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php b/AnalyticsData/src/V1alpha/QueryReportTaskRequest.php similarity index 99% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php rename to AnalyticsData/src/V1alpha/QueryReportTaskRequest.php index 17ab1b591dc..4f58b1384f4 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskRequest.php +++ b/AnalyticsData/src/V1alpha/QueryReportTaskRequest.php @@ -21,7 +21,7 @@ class QueryReportTaskRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; */ - protected $name = ''; + private $name = ''; /** * Optional. The row count of the start row in the report. The first row is * counted as row 0. @@ -34,7 +34,7 @@ class QueryReportTaskRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $offset = 0; + private $offset = 0; /** * Optional. The number of rows to return from the report. If unspecified, * 10,000 rows are returned. The API returns a maximum of 250,000 rows per @@ -51,7 +51,7 @@ class QueryReportTaskRequest extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $limit = 0; + private $limit = 0; /** * @param string $name Required. The report source name. diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php b/AnalyticsData/src/V1alpha/QueryReportTaskResponse.php similarity index 99% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php rename to AnalyticsData/src/V1alpha/QueryReportTaskResponse.php index cc6ed351abc..6d04e25e9d2 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryReportTaskResponse.php +++ b/AnalyticsData/src/V1alpha/QueryReportTaskResponse.php @@ -58,13 +58,13 @@ class QueryReportTaskResponse extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int32 row_count = 7; */ - protected $row_count = 0; + private $row_count = 0; /** * Metadata for the report. * * Generated from protobuf field .google.analytics.data.v1alpha.ResponseMetaData metadata = 8; */ - protected $metadata = null; + private $metadata = null; /** * Constructor. diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php b/AnalyticsData/src/V1alpha/ReportTask.php similarity index 98% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php rename to AnalyticsData/src/V1alpha/ReportTask.php index 91c9e39f72b..38e457422bb 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask.php +++ b/AnalyticsData/src/V1alpha/ReportTask.php @@ -21,7 +21,7 @@ class ReportTask extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $name = ''; + private $name = ''; /** * Optional. A report definition to fetch report data, which describes the * structure of a report. It typically includes the fields that will be @@ -30,7 +30,7 @@ class ReportTask extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportDefinition report_definition = 2 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $report_definition = null; + private $report_definition = null; /** * Output only. The report metadata for a specific report task, which provides * information about a report. It typically includes the following @@ -39,7 +39,7 @@ class ReportTask extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.analytics.data.v1alpha.ReportTask.ReportMetadata report_metadata = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $report_metadata = null; + private $report_metadata = null; /** * Constructor. diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php b/AnalyticsData/src/V1alpha/ReportTask/ReportDefinition.php similarity index 98% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php rename to AnalyticsData/src/V1alpha/ReportTask/ReportDefinition.php index 5eaf6627192..caf7fa7236b 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportDefinition.php +++ b/AnalyticsData/src/V1alpha/ReportTask/ReportDefinition.php @@ -45,7 +45,7 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 5 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $dimension_filter = null; + private $dimension_filter = null; /** * Optional. The filter clause of metrics. Applied after aggregating the * report's rows, similar to SQL having-clause. Dimensions cannot be used in @@ -53,7 +53,7 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression metric_filter = 6 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $metric_filter = null; + private $metric_filter = null; /** * Optional. The row count of the start row from Google Analytics Storage. * The first row is counted as row 0. @@ -67,7 +67,7 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int64 offset = 7 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $offset = 0; + private $offset = 0; /** * Optional. The number of rows to return in the Report. If unspecified, * 10,000 rows are returned. The API returns a maximum of 250,000 rows per @@ -80,7 +80,7 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int64 limit = 8 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $limit = 0; + private $limit = 0; /** * Optional. Aggregation of metrics. Aggregated metric values will be shown * in rows where the dimension_values are set to @@ -101,14 +101,14 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string currency_code = 11 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $currency_code = ''; + private $currency_code = ''; /** * Optional. Cohort group associated with this request. If there is a cohort * group in the request the 'cohort' dimension must be present. * * Generated from protobuf field .google.analytics.data.v1alpha.CohortSpec cohort_spec = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $cohort_spec = null; + private $cohort_spec = null; /** * Optional. If false or unspecified, each row with all metrics equal to 0 * will not be returned. If true, these rows will be returned if they are @@ -121,7 +121,7 @@ class ReportDefinition extends \Google\Protobuf\Internal\Message * * Generated from protobuf field bool keep_empty_rows = 13 [(.google.api.field_behavior) = OPTIONAL]; */ - protected $keep_empty_rows = false; + private $keep_empty_rows = false; /** * Constructor. @@ -609,6 +609,4 @@ public function setKeepEmptyRows($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ReportDefinition::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportDefinition::class); diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php b/AnalyticsData/src/V1alpha/ReportTask/ReportMetadata.php similarity index 97% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php rename to AnalyticsData/src/V1alpha/ReportTask/ReportMetadata.php index ffb4729f713..f8dbf6056ac 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata.php +++ b/AnalyticsData/src/V1alpha/ReportTask/ReportMetadata.php @@ -20,14 +20,14 @@ class ReportMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field optional .google.analytics.data.v1alpha.ReportTask.ReportMetadata.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $state = null; + private $state = null; /** * Output only. The time when `CreateReportTask` was called and the report * began the `CREATING` state. * * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $begin_creating_time = null; + private $begin_creating_time = null; /** * Output only. The total quota tokens charged during creation of the * report. Because this token count is based on activity from the `CREATING` @@ -36,7 +36,7 @@ class ReportMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int32 creation_quota_tokens_charged = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $creation_quota_tokens_charged = 0; + private $creation_quota_tokens_charged = 0; /** * Output only. The total number of rows in the report result. This field * will be populated when the state is active. You can utilize @@ -45,14 +45,14 @@ class ReportMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field optional int32 task_row_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $task_row_count = null; + private $task_row_count = null; /** * Output only. Error message is populated if a report task fails during * creation. * * Generated from protobuf field optional string error_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $error_message = null; + private $error_message = null; /** * Output only. The total number of rows in Google Analytics storage. If you * want to query additional data rows beyond the current report, they can @@ -71,7 +71,7 @@ class ReportMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field optional int32 total_row_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ - protected $total_row_count = null; + private $total_row_count = null; /** * Constructor. @@ -369,6 +369,4 @@ public function setTotalRowCount($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ReportMetadata::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportMetadata::class); diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php b/AnalyticsData/src/V1alpha/ReportTask/ReportMetadata/State.php similarity index 91% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php rename to AnalyticsData/src/V1alpha/ReportTask/ReportMetadata/State.php index 90c793f136a..d52e28949d8 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTask/ReportMetadata/State.php +++ b/AnalyticsData/src/V1alpha/ReportTask/ReportMetadata/State.php @@ -67,6 +67,4 @@ public static function value($name) } } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Analytics\Data\V1alpha\ReportTask_ReportMetadata_State::class); diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php b/AnalyticsData/src/V1alpha/ReportTaskMetadata.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ReportTaskMetadata.php rename to AnalyticsData/src/V1alpha/ReportTaskMetadata.php diff --git a/AnalyticsData/src/V1alpha/ResponseMetaData.php b/AnalyticsData/src/V1alpha/ResponseMetaData.php index 2a59512caa2..8874cfd66fc 100644 --- a/AnalyticsData/src/V1alpha/ResponseMetaData.php +++ b/AnalyticsData/src/V1alpha/ResponseMetaData.php @@ -18,10 +18,69 @@ class ResponseMetaData extends \Google\Protobuf\Internal\Message /** * If true, indicates some buckets of dimension combinations are rolled into * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). * * Generated from protobuf field bool data_loss_from_other_row = 3; */ private $data_loss_from_other_row = false; + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + */ + private $schema_restriction_response = null; + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + */ + private $currency_code = null; + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + */ + private $time_zone = null; + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + */ + private $empty_reason = null; + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + */ + private $subject_to_thresholding = null; /** * Constructor. @@ -32,6 +91,45 @@ class ResponseMetaData extends \Google\Protobuf\Internal\Message * @type bool $data_loss_from_other_row * If true, indicates some buckets of dimension combinations are rolled into * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). + * @type \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $schema_restriction_response + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * @type string $currency_code + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * @type string $time_zone + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * @type string $empty_reason + * If empty reason is specified, the report is empty for this reason. + * @type bool $subject_to_thresholding + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). * } */ public function __construct($data = NULL) { @@ -42,6 +140,15 @@ public function __construct($data = NULL) { /** * If true, indicates some buckets of dimension combinations are rolled into * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). * * Generated from protobuf field bool data_loss_from_other_row = 3; * @return bool @@ -54,6 +161,15 @@ public function getDataLossFromOtherRow() /** * If true, indicates some buckets of dimension combinations are rolled into * "(other)" row. This can happen for high cardinality reports. + * The metadata parameter dataLossFromOtherRow is populated based on the + * aggregated data table used in the report. The parameter will be accurately + * populated regardless of the filters and limits in the report. + * For example, the (other) row could be dropped from the report because the + * request contains a filter on sessionSource = google. This parameter will + * still be populated if data loss from other row was present in the input + * aggregate data used to generate this report. + * To learn more, see [About the (other) row and data + * sampling](https://support.google.com/analytics/answer/13208658#reports). * * Generated from protobuf field bool data_loss_from_other_row = 3; * @param bool $var @@ -67,5 +183,225 @@ public function setDataLossFromOtherRow($var) return $this; } + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @return \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse|null + */ + public function getSchemaRestrictionResponse() + { + return $this->schema_restriction_response; + } + + public function hasSchemaRestrictionResponse() + { + return isset($this->schema_restriction_response); + } + + public function clearSchemaRestrictionResponse() + { + unset($this->schema_restriction_response); + } + + /** + * Describes the schema restrictions actively enforced in creating this + * report. To learn more, see [Access and data-restriction + * management](https://support.google.com/analytics/answer/10851388). + * + * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; + * @param \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $var + * @return $this + */ + public function setSchemaRestrictionResponse($var) + { + GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse::class); + $this->schema_restriction_response = $var; + + return $this; + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @return string + */ + public function getCurrencyCode() + { + return isset($this->currency_code) ? $this->currency_code : ''; + } + + public function hasCurrencyCode() + { + return isset($this->currency_code); + } + + public function clearCurrencyCode() + { + unset($this->currency_code); + } + + /** + * The currency code used in this report. Intended to be used in formatting + * currency metrics like `purchaseRevenue` for visualization. If currency_code + * was specified in the request, this response parameter will echo the request + * parameter; otherwise, this response parameter is the property's current + * currency_code. + * Currency codes are string encodings of currency types from the ISO 4217 + * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", + * "EUR", "JPY". To learn more, see + * https://support.google.com/analytics/answer/9796179. + * + * Generated from protobuf field optional string currency_code = 5; + * @param string $var + * @return $this + */ + public function setCurrencyCode($var) + { + GPBUtil::checkString($var, True); + $this->currency_code = $var; + + return $this; + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @return string + */ + public function getTimeZone() + { + return isset($this->time_zone) ? $this->time_zone : ''; + } + + public function hasTimeZone() + { + return isset($this->time_zone); + } + + public function clearTimeZone() + { + unset($this->time_zone); + } + + /** + * The property's current timezone. Intended to be used to interpret + * time-based dimensions like `hour` and `minute`. Formatted as strings from + * the IANA Time Zone database (https://www.iana.org/time-zones); for example + * "America/New_York" or "Asia/Tokyo". + * + * Generated from protobuf field optional string time_zone = 6; + * @param string $var + * @return $this + */ + public function setTimeZone($var) + { + GPBUtil::checkString($var, True); + $this->time_zone = $var; + + return $this; + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @return string + */ + public function getEmptyReason() + { + return isset($this->empty_reason) ? $this->empty_reason : ''; + } + + public function hasEmptyReason() + { + return isset($this->empty_reason); + } + + public function clearEmptyReason() + { + unset($this->empty_reason); + } + + /** + * If empty reason is specified, the report is empty for this reason. + * + * Generated from protobuf field optional string empty_reason = 7; + * @param string $var + * @return $this + */ + public function setEmptyReason($var) + { + GPBUtil::checkString($var, True); + $this->empty_reason = $var; + + return $this; + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @return bool + */ + public function getSubjectToThresholding() + { + return isset($this->subject_to_thresholding) ? $this->subject_to_thresholding : false; + } + + public function hasSubjectToThresholding() + { + return isset($this->subject_to_thresholding); + } + + public function clearSubjectToThresholding() + { + unset($this->subject_to_thresholding); + } + + /** + * If `subjectToThresholding` is true, this report is subject to thresholding + * and only returns data that meets the minimum aggregation thresholds. It is + * possible for a request to be subject to thresholding thresholding and no + * data is absent from the report, and this happens when all data is above the + * thresholds. To learn more, see [Data + * thresholds](https://support.google.com/analytics/answer/9383630) and [About + * Demographics and + * Interests](https://support.google.com/analytics/answer/2799357). + * + * Generated from protobuf field optional bool subject_to_thresholding = 8; + * @param bool $var + * @return $this + */ + public function setSubjectToThresholding($var) + { + GPBUtil::checkBool($var); + $this->subject_to_thresholding = $var; + + return $this; + } + } diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php b/AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php similarity index 94% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php rename to AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php index be49e2a5e52..e2bed167d7d 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php +++ b/AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse.php @@ -79,6 +79,4 @@ public function setActiveMetricRestrictions($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SchemaRestrictionResponse::class, \Google\Analytics\Data\V1alpha\ResponseMetaData_SchemaRestrictionResponse::class); diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php b/AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php similarity index 92% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php rename to AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php index 899eb88c337..1d3df5152fa 100644 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php +++ b/AnalyticsData/src/V1alpha/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php @@ -20,7 +20,7 @@ class ActiveMetricRestriction extends \Google\Protobuf\Internal\Message * * Generated from protobuf field optional string metric_name = 1; */ - protected $metric_name = null; + private $metric_name = null; /** * The reason for this metric's restriction. * @@ -109,6 +109,4 @@ public function setRestrictedMetricTypes($var) } -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ActiveMetricRestriction::class, \Google\Analytics\Data\V1alpha\ResponseMetaData_SchemaRestrictionResponse_ActiveMetricRestriction::class); diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php b/AnalyticsData/src/V1alpha/RestrictedMetricType.php similarity index 100% rename from owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RestrictedMetricType.php rename to AnalyticsData/src/V1alpha/RestrictedMetricType.php diff --git a/AnalyticsData/src/V1alpha/gapic_metadata.json b/AnalyticsData/src/V1alpha/gapic_metadata.json index 34f0f627b2f..6b8b6ebe92b 100644 --- a/AnalyticsData/src/V1alpha/gapic_metadata.json +++ b/AnalyticsData/src/V1alpha/gapic_metadata.json @@ -20,6 +20,11 @@ "createRecurringAudienceList" ] }, + "CreateReportTask": { + "methods": [ + "createReportTask" + ] + }, "GetAudienceList": { "methods": [ "getAudienceList" @@ -30,6 +35,11 @@ "getRecurringAudienceList" ] }, + "GetReportTask": { + "methods": [ + "getReportTask" + ] + }, "ListAudienceLists": { "methods": [ "listAudienceLists" @@ -40,11 +50,21 @@ "listRecurringAudienceLists" ] }, + "ListReportTasks": { + "methods": [ + "listReportTasks" + ] + }, "QueryAudienceList": { "methods": [ "queryAudienceList" ] }, + "QueryReportTask": { + "methods": [ + "queryReportTask" + ] + }, "RunFunnelReport": { "methods": [ "runFunnelReport" diff --git a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_client_config.json b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_client_config.json index 2718a17f7bd..730a2dea65b 100644 --- a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_client_config.json +++ b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_client_config.json @@ -48,6 +48,11 @@ "retry_codes_name": "retry_policy_1_codes", "retry_params_name": "retry_policy_1_params" }, + "CreateReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, "GetAudienceList": { "timeout_millis": 60000, "retry_codes_name": "retry_policy_1_codes", @@ -58,6 +63,11 @@ "retry_codes_name": "retry_policy_1_codes", "retry_params_name": "retry_policy_1_params" }, + "GetReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, "ListAudienceLists": { "timeout_millis": 60000, "retry_codes_name": "retry_policy_1_codes", @@ -68,11 +78,21 @@ "retry_codes_name": "retry_policy_1_codes", "retry_params_name": "retry_policy_1_params" }, + "ListReportTasks": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, "QueryAudienceList": { "timeout_millis": 60000, "retry_codes_name": "retry_policy_1_codes", "retry_params_name": "retry_policy_1_params" }, + "QueryReportTask": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, "RunFunnelReport": { "timeout_millis": 60000, "retry_codes_name": "no_retry_1_codes", diff --git a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php index 2dd5ef0502a..6903c5bf2ef 100644 --- a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php +++ b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php @@ -42,6 +42,25 @@ ], ], ], + 'CreateReportTask' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Analytics\Data\V1alpha\ReportTask', + 'metadataReturnType' => '\Google\Analytics\Data\V1alpha\ReportTaskMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], 'CreateRecurringAudienceList' => [ 'callType' => \Google\ApiCore\Call::UNARY_CALL, 'responseType' => 'Google\Analytics\Data\V1alpha\RecurringAudienceList', @@ -78,6 +97,18 @@ ], ], ], + 'GetReportTask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ReportTask', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'ListAudienceLists' => [ 'pageStreaming' => [ 'requestPageTokenGetMethod' => 'getPageToken', @@ -118,6 +149,26 @@ ], ], ], + 'ListReportTasks' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getReportTasks', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\ListReportTasksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], 'QueryAudienceList' => [ 'callType' => \Google\ApiCore\Call::UNARY_CALL, 'responseType' => 'Google\Analytics\Data\V1alpha\QueryAudienceListResponse', @@ -130,6 +181,18 @@ ], ], ], + 'QueryReportTask' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Analytics\Data\V1alpha\QueryReportTaskResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], 'RunFunnelReport' => [ 'callType' => \Google\ApiCore\Call::UNARY_CALL, 'responseType' => 'Google\Analytics\Data\V1alpha\RunFunnelReportResponse', @@ -158,6 +221,7 @@ 'audienceList' => 'properties/{property}/audienceLists/{audience_list}', 'property' => 'properties/{property}', 'recurringAudienceList' => 'properties/{property}/recurringAudienceLists/{recurring_audience_list}', + 'reportTask' => 'properties/{property}/reportTasks/{report_task}', ], ], ], diff --git a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php index 73859d059df..6b05bd39065 100644 --- a/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php +++ b/AnalyticsData/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php @@ -47,6 +47,18 @@ ], ], ], + 'CreateReportTask' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', + 'body' => 'report_task', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], 'GetAudienceList' => [ 'method' => 'get', 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}', @@ -69,6 +81,17 @@ ], ], ], + 'GetReportTask' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], 'ListAudienceLists' => [ 'method' => 'get', 'uriTemplate' => '/v1alpha/{parent=properties/*}/audienceLists', @@ -91,6 +114,17 @@ ], ], ], + 'ListReportTasks' => [ + 'method' => 'get', + 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], 'QueryAudienceList' => [ 'method' => 'post', 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}:query', @@ -103,6 +137,18 @@ ], ], ], + 'QueryReportTask' => [ + 'method' => 'post', + 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}:query', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], 'RunFunnelReport' => [ 'method' => 'post', 'uriTemplate' => '/v1alpha/{property=properties/*}:runFunnelReport', diff --git a/AnalyticsData/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php b/AnalyticsData/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php index 588ceb5caa4..df143d25ace 100644 --- a/AnalyticsData/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php +++ b/AnalyticsData/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php @@ -26,8 +26,11 @@ use Google\Analytics\Data\V1alpha\AudienceList; use Google\Analytics\Data\V1alpha\ListAudienceListsResponse; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsResponse; +use Google\Analytics\Data\V1alpha\ListReportTasksResponse; use Google\Analytics\Data\V1alpha\QueryAudienceListResponse; +use Google\Analytics\Data\V1alpha\QueryReportTaskResponse; use Google\Analytics\Data\V1alpha\RecurringAudienceList; +use Google\Analytics\Data\V1alpha\ReportTask; use Google\Analytics\Data\V1alpha\RunFunnelReportResponse; use Google\Analytics\Data\V1alpha\SheetExportAudienceListResponse; use Google\ApiCore\ApiException; @@ -292,6 +295,129 @@ public function createRecurringAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function createReportTaskTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createReportTaskTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $response = $gapicClient->createReportTask($formattedParent, $reportTask); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getReportTask(); + $this->assertProtobufEquals($reportTask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createReportTaskExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $response = $gapicClient->createReportTask($formattedParent, $reportTask); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + /** @test */ public function getAudienceListTest() { @@ -432,6 +558,66 @@ public function getRecurringAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function getReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $response = $gapicClient->getReportTask($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + try { + $gapicClient->getReportTask($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function listAudienceListsTest() { @@ -568,6 +754,74 @@ public function listRecurringAudienceListsExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function listReportTasksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $reportTasksElement = new ReportTask(); + $reportTasks = [ + $reportTasksElement, + ]; + $expectedResponse = new ListReportTasksResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setReportTasks($reportTasks); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $response = $gapicClient->listReportTasks($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + try { + $gapicClient->listReportTasks($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function queryAudienceListTest() { @@ -628,6 +882,66 @@ public function queryAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function queryReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryReportTaskResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $response = $gapicClient->queryReportTask($name); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + try { + $gapicClient->queryReportTask($name); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function runFunnelReportTest() { diff --git a/AnalyticsData/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php b/AnalyticsData/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php index a64dab8f9e6..27ed731150f 100644 --- a/AnalyticsData/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php +++ b/AnalyticsData/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php @@ -26,15 +26,22 @@ use Google\Analytics\Data\V1alpha\Client\AlphaAnalyticsDataClient; use Google\Analytics\Data\V1alpha\CreateAudienceListRequest; use Google\Analytics\Data\V1alpha\CreateRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\CreateReportTaskRequest; use Google\Analytics\Data\V1alpha\GetAudienceListRequest; use Google\Analytics\Data\V1alpha\GetRecurringAudienceListRequest; +use Google\Analytics\Data\V1alpha\GetReportTaskRequest; use Google\Analytics\Data\V1alpha\ListAudienceListsRequest; use Google\Analytics\Data\V1alpha\ListAudienceListsResponse; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsRequest; use Google\Analytics\Data\V1alpha\ListRecurringAudienceListsResponse; +use Google\Analytics\Data\V1alpha\ListReportTasksRequest; +use Google\Analytics\Data\V1alpha\ListReportTasksResponse; use Google\Analytics\Data\V1alpha\QueryAudienceListRequest; use Google\Analytics\Data\V1alpha\QueryAudienceListResponse; +use Google\Analytics\Data\V1alpha\QueryReportTaskRequest; +use Google\Analytics\Data\V1alpha\QueryReportTaskResponse; use Google\Analytics\Data\V1alpha\RecurringAudienceList; +use Google\Analytics\Data\V1alpha\ReportTask; use Google\Analytics\Data\V1alpha\RunFunnelReportRequest; use Google\Analytics\Data\V1alpha\RunFunnelReportResponse; use Google\Analytics\Data\V1alpha\SheetExportAudienceListRequest; @@ -313,6 +320,135 @@ public function createRecurringAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function createReportTaskTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createReportTaskTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $request = (new CreateReportTaskRequest()) + ->setParent($formattedParent) + ->setReportTask($reportTask); + $response = $gapicClient->createReportTask($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getReportTask(); + $this->assertProtobufEquals($reportTask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createReportTaskExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/createReportTaskTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $reportTask = new ReportTask(); + $request = (new CreateReportTaskRequest()) + ->setParent($formattedParent) + ->setReportTask($reportTask); + $response = $gapicClient->createReportTask($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + /** @test */ public function getAudienceListTest() { @@ -461,6 +597,70 @@ public function getRecurringAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function getReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new ReportTask(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $request = (new GetReportTaskRequest()) + ->setName($formattedName); + $response = $gapicClient->getReportTask($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); + $request = (new GetReportTaskRequest()) + ->setName($formattedName); + try { + $gapicClient->getReportTask($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function listAudienceListsTest() { @@ -605,6 +805,78 @@ public function listRecurringAudienceListsExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function listReportTasksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $reportTasksElement = new ReportTask(); + $reportTasks = [ + $reportTasksElement, + ]; + $expectedResponse = new ListReportTasksResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setReportTasks($reportTasks); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListReportTasksRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listReportTasks($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listReportTasksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->propertyName('[PROPERTY]'); + $request = (new ListReportTasksRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listReportTasks($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function queryAudienceListTest() { @@ -669,6 +941,70 @@ public function queryAudienceListExceptionTest() $this->assertTrue($transport->isExhausted()); } + /** @test */ + public function queryReportTaskTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rowCount = 1340416618; + $expectedResponse = new QueryReportTaskResponse(); + $expectedResponse->setRowCount($rowCount); + $transport->addResponse($expectedResponse); + // Mock request + $name = 'name3373707'; + $request = (new QueryReportTaskRequest()) + ->setName($name); + $response = $gapicClient->queryReportTask($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($name, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryReportTaskExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $name = 'name3373707'; + $request = (new QueryReportTaskRequest()) + ->setName($name); + try { + $gapicClient->queryReportTask($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + /** @test */ public function runFunnelReportTest() { diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/AnalyticsDataApi.php deleted file mode 100644 index fce3ba97b7179fb6a742b0c8508cc93e69987adf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 11945 zcmd5COK%&;IV(!C^ikGhtp}q#yxu%4D=uj>Z@P-R6eU}!BP)`uAcoMziX2f3QM=6U z(h3_0Xo?<+qG*Bk2eh{W4bT8R7U-csivmF}ZGj$qNf6}H^wevC0R3iWXSqu*wWOQ^ z)k)l$@0;)an)&9<`avC@QEm~7IEF_m%3f3P4v12BY|k#+HD#}{zfT;cY#-Il8ga6U zQo5_G-`!SLN^9Gf5Y)9BPMH*xs%=+mBxhJgt?8L%H&-z{BlqCCQL7&qtoBj3eUKjWSVgZ4}=koOAR)@LrmLHl>6u2&{4R31r0g3tmmrePz55NT?3uQuP=LEunJipUI8M6v z*}9DqSyBXb8&pUrpxrggBMy?fTOw}RG3%b~Y~a>Hp-Q|!wDilu75`X@&fHfPIE{ru z2a!vP=QK$8bVYH9*Kn*GjBbkHB=~Q)XW219778u?TIgbt)J;@^Wm8ewmfIiTa?K=` z*B{KPNotiMIWQiWw$mTzCh={tXYTIUR@G@(mT6UY@7AdY^v7gi0NW-Sv1c6B<0)o_ z^Nlx5-%PYhC9sNB^s0qGk5sFd;m`Nrm9x2%{1k`F25y+8?v(Z2aQ;bwwr-+J25RNL zI6oI!Ei>Ku3l~ER`&2>tp06Q)!{eb1j;{uP=^1~i){=G34rJYS0E-FeQ8`Ztly6Y~ zB7wT>5DZb9q}*^E)R@+&pm~+a9nPpNaim%)qQ3E7al~%;<4~ zQmb$wMha*osfJ_vmebP3ML1tRKxZd4-Lnsg)iNOIHkDa%7zT9&EKb6>9@(iL!o^zz zo$C~jyB)Dt-`~z6fAyCVT;jeQbDaCX@bFm}ts7OMyI2=6sc;jP=K$DuF0R0rB=t8K zg-#>Ut)q_-c?U9quA|oBqIReQo+)(5Pr`&n-uLtnaWoQ*GM_8TFsZjKtM9@rDllw^ zLXI~hdb`fzFj)=rH z@j^nl3A1+w1^fz$;(05KNGRcJ5YsI0Zzs^K&!Vs;T2}?ZV z`RjcsF}p0*-WR!2PQ0<F+hLSmu$|rQy`6l1k>B$d4&ZjiZizte5QuRw*>)v7nQ>JwOp*tR{|QJ35w=E{3Me zDD`iCQi^VP9;Puzm9fI1fs1x!HG*whCXM?fzHgB3yVAXQ8Ec^&qFcMAr`n~n7jg{rK)wPw<X?;NmB%=}r~{KVr-IF|ka47Dr%MXBJnS zg=wsQJM5)62A~IuWw|t>NtVsyR9Bpb3|3Np&Womt?j-;R>-fj@58D138 zW-1c$(E$eJ3ovZ&@4JMTv?*#pk}She%{(%_49$G}oBAonu^7aDaP0^}wE9lx`w2qA z7XvL&VY--=X}Vk#UKpgONL!N?+-};(G;aiIU>pqbDu-4#LZwXOQH`lTlHlpB146u& z_v^M3NozuYkD4=k7xxba;9^%|e4%4C;MOr@Ra{Cnt>Ad+7gXTkRkOm&J|>Ge8L{xw zp~u1g^+>}Mt3|@c)ADi(CiL((vl7(+^O=Z-)bBt#tlGOUSrHwH{=leV%jefqFZXC5 zB>}!eq19_JCGZC;w0CKp66(dMZ>X=pYzG9xB~QQ*BS|Qsn1)f?BAib3t09=(Y*?!} zY#_BwLM=>K74~+b+u*R=3yYA(UX|#MVO5b&?g$GBeBvC8Y*GM@qX5G=(ZUm%Bc$`s zC4h7CIP6<6$zk<9G_u2reQaU(NZmTy8x{e@(QSb2qhmEH?Rad9rSEh;*Av2ZEPXWw z#xXYFaUbIY({0e<9&00YuUY5Wdp!SE0^)d$WVsl2!dSNvDL-}zMqE3#MFC+_hbKti4$p>G3#?Ls%q@%7LLRPF}ejCnnhIHS{d6RKA zFK^Xuw7Y1p-Dqdwf7^r${;5W_>X0g*a${?eS{P3p1#*#UEkG{aH!!(572@c7O&4Po zRZdbEyi4~Nn;d=~hf+Ak#rbU$yO;`L4Ge2^BzYOqW%~f_7s~}wWHZ(l?&3~GLac;55AG>jq-w`b(tzF0SZzP<@p{XPL&L$A` z+Fx>?{+jwr8k~3^DJwAUAyutjghiiIn@nob;U@DEOn4Z+Y9SodP<4y9c}BGRkvZ5 zb$G2MLH46Gj(<(TTnAb|@vp&DtI|HePKG$5piinXgL3^g1H+gxe#C;mF7WV-lhlGD z_n0w!B-db&HJv=!s7Vn3o6S57Gs6=XE4{$H1S3br`{q&O$i@1XM$TTLupD4e^e&}0 zsHt!>%!W{ymq$=iEav$)E=lPJ?^W4cn_3Ds7>0TerrEWC@C{)nOOXMCZ`{2*A#K5D z>9nO~fx$re(LJZ{dGe3ZkvpjIE%zpjIlM}v!ATfx?|#_-Bsu@DIgr`w2Ti<*pt_KM zFTq4xVJ#Mk5QYfr0o)nxYhJv&x z|62l?hfC2{Q<=+26=^4k;NmI4Md-pg8(i+IA4;ES&$dsx!$(sqr^(`>HqEb+uNvX` zI^%Uoy&B?`T{uTM%?TLFj9X|8wQ7_(yv&~J7^cau3c`b&6&-SQKnRYLWEBJGYp(QA zW4FzWsaMr}izzzyh_DppD2K{?kIosX3co-{=`yU6mlBxj0w-8Ys=~U0`wYGrW^hS; ztuF=%8w9c=D4V}UPiwnOOZ2q1{erEetQ59K^+uS7tQ@kuWF^UeLQ|tQ7{=%(npy{h zAUw&`VgP+jEIrixry0!HB7AT^izwB4DlJi8|up~+l%ElfR3oD(CrP1{13c;Wmz~*97%rD4e-%q5e+ADh~rL6jb|6* ziu_Lr=BXWRiaU{rK;&;FXu3P7U@pm4PQ&0^^J>(ZUk&rxhj!)9C72YZDXJ+sDG#>; z2)+_B-|;7!5*a|nGyxAaIWXp+*=B;qVkI>)6M*>>szrr%@$)FI5Y2N>)J(LbSukIFdx#Qzw zUlYNTKBM6sv>qK_?RjUGUZ~ktt(gc?aqt~nZ@aQM?MvPox*Kzgf5693c)NePffZ*W zy#PLd#__XfZ%Fqw|7Bv;uHkJ^)^@77DzUH__v~Ej@ncIsk;mFMsJOq>Zo>0{0*uO$ zX|>B352Nqpn(|Dj$`4Balf7Yf-iw!m*R5Cio956HXnLh?mSdhjvz`2D@(G*({1=W? B(fj}a diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/GPBMetadata/Google/Analytics/Data/V1Alpha/Data.php deleted file mode 100644 index 281b7c696ed61165745b56ae7630f657304ff057..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 15349 zcmeHO&2J;el^=?dhI*7Js`WV~yVkPTjWlxMI)gv(@ku*PMMu`@U7TJ;* zlif^rbH;LFVE3?qFF}y3FN*|w-#u)Q9QL|Eg20C$hd4lzOa6cWd)!k_dG*!ZY?5kf zG|4GCshd^5dSCUcSFftydAEDkg*%yD!!&H&HJX{@^Nf3DWV*KHS`Dk6IqsdD7S)s%6xjLhTjo>R3IyVQgnkE$g&x+|y0HeeSjz&b_AY>i3?$skggl zI(^7ePykc!7*1Dj7@6I2?!a($((-7R_CHcY|Dzr9_R*UP>HjuBqpdqmhP;IDKnDN1 zz2kPPk#Srdhs)e;IaP8HP#P z-tAhb_x+5Js7y?OW;iOCu3@8iM>~eouv=Z%vdh?Xd;8RIJp+4vL34H^_2fJ4vRzHOOFBC)-%J_8oFbwO;UX2^7z?2cK3(dyGDR}-L3$hdU3!S zBpa65Ks%en*3%Su?|DS_QG$}MZ$PSF8)*enzB{M~shigGu$&(TBCW!Fe+LI+B91Y! z05eUa-RiV(%2995La{&rTjtZ2(>iXmxJt-Boq#k3 zKaSw5CGEkCj=^|pTfHug&*avZB5W4M*l#&5I(8Qlmd$}!JU%B-0aB*r1{A0BBDr<% zl5(L;UxDcpsxgn?SI2_byOx`VNn%p@=m?gE=_~C((ziMD;^ifjKb?SS22Yscq-C_5 znjc3v$ee@zHcvIK1+(ktBDAQ|J`5L)phBu;YHjqAfFV4S+=_xJn8dRl%mZ{wuVY~N z2^hu-pO28H$T|gajt%#jVVDAkkw6qqj&%|^xmf@*KTfEB<&P&|HmJ8$0O;s$<4kkU zyNr2LTmKLtY7iiMKzi4(vor@&PxW@sU=x$fdP0htLnzv9Jr(ooUt=)icUp&)1ErSV z(`tuhRjU`PWi?-TP*8W$*Q6PkQlBXKS~@1pLo%oC7K&BvaiO-Cp1{Fo)Zz|*jN?pC zntUQ)Ye-OChP;qmPBu9J7~k`*yAvdh}mUgSRd&IESJh^MX41^ z#UXZmudeK)UD1sDYPG7>_LL%8bp<5vQ7ct6l{SmxT0Fa3QI(onVJ#;mgb%*)8&Aof z#o>C%ZW?y(TzUZ09m>U=G`}2S7v3++2%JCR)* zxfIM2+F)87pUdBm!CW7;Nbe#O+g3+obDpf|my1{FJ|tX=cOQ?j`@;R}FdKZ9mLZ9G z>|0+B2o%T2S%KN6g?j=cFj5Sct|U%cRFFz9|1k!Tx6Ulvt#*xu^cGxi&?m8CMJ3EG9)m#{mKodSPHM4pn1kPLRb39GvmoDTa+rBFK@3lfAHDwPU;_@ae4YMp6TW>Ua9aNC-ToUrHryyOyy{u(A1~Q9|=Fz1Ltf5_X zt!+7uMkkJiJ8E0At!LD;3CV$*PUFnz=;(Qp&(O^%`JV#u)T|KUitxDEDuu+?0#UTs zyY_J`Caq)0_H5fQ8|PZXY8q=K%b3}Vk>6He#>ME+KE#PaHwrU*6Xg93m^C_G_Z(%@ z9o$x3r(NRYr@OG~^p3w}G+YhmwtI%spIPlD#_w7JTP5};vDNzjPQZBG+M-$vW&;++9o({pn;)ZM_lUIA3Y`2Qi3OtY^4oN_#BD2wOzK7b3ts zv1x`RDKOWe*@!?P9!YL(MxZc}Sdx{6R0wolq-=Ck8(vvH2gyKp%uIQXOg05G;l_W8 z!yHy_FdKBw-|Jb(8aYV0*87-2Yor#?)ER?Di%ff0u?E(2q&&@Vlqy`D_}}i~oD^%)Wq=-m>=^b_)W)!F%VvsU36OFIQIZPC_Dq+-{U>;%Yhh7? zl=|A|KK0-v6w*=~Qh2tNx(s{?ZU&4vATKMUTmn$uf@ILXSnWdlI=BgJ(nWHL)H-Zj z46tm695w->cH&HW zw%7NoRXG_lT7+!!k0(ShReQ%QUBr#-f)_&C8D)CGv{|9V@N%wSH04V`9#WiY1rFod zs9czlB?tK;Ok#ROSccHF93cW*DiSy>Jv!hC(|9JtMb}H$NSY@9R}7MMB&w=$iZy0e zs={gyAMr4u(e9CAvWB&OtP!?!KG&kE$^o!E?}@wP8RG+v$2mDFI|#t2qO1Ii7%T>U z@bDkO5~*4uu{5y)gEG_lrEuw2BkUPO6bQSd04mjBk>EOH6~J>60n0obmD~qls~mu$ z%D;@kjlhps8fH?nF%MwD*TZR8T|$dw$xTHT^a-f2NtN}K4&jEwT+2&i!O6#Vqfs>+ z9vb1Y7;JUoS&%++1gRauy2IX# z=CvsP?1vPik(#I{J&(j_>(f&@E}Ul-*@2Z2gB)JSZ*NENTL`p|ZscFZ;H8TiNVsZ` z;-fK5CT#ULprqg6R<>Uo&%Dw%{UGo>77pVmPUqMjs29nB2=l>1!91q9!twmySZY$A z;@T{txejXvc^)0hQHyI3PIw3Nyn#rLn$ zqxPRC;JOId{!0rvnC-FEm}Z=uG^4hZfn^Dc-Fq^hmc~v_p)kIdyl@c(r0$g>Y@7s6<8Y93Xd0; zbgTuL=UUgoQ#f3LX|b7=XjnOE6_&MOZRFp_K;oc*@WV?$z~b1y>A~tH--bI5-@0{m z8>`{C4IjCQdw0CJFAE^%3_rl>Nl0!ElA13}?lrjUaoPnU$p03H4A*Sr0Me5|%FAC- zXwH3)2e|JA0UwSa!7Cg48t%*2MmcxPg3fS*2iWYpaCdkc-|LjtYQt#lsw&D@MnON2}b zvj&^UKf^E@Uj4JdsI3F($%k-fXp>NO zQXR$?S5!~_VH}o+4*vJtfZbB~OT$Du^VxELpSp7!0rBK4f(xU$0cuV*W5aL%vO50;p;& z4IT)NhM-CEkp~-HMJB1HXYtzpJbm%7uwOz&$;-J-4VH#osFW~jDr%J&yr%AGqwRu1 zwxiS(GzuD_LVR0S*_(;nciPbFFgh8w&pn@ziSL zW$~ho&PxGNmoqr=TCf HM*x2TC(@{l diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php deleted file mode 100644 index 52ad212cf8c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimension.php +++ /dev/null @@ -1,76 +0,0 @@ -google.analytics.data.v1alpha.AudienceDimension - */ -class AudienceDimension extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $dimension_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php deleted file mode 100644 index e34a79a37b1..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceDimensionValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1alpha.AudienceDimensionValue - */ -class AudienceDimensionValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Value as a string if the dimension type is a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->readOneof(1); - } - - public function hasValue() - { - return $this->hasOneof(1); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php deleted file mode 100644 index f365d873b01..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList.php +++ /dev/null @@ -1,621 +0,0 @@ -google.analytics.data.v1alpha.AudienceList - */ -class AudienceList extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The audience list resource name assigned during - * creation. This resource name identifies this `AudienceList`. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $audience = ''; - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $audience_display_name = ''; - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $dimensions; - /** - * Output only. The current state for this AudienceList. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = null; - /** - * Output only. The time when CreateAudienceList was called and the - * AudienceList began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $begin_creating_time = null; - /** - * Output only. The total quota tokens charged during creation of the - * AudienceList. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceList - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $creation_quota_tokens_charged = 0; - /** - * Output only. The total number of rows in the AudienceList result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $row_count = null; - /** - * Output only. Error message is populated when an audience list fails during - * creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $error_message = null; - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $percentage_completed = null; - /** - * Output only. The recurring audience list that created this audience list. - * Recurring audience lists create audience lists daily. - * If audience lists are created directly, they will have no associated - * recurring audience list, and this field will be blank. - * - * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $recurring_audience_list = null; - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when an audience list is - * ready to be used. Webhooks allow a notification to be sent to your servers - * & avoid the need for polling. - * Either one or two POST requests will be sent to the webhook. The first POST - * request will be sent immediately showing the newly created audience list in - * its CREATING state. The second POST request will be sent after the audience - * list completes creation (either the ACTIVE or FAILED state). - * If identical audience lists are requested in quick succession, the second & - * subsequent audience lists can be served from cache. In that case, the - * audience list create method can return an audience list is already ACTIVE. - * In this scenario, only one POST request will be sent to the webhook. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $webhook_notification = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The audience list resource name assigned during - * creation. This resource name identifies this `AudienceList`. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @type string $audience - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * @type string $audience_display_name - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * @type array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * Required. The dimensions requested and displayed in the query response. - * @type int $state - * Output only. The current state for this AudienceList. - * @type \Google\Protobuf\Timestamp $begin_creating_time - * Output only. The time when CreateAudienceList was called and the - * AudienceList began the `CREATING` state. - * @type int $creation_quota_tokens_charged - * Output only. The total quota tokens charged during creation of the - * AudienceList. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceList - * enters the `ACTIVE` or `FAILED` states. - * @type int $row_count - * Output only. The total number of rows in the AudienceList result. - * @type string $error_message - * Output only. Error message is populated when an audience list fails during - * creation. A common reason for such a failure is quota exhaustion. - * @type float $percentage_completed - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * @type string $recurring_audience_list - * Output only. The recurring audience list that created this audience list. - * Recurring audience lists create audience lists daily. - * If audience lists are created directly, they will have no associated - * recurring audience list, and this field will be blank. - * @type \Google\Analytics\Data\V1alpha\WebhookNotification $webhook_notification - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when an audience list is - * ready to be used. Webhooks allow a notification to be sent to your servers - * & avoid the need for polling. - * Either one or two POST requests will be sent to the webhook. The first POST - * request will be sent immediately showing the newly created audience list in - * its CREATING state. The second POST request will be sent after the audience - * list completes creation (either the ACTIVE or FAILED state). - * If identical audience lists are requested in quick succession, the second & - * subsequent audience lists can be served from cache. In that case, the - * audience list create method can return an audience list is already ACTIVE. - * In this scenario, only one POST request will be sent to the webhook. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The audience list resource name assigned during - * creation. This resource name identifies this `AudienceList`. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The audience list resource name assigned during - * creation. This resource name identifies this `AudienceList`. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAudience() - { - return $this->audience; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAudience($var) - { - GPBUtil::checkString($var, True); - $this->audience = $var; - - return $this; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getAudienceDisplayName() - { - return $this->audience_display_name; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setAudienceDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->audience_display_name = $var; - - return $this; - } - - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * Output only. The current state for this AudienceList. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return isset($this->state) ? $this->state : 0; - } - - public function hasState() - { - return isset($this->state); - } - - public function clearState() - { - unset($this->state); - } - - /** - * Output only. The current state for this AudienceList. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\AudienceList\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. The time when CreateAudienceList was called and the - * AudienceList began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBeginCreatingTime() - { - return $this->begin_creating_time; - } - - public function hasBeginCreatingTime() - { - return isset($this->begin_creating_time); - } - - public function clearBeginCreatingTime() - { - unset($this->begin_creating_time); - } - - /** - * Output only. The time when CreateAudienceList was called and the - * AudienceList began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBeginCreatingTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->begin_creating_time = $var; - - return $this; - } - - /** - * Output only. The total quota tokens charged during creation of the - * AudienceList. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceList - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getCreationQuotaTokensCharged() - { - return $this->creation_quota_tokens_charged; - } - - /** - * Output only. The total quota tokens charged during creation of the - * AudienceList. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceList - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setCreationQuotaTokensCharged($var) - { - GPBUtil::checkInt32($var); - $this->creation_quota_tokens_charged = $var; - - return $this; - } - - /** - * Output only. The total number of rows in the AudienceList result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getRowCount() - { - return isset($this->row_count) ? $this->row_count : 0; - } - - public function hasRowCount() - { - return isset($this->row_count); - } - - public function clearRowCount() - { - unset($this->row_count); - } - - /** - * Output only. The total number of rows in the AudienceList result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - - /** - * Output only. Error message is populated when an audience list fails during - * creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getErrorMessage() - { - return isset($this->error_message) ? $this->error_message : ''; - } - - public function hasErrorMessage() - { - return isset($this->error_message); - } - - public function clearErrorMessage() - { - unset($this->error_message); - } - - /** - * Output only. Error message is populated when an audience list fails during - * creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setErrorMessage($var) - { - GPBUtil::checkString($var, True); - $this->error_message = $var; - - return $this; - } - - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return float - */ - public function getPercentageCompleted() - { - return isset($this->percentage_completed) ? $this->percentage_completed : 0.0; - } - - public function hasPercentageCompleted() - { - return isset($this->percentage_completed); - } - - public function clearPercentageCompleted() - { - unset($this->percentage_completed); - } - - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param float $var - * @return $this - */ - public function setPercentageCompleted($var) - { - GPBUtil::checkDouble($var); - $this->percentage_completed = $var; - - return $this; - } - - /** - * Output only. The recurring audience list that created this audience list. - * Recurring audience lists create audience lists daily. - * If audience lists are created directly, they will have no associated - * recurring audience list, and this field will be blank. - * - * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getRecurringAudienceList() - { - return isset($this->recurring_audience_list) ? $this->recurring_audience_list : ''; - } - - public function hasRecurringAudienceList() - { - return isset($this->recurring_audience_list); - } - - public function clearRecurringAudienceList() - { - unset($this->recurring_audience_list); - } - - /** - * Output only. The recurring audience list that created this audience list. - * Recurring audience lists create audience lists daily. - * If audience lists are created directly, they will have no associated - * recurring audience list, and this field will be blank. - * - * Generated from protobuf field optional string recurring_audience_list = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setRecurringAudienceList($var) - { - GPBUtil::checkString($var, True); - $this->recurring_audience_list = $var; - - return $this; - } - - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when an audience list is - * ready to be used. Webhooks allow a notification to be sent to your servers - * & avoid the need for polling. - * Either one or two POST requests will be sent to the webhook. The first POST - * request will be sent immediately showing the newly created audience list in - * its CREATING state. The second POST request will be sent after the audience - * list completes creation (either the ACTIVE or FAILED state). - * If identical audience lists are requested in quick succession, the second & - * subsequent audience lists can be served from cache. In that case, the - * audience list create method can return an audience list is already ACTIVE. - * In this scenario, only one POST request will be sent to the webhook. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\WebhookNotification|null - */ - public function getWebhookNotification() - { - return $this->webhook_notification; - } - - public function hasWebhookNotification() - { - return isset($this->webhook_notification); - } - - public function clearWebhookNotification() - { - unset($this->webhook_notification); - } - - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when an audience list is - * ready to be used. Webhooks allow a notification to be sent to your servers - * & avoid the need for polling. - * Either one or two POST requests will be sent to the webhook. The first POST - * request will be sent immediately showing the newly created audience list in - * its CREATING state. The second POST request will be sent after the audience - * list completes creation (either the ACTIVE or FAILED state). - * If identical audience lists are requested in quick succession, the second & - * subsequent audience lists can be served from cache. In that case, the - * audience list create method can return an audience list is already ACTIVE. - * In this scenario, only one POST request will be sent to the webhook. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\WebhookNotification $var - * @return $this - */ - public function setWebhookNotification($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\WebhookNotification::class); - $this->webhook_notification = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php deleted file mode 100644 index abef9023454..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceList/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1alpha.AudienceList.State - */ -class State -{ - /** - * Unspecified state will never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The AudienceList is currently creating and will be available in the - * future. Creating occurs immediately after the CreateAudienceList call. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The AudienceList is fully created and ready for querying. An AudienceList - * is updated to active asynchronously from a request; this occurs some - * time (for example 15 minutes) after the initial create call. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * The AudienceList failed to be created. It is possible that re-requesting - * this audience list will succeed. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Analytics\Data\V1alpha\AudienceList_State::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php deleted file mode 100644 index 5c620b9dd85..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceListMetadata.php +++ /dev/null @@ -1,33 +0,0 @@ -google.analytics.data.v1alpha.AudienceListMetadata - */ -class AudienceListMetadata extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php deleted file mode 100644 index 2047788e653..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/AudienceRow.php +++ /dev/null @@ -1,71 +0,0 @@ -google.analytics.data.v1alpha.AudienceRow - */ -class AudienceRow extends \Google\Protobuf\Internal\Message -{ - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; - */ - private $dimension_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionValues() - { - return $this->dimension_values; - } - - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimensionValue dimension_values = 1; - * @param array<\Google\Analytics\Data\V1alpha\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimensionValue::class); - $this->dimension_values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php deleted file mode 100644 index 1a3c30dd571..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/BetweenFilter.php +++ /dev/null @@ -1,121 +0,0 @@ -google.analytics.data.v1alpha.BetweenFilter - */ -class BetweenFilter extends \Google\Protobuf\Internal\Message -{ - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; - */ - protected $from_value = null; - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; - */ - protected $to_value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\NumericValue $from_value - * Begins with this number. - * @type \Google\Analytics\Data\V1alpha\NumericValue $to_value - * Ends with this number. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; - * @return \Google\Analytics\Data\V1alpha\NumericValue|null - */ - public function getFromValue() - { - return $this->from_value; - } - - public function hasFromValue() - { - return isset($this->from_value); - } - - public function clearFromValue() - { - unset($this->from_value); - } - - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue from_value = 1; - * @param \Google\Analytics\Data\V1alpha\NumericValue $var - * @return $this - */ - public function setFromValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); - $this->from_value = $var; - - return $this; - } - - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; - * @return \Google\Analytics\Data\V1alpha\NumericValue|null - */ - public function getToValue() - { - return $this->to_value; - } - - public function hasToValue() - { - return isset($this->to_value); - } - - public function clearToValue() - { - unset($this->to_value); - } - - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue to_value = 2; - * @param \Google\Analytics\Data\V1alpha\NumericValue $var - * @return $this - */ - public function setToValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); - $this->to_value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php deleted file mode 100644 index ad2a39a6847..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Cohort.php +++ /dev/null @@ -1,215 +0,0 @@ -google.analytics.data.v1alpha.Cohort - */ -class Cohort extends \Google\Protobuf\Internal\Message -{ - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - */ - protected $dimension = ''; - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; - */ - protected $date_range = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * @type string $dimension - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * @type \Google\Analytics\Data\V1alpha\DateRange $date_range - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - * @return string - */ - public function getDimension() - { - return $this->dimension; - } - - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - * @param string $var - * @return $this - */ - public function setDimension($var) - { - GPBUtil::checkString($var, True); - $this->dimension = $var; - - return $this; - } - - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; - * @return \Google\Analytics\Data\V1alpha\DateRange|null - */ - public function getDateRange() - { - return $this->date_range; - } - - public function hasDateRange() - { - return isset($this->date_range); - } - - public function clearDateRange() - { - unset($this->date_range); - } - - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DateRange date_range = 3; - * @param \Google\Analytics\Data\V1alpha\DateRange $var - * @return $this - */ - public function setDateRange($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DateRange::class); - $this->date_range = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php deleted file mode 100644 index 4364a0b9c5a..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortReportSettings.php +++ /dev/null @@ -1,71 +0,0 @@ -google.analytics.data.v1alpha.CohortReportSettings - */ -class CohortReportSettings extends \Google\Protobuf\Internal\Message -{ - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - */ - protected $accumulate = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $accumulate - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - * @return bool - */ - public function getAccumulate() - { - return $this->accumulate; - } - - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - * @param bool $var - * @return $this - */ - public function setAccumulate($var) - { - GPBUtil::checkBool($var); - $this->accumulate = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php deleted file mode 100644 index 6de328bb2e3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortSpec.php +++ /dev/null @@ -1,179 +0,0 @@ -google.analytics.data.v1alpha.CohortSpec - */ -class CohortSpec extends \Google\Protobuf\Internal\Message -{ - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; - */ - private $cohorts; - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; - */ - protected $cohorts_range = null; - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; - */ - protected $cohort_report_settings = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $cohorts - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * @type \Google\Analytics\Data\V1alpha\CohortsRange $cohorts_range - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * @type \Google\Analytics\Data\V1alpha\CohortReportSettings $cohort_report_settings - * Optional settings for a cohort report. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCohorts() - { - return $this->cohorts; - } - - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Cohort cohorts = 1; - * @param array<\Google\Analytics\Data\V1alpha\Cohort>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCohorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Cohort::class); - $this->cohorts = $arr; - - return $this; - } - - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; - * @return \Google\Analytics\Data\V1alpha\CohortsRange|null - */ - public function getCohortsRange() - { - return $this->cohorts_range; - } - - public function hasCohortsRange() - { - return isset($this->cohorts_range); - } - - public function clearCohortsRange() - { - unset($this->cohorts_range); - } - - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange cohorts_range = 2; - * @param \Google\Analytics\Data\V1alpha\CohortsRange $var - * @return $this - */ - public function setCohortsRange($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\CohortsRange::class); - $this->cohorts_range = $var; - - return $this; - } - - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; - * @return \Google\Analytics\Data\V1alpha\CohortReportSettings|null - */ - public function getCohortReportSettings() - { - return $this->cohort_report_settings; - } - - public function hasCohortReportSettings() - { - return isset($this->cohort_report_settings); - } - - public function clearCohortReportSettings() - { - unset($this->cohort_report_settings); - } - - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortReportSettings cohort_report_settings = 3; - * @param \Google\Analytics\Data\V1alpha\CohortReportSettings $var - * @return $this - */ - public function setCohortReportSettings($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\CohortReportSettings::class); - $this->cohort_report_settings = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php deleted file mode 100644 index 3133c9ca748..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange.php +++ /dev/null @@ -1,208 +0,0 @@ -google.analytics.data.v1alpha.CohortsRange - */ -class CohortsRange extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; - */ - protected $granularity = 0; - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - */ - protected $start_offset = 0; - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - */ - protected $end_offset = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $granularity - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * @type int $start_offset - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * @type int $end_offset - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; - * @return int - */ - public function getGranularity() - { - return $this->granularity; - } - - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.CohortsRange.Granularity granularity = 1; - * @param int $var - * @return $this - */ - public function setGranularity($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\CohortsRange\Granularity::class); - $this->granularity = $var; - - return $this; - } - - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - * @return int - */ - public function getStartOffset() - { - return $this->start_offset; - } - - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - * @param int $var - * @return $this - */ - public function setStartOffset($var) - { - GPBUtil::checkInt32($var); - $this->start_offset = $var; - - return $this; - } - - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - * @return int - */ - public function getEndOffset() - { - return $this->end_offset; - } - - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - * @param int $var - * @return $this - */ - public function setEndOffset($var) - { - GPBUtil::checkInt32($var); - $this->end_offset = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php deleted file mode 100644 index d5c75924d4b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CohortsRange/Granularity.php +++ /dev/null @@ -1,76 +0,0 @@ -google.analytics.data.v1alpha.CohortsRange.Granularity - */ -class Granularity -{ - /** - * Should never be specified. - * - * Generated from protobuf enum GRANULARITY_UNSPECIFIED = 0; - */ - const GRANULARITY_UNSPECIFIED = 0; - /** - * Daily granularity. Commonly used if the cohort's `dateRange` is a single - * day and the request contains `cohortNthDay`. - * - * Generated from protobuf enum DAILY = 1; - */ - const DAILY = 1; - /** - * Weekly granularity. Commonly used if the cohort's `dateRange` is a week - * in duration (starting on Sunday and ending on Saturday) and the request - * contains `cohortNthWeek`. - * - * Generated from protobuf enum WEEKLY = 2; - */ - const WEEKLY = 2; - /** - * Monthly granularity. Commonly used if the cohort's `dateRange` is a month - * in duration and the request contains `cohortNthMonth`. - * - * Generated from protobuf enum MONTHLY = 3; - */ - const MONTHLY = 3; - - private static $valueToName = [ - self::GRANULARITY_UNSPECIFIED => 'GRANULARITY_UNSPECIFIED', - self::DAILY => 'DAILY', - self::WEEKLY => 'WEEKLY', - self::MONTHLY => 'MONTHLY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Granularity::class, \Google\Analytics\Data\V1alpha\CohortsRange_Granularity::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php deleted file mode 100644 index 3f2845a201c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateAudienceListRequest.php +++ /dev/null @@ -1,132 +0,0 @@ -google.analytics.data.v1alpha.CreateAudienceListRequest - */ -class CreateAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $audience_list = null; - - /** - * @param string $parent Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. - * @param \Google\Analytics\Data\V1alpha\AudienceList $audienceList Required. The audience list to create. - * - * @return \Google\Analytics\Data\V1alpha\CreateAudienceListRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Analytics\Data\V1alpha\AudienceList $audienceList): self - { - return (new self()) - ->setParent($parent) - ->setAudienceList($audienceList); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list - * Required. The audience list to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Analytics\Data\V1alpha\AudienceList|null - */ - public function getAudienceList() - { - return $this->audience_list; - } - - public function hasAudienceList() - { - return isset($this->audience_list); - } - - public function clearAudienceList() - { - unset($this->audience_list); - } - - /** - * Required. The audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.AudienceList audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Analytics\Data\V1alpha\AudienceList $var - * @return $this - */ - public function setAudienceList($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); - $this->audience_list = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php deleted file mode 100644 index 597ed8af253..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/CreateRecurringAudienceListRequest.php +++ /dev/null @@ -1,132 +0,0 @@ -google.analytics.data.v1alpha.CreateRecurringAudienceListRequest - */ -class CreateRecurringAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The recurring audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $recurring_audience_list = null; - - /** - * @param string $parent Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. - * @param \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurringAudienceList Required. The recurring audience list to create. - * - * @return \Google\Analytics\Data\V1alpha\CreateRecurringAudienceListRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurringAudienceList): self - { - return (new self()) - ->setParent($parent) - ->setRecurringAudienceList($recurringAudienceList); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * @type \Google\Analytics\Data\V1alpha\RecurringAudienceList $recurring_audience_list - * Required. The recurring audience list to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The recurring audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList|null - */ - public function getRecurringAudienceList() - { - return $this->recurring_audience_list; - } - - public function hasRecurringAudienceList() - { - return isset($this->recurring_audience_list); - } - - public function clearRecurringAudienceList() - { - unset($this->recurring_audience_list); - } - - /** - * Required. The recurring audience list to create. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_list = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Analytics\Data\V1alpha\RecurringAudienceList $var - * @return $this - */ - public function setRecurringAudienceList($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\RecurringAudienceList::class); - $this->recurring_audience_list = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php deleted file mode 100644 index 0d7a4291b97..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DateRange.php +++ /dev/null @@ -1,172 +0,0 @@ -google.analytics.data.v1alpha.DateRange - */ -class DateRange extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - */ - protected $start_date = ''; - /** - * 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. - * - * Generated from protobuf field string end_date = 2; - */ - protected $end_date = ''; - /** - * 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. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $start_date - * 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. - * @type string $end_date - * 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. - * @type string $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - * @return string - */ - public function getStartDate() - { - return $this->start_date; - } - - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - * @param string $var - * @return $this - */ - public function setStartDate($var) - { - GPBUtil::checkString($var, True); - $this->start_date = $var; - - 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. - * - * Generated from protobuf field string end_date = 2; - * @return string - */ - public function getEndDate() - { - return $this->end_date; - } - - /** - * 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. - * - * Generated from protobuf field string end_date = 2; - * @param string $var - * @return $this - */ - public function setEndDate($var) - { - GPBUtil::checkString($var, True); - $this->end_date = $var; - - 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. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->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. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php deleted file mode 100644 index b1deaf99406..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Dimension.php +++ /dev/null @@ -1,189 +0,0 @@ -google.analytics.data.v1alpha.Dimension - */ -class Dimension extends \Google\Protobuf\Internal\Message -{ - /** - * 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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; - */ - protected $dimension_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * @type \Google\Analytics\Data\V1alpha\DimensionExpression $dimension_expression - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; - * @return \Google\Analytics\Data\V1alpha\DimensionExpression|null - */ - public function getDimensionExpression() - { - return $this->dimension_expression; - } - - public function hasDimensionExpression() - { - return isset($this->dimension_expression); - } - - public function clearDimensionExpression() - { - unset($this->dimension_expression); - } - - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression dimension_expression = 2; - * @param \Google\Analytics\Data\V1alpha\DimensionExpression $var - * @return $this - */ - public function setDimensionExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression::class); - $this->dimension_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php deleted file mode 100644 index 95d5d64ceb7..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression.php +++ /dev/null @@ -1,147 +0,0 @@ -google.analytics.data.v1alpha.DimensionExpression - */ -class DimensionExpression extends \Google\Protobuf\Internal\Message -{ - protected $one_expression; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $lower_case - * Used to convert a dimension value to lower case. - * @type \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $upper_case - * Used to convert a dimension value to upper case. - * @type \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression $concatenate - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Used to convert a dimension value to lower case. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; - * @return \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression|null - */ - public function getLowerCase() - { - return $this->readOneof(4); - } - - public function hasLowerCase() - { - return $this->hasOneof(4); - } - - /** - * Used to convert a dimension value to lower case. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression lower_case = 4; - * @param \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $var - * @return $this - */ - public function setLowerCase($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Used to convert a dimension value to upper case. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; - * @return \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression|null - */ - public function getUpperCase() - { - return $this->readOneof(5); - } - - public function hasUpperCase() - { - return $this->hasOneof(5); - } - - /** - * Used to convert a dimension value to upper case. - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.CaseExpression upper_case = 5; - * @param \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression $var - * @return $this - */ - public function setUpperCase($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\CaseExpression::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; - * @return \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression|null - */ - public function getConcatenate() - { - return $this->readOneof(6); - } - - public function hasConcatenate() - { - return $this->hasOneof(6); - } - - /** - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression concatenate = 6; - * @param \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression $var - * @return $this - */ - public function setConcatenate($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\DimensionExpression\ConcatenateExpression::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneExpression() - { - return $this->whichOneof("one_expression"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php deleted file mode 100644 index da9ca59bb91..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/CaseExpression.php +++ /dev/null @@ -1,74 +0,0 @@ -google.analytics.data.v1alpha.DimensionExpression.CaseExpression - */ -class CaseExpression extends \Google\Protobuf\Internal\Message -{ - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - */ - protected $dimension_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CaseExpression::class, \Google\Analytics\Data\V1alpha\DimensionExpression_CaseExpression::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php deleted file mode 100644 index 22367f8c52d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionExpression/ConcatenateExpression.php +++ /dev/null @@ -1,128 +0,0 @@ -google.analytics.data.v1alpha.DimensionExpression.ConcatenateExpression - */ -class ConcatenateExpression extends \Google\Protobuf\Internal\Message -{ - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - */ - private $dimension_names; - /** - * 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". - * - * Generated from protobuf field string delimiter = 2; - */ - protected $delimiter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $dimension_names - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * @type string $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". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionNames() - { - return $this->dimension_names; - } - - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->dimension_names = $arr; - - 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". - * - * Generated from protobuf field string delimiter = 2; - * @return string - */ - public function getDelimiter() - { - return $this->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". - * - * Generated from protobuf field string delimiter = 2; - * @param string $var - * @return $this - */ - public function setDelimiter($var) - { - GPBUtil::checkString($var, True); - $this->delimiter = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ConcatenateExpression::class, \Google\Analytics\Data\V1alpha\DimensionExpression_ConcatenateExpression::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php deleted file mode 100644 index 3d84d708eee..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionHeader.php +++ /dev/null @@ -1,70 +0,0 @@ -google.analytics.data.v1alpha.DimensionHeader - */ -class DimensionHeader extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The dimension's name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php deleted file mode 100644 index b73fad0eaf8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/DimensionValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1alpha.DimensionValue - */ -class DimensionValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Value as a string if the dimension type is a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->readOneof(1); - } - - public function hasValue() - { - return $this->hasOneof(1); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php deleted file mode 100644 index 760528e9a04..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventCriteriaScoping.php +++ /dev/null @@ -1,56 +0,0 @@ -google.analytics.data.v1alpha.EventCriteriaScoping - */ -class EventCriteriaScoping -{ - /** - * Unspecified criteria scoping. Do not specify. - * - * Generated from protobuf enum EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; - */ - const EVENT_CRITERIA_SCOPING_UNSPECIFIED = 0; - /** - * If the criteria is satisfied within one event, the event matches the - * criteria. - * - * Generated from protobuf enum EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; - */ - const EVENT_CRITERIA_WITHIN_SAME_EVENT = 1; - - private static $valueToName = [ - self::EVENT_CRITERIA_SCOPING_UNSPECIFIED => 'EVENT_CRITERIA_SCOPING_UNSPECIFIED', - self::EVENT_CRITERIA_WITHIN_SAME_EVENT => 'EVENT_CRITERIA_WITHIN_SAME_EVENT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php deleted file mode 100644 index 9a97210c923..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventExclusionDuration.php +++ /dev/null @@ -1,56 +0,0 @@ -google.analytics.data.v1alpha.EventExclusionDuration - */ -class EventExclusionDuration -{ - /** - * Unspecified exclusion duration. Do not specify. - * - * Generated from protobuf enum EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; - */ - const EVENT_EXCLUSION_DURATION_UNSPECIFIED = 0; - /** - * Permanently exclude events from the segment if the event ever meets - * the `eventExclusionCriteria` condition. - * - * Generated from protobuf enum EVENT_EXCLUSION_PERMANENT = 1; - */ - const EVENT_EXCLUSION_PERMANENT = 1; - - private static $valueToName = [ - self::EVENT_EXCLUSION_DURATION_UNSPECIFIED => 'EVENT_EXCLUSION_DURATION_UNSPECIFIED', - self::EVENT_EXCLUSION_PERMANENT => 'EVENT_EXCLUSION_PERMANENT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php deleted file mode 100644 index 1a9340fde93..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegment.php +++ /dev/null @@ -1,123 +0,0 @@ -google.analytics.data.v1alpha.EventSegment - */ -class EventSegment extends \Google\Protobuf\Internal\Message -{ - /** - * Defines which events are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; - */ - protected $event_inclusion_criteria = null; - /** - * Defines which events are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; - */ - protected $exclusion = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\EventSegmentCriteria $event_inclusion_criteria - * Defines which events are included in this segment. Optional. - * @type \Google\Analytics\Data\V1alpha\EventSegmentExclusion $exclusion - * Defines which events are excluded in this segment. Optional. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Defines which events are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; - * @return \Google\Analytics\Data\V1alpha\EventSegmentCriteria|null - */ - public function getEventInclusionCriteria() - { - return $this->event_inclusion_criteria; - } - - public function hasEventInclusionCriteria() - { - return isset($this->event_inclusion_criteria); - } - - public function clearEventInclusionCriteria() - { - unset($this->event_inclusion_criteria); - } - - /** - * Defines which events are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_inclusion_criteria = 1; - * @param \Google\Analytics\Data\V1alpha\EventSegmentCriteria $var - * @return $this - */ - public function setEventInclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentCriteria::class); - $this->event_inclusion_criteria = $var; - - return $this; - } - - /** - * Defines which events are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; - * @return \Google\Analytics\Data\V1alpha\EventSegmentExclusion|null - */ - public function getExclusion() - { - return $this->exclusion; - } - - public function hasExclusion() - { - return isset($this->exclusion); - } - - public function clearExclusion() - { - unset($this->exclusion); - } - - /** - * Defines which events are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentExclusion exclusion = 2; - * @param \Google\Analytics\Data\V1alpha\EventSegmentExclusion $var - * @return $this - */ - public function setExclusion($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentExclusion::class); - $this->exclusion = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php deleted file mode 100644 index 6ff4974e6ae..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentConditionGroup.php +++ /dev/null @@ -1,128 +0,0 @@ -google.analytics.data.v1alpha.EventSegmentConditionGroup - */ -class EventSegmentConditionGroup extends \Google\Protobuf\Internal\Message -{ - /** - * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. - * Optional. If unspecified, a `conditionScoping` of - * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; - */ - protected $condition_scoping = 0; - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - */ - protected $segment_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $condition_scoping - * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. - * Optional. If unspecified, a `conditionScoping` of - * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. - * Optional. If unspecified, a `conditionScoping` of - * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; - * @return int - */ - public function getConditionScoping() - { - return $this->condition_scoping; - } - - /** - * `conditionScoping` should always be `EVENT_CRITERIA_WITHIN_SAME_EVENT`. - * Optional. If unspecified, a `conditionScoping` of - * `EVENT_CRITERIA_WITHIN_SAME_EVENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventCriteriaScoping condition_scoping = 1; - * @param int $var - * @return $this - */ - public function setConditionScoping($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\EventCriteriaScoping::class); - $this->condition_scoping = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null - */ - public function getSegmentFilterExpression() - { - return $this->segment_filter_expression; - } - - public function hasSegmentFilterExpression() - { - return isset($this->segment_filter_expression); - } - - public function clearSegmentFilterExpression() - { - unset($this->segment_filter_expression); - } - - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var - * @return $this - */ - public function setSegmentFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->segment_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php deleted file mode 100644 index d0770b39d84..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentCriteria.php +++ /dev/null @@ -1,72 +0,0 @@ -google.analytics.data.v1alpha.EventSegmentCriteria - */ -class EventSegmentCriteria extends \Google\Protobuf\Internal\Message -{ - /** - * An event matches this criteria if the event matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; - */ - private $and_condition_groups; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\EventSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups - * An event matches this criteria if the event matches each of these - * `andConditionGroups`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * An event matches this criteria if the event matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAndConditionGroups() - { - return $this->and_condition_groups; - } - - /** - * An event matches this criteria if the event matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.EventSegmentConditionGroup and_condition_groups = 1; - * @param array<\Google\Analytics\Data\V1alpha\EventSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAndConditionGroups($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\EventSegmentConditionGroup::class); - $this->and_condition_groups = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php deleted file mode 100644 index 8c4db8412dd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/EventSegmentExclusion.php +++ /dev/null @@ -1,123 +0,0 @@ -google.analytics.data.v1alpha.EventSegmentExclusion - */ -class EventSegmentExclusion extends \Google\Protobuf\Internal\Message -{ - /** - * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. - * Optional. If unspecified, an `eventExclusionDuration` of - * `EVENT_EXCLUSION_PERMANENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; - */ - protected $event_exclusion_duration = 0; - /** - * If an event meets this condition, the event is excluded from membership - * in the segment for the `eventExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; - */ - protected $event_exclusion_criteria = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $event_exclusion_duration - * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. - * Optional. If unspecified, an `eventExclusionDuration` of - * `EVENT_EXCLUSION_PERMANENT` is used. - * @type \Google\Analytics\Data\V1alpha\EventSegmentCriteria $event_exclusion_criteria - * If an event meets this condition, the event is excluded from membership - * in the segment for the `eventExclusionDuration`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. - * Optional. If unspecified, an `eventExclusionDuration` of - * `EVENT_EXCLUSION_PERMANENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; - * @return int - */ - public function getEventExclusionDuration() - { - return $this->event_exclusion_duration; - } - - /** - * `eventExclusionDuration` should always be `PERMANENTLY_EXCLUDE`. - * Optional. If unspecified, an `eventExclusionDuration` of - * `EVENT_EXCLUSION_PERMANENT` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventExclusionDuration event_exclusion_duration = 1; - * @param int $var - * @return $this - */ - public function setEventExclusionDuration($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\EventExclusionDuration::class); - $this->event_exclusion_duration = $var; - - return $this; - } - - /** - * If an event meets this condition, the event is excluded from membership - * in the segment for the `eventExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; - * @return \Google\Analytics\Data\V1alpha\EventSegmentCriteria|null - */ - public function getEventExclusionCriteria() - { - return $this->event_exclusion_criteria; - } - - public function hasEventExclusionCriteria() - { - return isset($this->event_exclusion_criteria); - } - - public function clearEventExclusionCriteria() - { - unset($this->event_exclusion_criteria); - } - - /** - * If an event meets this condition, the event is excluded from membership - * in the segment for the `eventExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegmentCriteria event_exclusion_criteria = 2; - * @param \Google\Analytics\Data\V1alpha\EventSegmentCriteria $var - * @return $this - */ - public function setEventExclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegmentCriteria::class); - $this->event_exclusion_criteria = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php deleted file mode 100644 index 1a4a786517f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Filter.php +++ /dev/null @@ -1,212 +0,0 @@ -google.analytics.data.v1alpha.Filter - */ -class Filter extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension name or metric name. Must be a name defined in dimensions - * or metrics. - * - * Generated from protobuf field string field_name = 1; - */ - protected $field_name = ''; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field_name - * The dimension name or metric name. Must be a name defined in dimensions - * or metrics. - * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter - * A filter for between two values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension name or metric name. Must be a name defined in dimensions - * or metrics. - * - * Generated from protobuf field string field_name = 1; - * @return string - */ - public function getFieldName() - { - return $this->field_name; - } - - /** - * The dimension name or metric name. Must be a name defined in dimensions - * or metrics. - * - * Generated from protobuf field string field_name = 1; - * @param string $var - * @return $this - */ - public function setFieldName($var) - { - GPBUtil::checkString($var, True); - $this->field_name = $var; - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 2; - * @return \Google\Analytics\Data\V1alpha\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(2); - } - - public function hasStringFilter() - { - return $this->hasOneof(2); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 2; - * @param \Google\Analytics\Data\V1alpha\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; - * @return \Google\Analytics\Data\V1alpha\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(3); - } - - public function hasInListFilter() - { - return $this->hasOneof(3); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 3; - * @param \Google\Analytics\Data\V1alpha\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; - * @return \Google\Analytics\Data\V1alpha\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(4); - } - - public function hasNumericFilter() - { - return $this->hasOneof(4); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 4; - * @param \Google\Analytics\Data\V1alpha\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; - * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(5); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 5; - * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php deleted file mode 100644 index 16c59dd4950..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpression.php +++ /dev/null @@ -1,178 +0,0 @@ -google.analytics.data.v1alpha.FilterExpression - */ -class FilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\FilterExpressionList $and_group - * The FilterExpressions in and_group have an AND relationship. - * @type \Google\Analytics\Data\V1alpha\FilterExpressionList $or_group - * The FilterExpressions in or_group have an OR relationship. - * @type \Google\Analytics\Data\V1alpha\FilterExpression $not_expression - * The FilterExpression is NOT of not_expression. - * @type \Google\Analytics\Data\V1alpha\Filter $filter - * A primitive filter. In the same FilterExpression, all of the filter's - * field names need to be either all dimensions or all metrics. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The FilterExpressions in and_group have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1alpha\FilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The FilterExpressions in and_group have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1alpha\FilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The FilterExpressions in or_group have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1alpha\FilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The FilterExpressions in or_group have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1alpha\FilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The FilterExpression is NOT of not_expression. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1alpha\FilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The FilterExpression is NOT of not_expression. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1alpha\FilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); - $this->writeOneof(3, $var); - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Filter filter = 4; - * @return \Google\Analytics\Data\V1alpha\Filter|null - */ - public function getFilter() - { - return $this->readOneof(4); - } - - public function hasFilter() - { - return $this->hasOneof(4); - } - - /** - * A primitive filter. In the same FilterExpression, all of the filter's - * field names need to be either all dimensions or all metrics. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Filter filter = 4; - * @param \Google\Analytics\Data\V1alpha\Filter $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Filter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php deleted file mode 100644 index d570c1b614d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.FilterExpressionList - */ -class FilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * A list of filter expressions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1alpha\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php deleted file mode 100644 index 44df64bb900..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Funnel.php +++ /dev/null @@ -1,115 +0,0 @@ -google.analytics.data.v1alpha.Funnel - */ -class Funnel extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field bool is_open_funnel = 1; - */ - protected $is_open_funnel = false; - /** - * The sequential steps of this funnel. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; - */ - private $steps; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $is_open_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. - * @type array<\Google\Analytics\Data\V1alpha\FunnelStep>|\Google\Protobuf\Internal\RepeatedField $steps - * The sequential steps of this funnel. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field bool is_open_funnel = 1; - * @return bool - */ - public function getIsOpenFunnel() - { - return $this->is_open_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. - * - * Generated from protobuf field bool is_open_funnel = 1; - * @param bool $var - * @return $this - */ - public function setIsOpenFunnel($var) - { - GPBUtil::checkBool($var); - $this->is_open_funnel = $var; - - return $this; - } - - /** - * The sequential steps of this funnel. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSteps() - { - return $this->steps; - } - - /** - * The sequential steps of this funnel. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelStep steps = 2; - * @param array<\Google\Analytics\Data\V1alpha\FunnelStep>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSteps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelStep::class); - $this->steps = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php deleted file mode 100644 index 0500c7956bd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelBreakdown.php +++ /dev/null @@ -1,137 +0,0 @@ -google.analytics.data.v1alpha.FunnelBreakdown - */ -class FunnelBreakdown extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; - */ - protected $breakdown_dimension = null; - /** - * 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. - * - * Generated from protobuf field optional int64 limit = 2; - */ - protected $limit = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\Dimension $breakdown_dimension - * 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. - * @type int|string $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; - * @return \Google\Analytics\Data\V1alpha\Dimension|null - */ - public function getBreakdownDimension() - { - return $this->breakdown_dimension; - } - - public function hasBreakdownDimension() - { - return isset($this->breakdown_dimension); - } - - public function clearBreakdownDimension() - { - unset($this->breakdown_dimension); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension breakdown_dimension = 1; - * @param \Google\Analytics\Data\V1alpha\Dimension $var - * @return $this - */ - public function setBreakdownDimension($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Dimension::class); - $this->breakdown_dimension = $var; - - 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. - * - * Generated from protobuf field optional int64 limit = 2; - * @return int|string - */ - public function getLimit() - { - return isset($this->limit) ? $this->limit : 0; - } - - public function hasLimit() - { - return isset($this->limit); - } - - public function clearLimit() - { - unset($this->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. - * - * Generated from protobuf field optional int64 limit = 2; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php deleted file mode 100644 index bd0a9458b38..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelEventFilter.php +++ /dev/null @@ -1,140 +0,0 @@ -google.analytics.data.v1alpha.FunnelEventFilter - */ -class FunnelEventFilter extends \Google\Protobuf\Internal\Message -{ - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - */ - protected $event_name = null; - /** - * 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; - */ - protected $funnel_parameter_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $event_name - * This filter matches events of this single event name. Event name is - * required. - * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $funnel_parameter_filter_expression - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - * @return string - */ - public function getEventName() - { - return isset($this->event_name) ? $this->event_name : ''; - } - - public function hasEventName() - { - return isset($this->event_name); - } - - public function clearEventName() - { - unset($this->event_name); - } - - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - * @param string $var - * @return $this - */ - public function setEventName($var) - { - GPBUtil::checkString($var, True); - $this->event_name = $var; - - 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; - * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression|null - */ - public function getFunnelParameterFilterExpression() - { - return $this->funnel_parameter_filter_expression; - } - - public function hasFunnelParameterFilterExpression() - { - return isset($this->funnel_parameter_filter_expression); - } - - public function clearFunnelParameterFilterExpression() - { - unset($this->funnel_parameter_filter_expression); - } - - /** - * 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.FunnelParameterFilterExpression funnel_parameter_filter_expression = 2; - * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $var - * @return $this - */ - public function setFunnelParameterFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); - $this->funnel_parameter_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php deleted file mode 100644 index 2b3cf703f56..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFieldFilter.php +++ /dev/null @@ -1,208 +0,0 @@ -google.analytics.data.v1alpha.FunnelFieldFilter - */ -class FunnelFieldFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - */ - protected $field_name = ''; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field_name - * The dimension name or metric name. - * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter - * A filter for between two values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - * @return string - */ - public function getFieldName() - { - return $this->field_name; - } - - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - * @param string $var - * @return $this - */ - public function setFieldName($var) - { - GPBUtil::checkString($var, True); - $this->field_name = $var; - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @return \Google\Analytics\Data\V1alpha\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(4); - } - - public function hasStringFilter() - { - return $this->hasOneof(4); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @param \Google\Analytics\Data\V1alpha\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @return \Google\Analytics\Data\V1alpha\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(5); - } - - public function hasInListFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @param \Google\Analytics\Data\V1alpha\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @return \Google\Analytics\Data\V1alpha\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(6); - } - - public function hasNumericFilter() - { - return $this->hasOneof(6); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @param \Google\Analytics\Data\V1alpha\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(7); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(7); - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php deleted file mode 100644 index 0bd5a29dcb3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpression.php +++ /dev/null @@ -1,216 +0,0 @@ -google.analytics.data.v1alpha.FunnelFilterExpression - */ -class FunnelFilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $and_group - * The FunnelFilterExpression in `andGroup` have an AND relationship. - * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $or_group - * The FunnelFilterExpression in `orGroup` have an OR relationship. - * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpression $not_expression - * The FunnelFilterExpression is NOT of `notExpression`. - * @type \Google\Analytics\Data\V1alpha\FunnelFieldFilter $funnel_field_filter - * A funnel filter for a dimension or metric. - * @type \Google\Analytics\Data\V1alpha\FunnelEventFilter $funnel_event_filter - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The FunnelFilterExpression in `andGroup` have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The FunnelFilterExpression in `andGroup` have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The FunnelFilterExpression in `orGroup` have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The FunnelFilterExpression in `orGroup` have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The FunnelFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The FunnelFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A funnel filter for a dimension or metric. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFieldFilter funnel_field_filter = 4; - * @return \Google\Analytics\Data\V1alpha\FunnelFieldFilter|null - */ - public function getFunnelFieldFilter() - { - return $this->readOneof(4); - } - - public function hasFunnelFieldFilter() - { - return $this->hasOneof(4); - } - - /** - * A funnel filter for a dimension or metric. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFieldFilter funnel_field_filter = 4; - * @param \Google\Analytics\Data\V1alpha\FunnelFieldFilter $var - * @return $this - */ - public function setFunnelFieldFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFieldFilter::class); - $this->writeOneof(4, $var); - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; - * @return \Google\Analytics\Data\V1alpha\FunnelEventFilter|null - */ - public function getFunnelEventFilter() - { - return $this->readOneof(5); - } - - public function hasFunnelEventFilter() - { - return $this->hasOneof(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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelEventFilter funnel_event_filter = 5; - * @param \Google\Analytics\Data\V1alpha\FunnelEventFilter $var - * @return $this - */ - public function setFunnelEventFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelEventFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php deleted file mode 100644 index 5e3753f3b65..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelFilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.FunnelFilterExpressionList - */ -class FunnelFilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * The list of funnel filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\FunnelFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * The list of funnel filter expressions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of funnel filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * The list of funnel filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelFilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1alpha\FunnelFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php deleted file mode 100644 index 0292b72b3d9..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelNextAction.php +++ /dev/null @@ -1,154 +0,0 @@ -google.analytics.data.v1alpha.FunnelNextAction - */ -class FunnelNextAction extends \Google\Protobuf\Internal\Message -{ - /** - * 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 `eventName` and most Page / - * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` - * cannot be a dimension expression. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; - */ - protected $next_action_dimension = null; - /** - * 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. - * - * Generated from protobuf field optional int64 limit = 2; - */ - protected $limit = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\Dimension $next_action_dimension - * 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 `eventName` and most Page / - * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` - * cannot be a dimension expression. - * @type int|string $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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 `eventName` and most Page / - * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` - * cannot be a dimension expression. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; - * @return \Google\Analytics\Data\V1alpha\Dimension|null - */ - public function getNextActionDimension() - { - return $this->next_action_dimension; - } - - public function hasNextActionDimension() - { - return isset($this->next_action_dimension); - } - - public function clearNextActionDimension() - { - unset($this->next_action_dimension); - } - - /** - * 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 `eventName` and most Page / - * Screen dimensions like `pageTitle` and `pagePath`. `nextActionDimension` - * cannot be a dimension expression. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Dimension next_action_dimension = 1; - * @param \Google\Analytics\Data\V1alpha\Dimension $var - * @return $this - */ - public function setNextActionDimension($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Dimension::class); - $this->next_action_dimension = $var; - - 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. - * - * Generated from protobuf field optional int64 limit = 2; - * @return int|string - */ - public function getLimit() - { - return isset($this->limit) ? $this->limit : 0; - } - - public function hasLimit() - { - return isset($this->limit); - } - - public function clearLimit() - { - unset($this->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. - * - * Generated from protobuf field optional int64 limit = 2; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php deleted file mode 100644 index 154ec61a260..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilter.php +++ /dev/null @@ -1,291 +0,0 @@ -google.analytics.data.v1alpha.FunnelParameterFilter - */ -class FunnelParameterFilter extends \Google\Protobuf\Internal\Message -{ - protected $one_parameter; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $event_parameter_name - * 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. - * @type string $item_parameter_name - * 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. - * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter - * A filter for between two values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field string event_parameter_name = 1; - * @return string - */ - public function getEventParameterName() - { - return $this->readOneof(1); - } - - public function hasEventParameterName() - { - return $this->hasOneof(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. - * - * Generated from protobuf field string event_parameter_name = 1; - * @param string $var - * @return $this - */ - public function setEventParameterName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - 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. - * - * Generated from protobuf field string item_parameter_name = 2; - * @return string - */ - public function getItemParameterName() - { - return $this->readOneof(2); - } - - public function hasItemParameterName() - { - return $this->hasOneof(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. - * - * Generated from protobuf field string item_parameter_name = 2; - * @param string $var - * @return $this - */ - public function setItemParameterName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @return \Google\Analytics\Data\V1alpha\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(4); - } - - public function hasStringFilter() - { - return $this->hasOneof(4); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @param \Google\Analytics\Data\V1alpha\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @return \Google\Analytics\Data\V1alpha\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(5); - } - - public function hasInListFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @param \Google\Analytics\Data\V1alpha\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @return \Google\Analytics\Data\V1alpha\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(6); - } - - public function hasNumericFilter() - { - return $this->hasOneof(6); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @param \Google\Analytics\Data\V1alpha\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(7); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(7); - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneParameter() - { - return $this->whichOneof("one_parameter"); - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php deleted file mode 100644 index dfc32d8c01a..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpression.php +++ /dev/null @@ -1,180 +0,0 @@ -google.analytics.data.v1alpha.FunnelParameterFilterExpression - */ -class FunnelParameterFilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $and_group - * The FunnelParameterFilterExpression in `andGroup` have an AND - * relationship. - * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $or_group - * The FunnelParameterFilterExpression in `orGroup` have an OR - * relationship. - * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $not_expression - * The FunnelParameterFilterExpression is NOT of `notExpression`. - * @type \Google\Analytics\Data\V1alpha\FunnelParameterFilter $funnel_parameter_filter - * A primitive funnel parameter filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The FunnelParameterFilterExpression in `andGroup` have an AND - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The FunnelParameterFilterExpression in `andGroup` have an AND - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The FunnelParameterFilterExpression in `orGroup` have an OR - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The FunnelParameterFilterExpression in `orGroup` have an OR - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The FunnelParameterFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The FunnelParameterFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A primitive funnel parameter filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; - * @return \Google\Analytics\Data\V1alpha\FunnelParameterFilter|null - */ - public function getFunnelParameterFilter() - { - return $this->readOneof(4); - } - - public function hasFunnelParameterFilter() - { - return $this->hasOneof(4); - } - - /** - * A primitive funnel parameter filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelParameterFilter funnel_parameter_filter = 4; - * @param \Google\Analytics\Data\V1alpha\FunnelParameterFilter $var - * @return $this - */ - public function setFunnelParameterFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelParameterFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php deleted file mode 100644 index 4ef706a4067..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelParameterFilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.FunnelParameterFilterExpressionList - */ -class FunnelParameterFilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * The list of funnel parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * The list of funnel parameter filter expressions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of funnel parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * The list of funnel parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.FunnelParameterFilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\FunnelParameterFilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php deleted file mode 100644 index 78714d6506c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelResponseMetadata.php +++ /dev/null @@ -1,92 +0,0 @@ -google.analytics.data.v1alpha.FunnelResponseMetadata - */ -class FunnelResponseMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * If funnel report results are - * [sampled](https://support.google.com/analytics/answer/13331292), 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; - */ - private $sampling_metadatas; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $sampling_metadatas - * If funnel report results are - * [sampled](https://support.google.com/analytics/answer/13331292), 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * If funnel report results are - * [sampled](https://support.google.com/analytics/answer/13331292), 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSamplingMetadatas() - { - return $this->sampling_metadatas; - } - - /** - * If funnel report results are - * [sampled](https://support.google.com/analytics/answer/13331292), 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SamplingMetadata sampling_metadatas = 1; - * @param array<\Google\Analytics\Data\V1alpha\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSamplingMetadatas($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SamplingMetadata::class); - $this->sampling_metadatas = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php deleted file mode 100644 index bdb78764bf0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelStep.php +++ /dev/null @@ -1,243 +0,0 @@ -google.analytics.data.v1alpha.FunnelStep - */ -class FunnelStep extends \Google\Protobuf\Internal\Message -{ - /** - * The distinctive name for this step. If unspecified, steps will be named - * by a 1 based indexed name (for example "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. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * 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. - * - * Generated from protobuf field bool is_directly_followed_by = 2; - */ - protected $is_directly_followed_by = false; - /** - * 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. - * - * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; - */ - protected $within_duration_from_prior_step = null; - /** - * The condition that your users must meet to be included in this step of - * the funnel journey. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; - */ - protected $filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The distinctive name for this step. If unspecified, steps will be named - * by a 1 based indexed name (for example "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. - * @type bool $is_directly_followed_by - * 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. - * @type \Google\Protobuf\Duration $within_duration_from_prior_step - * 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. - * @type \Google\Analytics\Data\V1alpha\FunnelFilterExpression $filter_expression - * The condition that your users must meet to be included in this step of - * the funnel journey. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The distinctive name for this step. If unspecified, steps will be named - * by a 1 based indexed name (for example "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. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The distinctive name for this step. If unspecified, steps will be named - * by a 1 based indexed name (for example "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. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - 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. - * - * Generated from protobuf field bool is_directly_followed_by = 2; - * @return bool - */ - public function getIsDirectlyFollowedBy() - { - return $this->is_directly_followed_by; - } - - /** - * 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. - * - * Generated from protobuf field bool is_directly_followed_by = 2; - * @param bool $var - * @return $this - */ - public function setIsDirectlyFollowedBy($var) - { - GPBUtil::checkBool($var); - $this->is_directly_followed_by = $var; - - 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. - * - * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; - * @return \Google\Protobuf\Duration|null - */ - public function getWithinDurationFromPriorStep() - { - return $this->within_duration_from_prior_step; - } - - public function hasWithinDurationFromPriorStep() - { - return isset($this->within_duration_from_prior_step); - } - - public function clearWithinDurationFromPriorStep() - { - unset($this->within_duration_from_prior_step); - } - - /** - * 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. - * - * Generated from protobuf field optional .google.protobuf.Duration within_duration_from_prior_step = 3; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setWithinDurationFromPriorStep($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->within_duration_from_prior_step = $var; - - return $this; - } - - /** - * The condition that your users must meet to be included in this step of - * the funnel journey. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; - * @return \Google\Analytics\Data\V1alpha\FunnelFilterExpression|null - */ - public function getFilterExpression() - { - return $this->filter_expression; - } - - public function hasFilterExpression() - { - return isset($this->filter_expression); - } - - public function clearFilterExpression() - { - unset($this->filter_expression); - } - - /** - * The condition that your users must meet to be included in this step of - * the funnel journey. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelFilterExpression filter_expression = 4; - * @param \Google\Analytics\Data\V1alpha\FunnelFilterExpression $var - * @return $this - */ - public function setFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelFilterExpression::class); - $this->filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php deleted file mode 100644 index 917e5746235..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/FunnelSubReport.php +++ /dev/null @@ -1,196 +0,0 @@ -google.analytics.data.v1alpha.FunnelSubReport - */ -class FunnelSubReport extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; - */ - private $dimension_headers; - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; - */ - private $metric_headers; - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; - */ - private $rows; - /** - * Metadata for the funnel report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers - * 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. - * @type array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers - * 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. - * @type array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $rows - * Rows of dimension value combinations and metric values in the report. - * @type \Google\Analytics\Data\V1alpha\FunnelResponseMetadata $metadata - * Metadata for the funnel report. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionHeaders() - { - return $this->dimension_headers; - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionHeader dimension_headers = 1; - * @param array<\Google\Analytics\Data\V1alpha\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DimensionHeader::class); - $this->dimension_headers = $arr; - - 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricHeaders() - { - return $this->metric_headers; - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricHeader metric_headers = 2; - * @param array<\Google\Analytics\Data\V1alpha\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\MetricHeader::class); - $this->metric_headers = $arr; - - return $this; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRows() - { - return $this->rows; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Row rows = 3; - * @param array<\Google\Analytics\Data\V1alpha\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Row::class); - $this->rows = $arr; - - return $this; - } - - /** - * Metadata for the funnel report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; - * @return \Google\Analytics\Data\V1alpha\FunnelResponseMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata for the funnel report. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelResponseMetadata metadata = 4; - * @param \Google\Analytics\Data\V1alpha\FunnelResponseMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelResponseMetadata::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php deleted file mode 100644 index b0b4e994fe0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetAudienceListRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.analytics.data.v1alpha.GetAudienceListRequest - */ -class GetAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * Please see {@see AlphaAnalyticsDataClient::audienceListName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1alpha\GetAudienceListRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php deleted file mode 100644 index 62483c22faa..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/GetRecurringAudienceListRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.analytics.data.v1alpha.GetRecurringAudienceListRequest - */ -class GetRecurringAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * Please see {@see AlphaAnalyticsDataClient::recurringAudienceListName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1alpha\GetRecurringAudienceListRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php deleted file mode 100644 index 6a21d6edf15..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/InListFilter.php +++ /dev/null @@ -1,105 +0,0 @@ -google.analytics.data.v1alpha.InListFilter - */ -class InListFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - */ - private $values; - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - */ - protected $case_sensitive = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $values - * The list of string values. - * Must be non-empty. - * @type bool $case_sensitive - * If true, the string value is case sensitive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getValues() - { - return $this->values; - } - - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->values = $arr; - - return $this; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - * @return bool - */ - public function getCaseSensitive() - { - return $this->case_sensitive; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php deleted file mode 100644 index f5a915fcf45..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsRequest.php +++ /dev/null @@ -1,178 +0,0 @@ -google.analytics.data.v1alpha.ListAudienceListsRequest - */ -class ListAudienceListsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of audience lists to return. The service may - * return fewer than this value. If unspecified, at most 200 audience lists - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A page token, received from a previous `ListAudienceLists` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceLists` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1alpha\ListAudienceListsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * @type int $page_size - * Optional. The maximum number of audience lists to return. The service may - * return fewer than this value. If unspecified, at most 200 audience lists - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * @type string $page_token - * Optional. A page token, received from a previous `ListAudienceLists` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceLists` must - * match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of audience lists to return. The service may - * return fewer than this value. If unspecified, at most 200 audience lists - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of audience lists to return. The service may - * return fewer than this value. If unspecified, at most 200 audience lists - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A page token, received from a previous `ListAudienceLists` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceLists` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A page token, received from a previous `ListAudienceLists` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceLists` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php deleted file mode 100644 index af435a8bb38..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListAudienceListsResponse.php +++ /dev/null @@ -1,115 +0,0 @@ -google.analytics.data.v1alpha.ListAudienceListsResponse - */ -class ListAudienceListsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Each audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; - */ - private $audience_lists; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - */ - protected $next_page_token = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\AudienceList>|\Google\Protobuf\Internal\RepeatedField $audience_lists - * Each audience list for a property. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Each audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAudienceLists() - { - return $this->audience_lists; - } - - /** - * Each audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceList audience_lists = 1; - * @param array<\Google\Analytics\Data\V1alpha\AudienceList>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAudienceLists($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceList::class); - $this->audience_lists = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return isset($this->next_page_token) ? $this->next_page_token : ''; - } - - public function hasNextPageToken() - { - return isset($this->next_page_token); - } - - public function clearNextPageToken() - { - unset($this->next_page_token); - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php deleted file mode 100644 index c0ce897dbad..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsRequest.php +++ /dev/null @@ -1,186 +0,0 @@ -google.analytics.data.v1alpha.ListRecurringAudienceListsRequest - */ -class ListRecurringAudienceListsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of recurring audience lists to return. The - * service may return fewer than this value. If unspecified, at most 200 - * recurring audience lists will be returned. The maximum value is 1000 - * (higher values will be coerced to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A page token, received from a previous - * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent - * page. - * When paginating, all other parameters provided to - * `ListRecurringAudienceLists` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * Please see {@see AlphaAnalyticsDataClient::propertyName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1alpha\ListRecurringAudienceListsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * @type int $page_size - * Optional. The maximum number of recurring audience lists to return. The - * service may return fewer than this value. If unspecified, at most 200 - * recurring audience lists will be returned. The maximum value is 1000 - * (higher values will be coerced to the maximum). - * @type string $page_token - * Optional. A page token, received from a previous - * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent - * page. - * When paginating, all other parameters provided to - * `ListRecurringAudienceLists` must match the call that provided the page - * token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of recurring audience lists to return. The - * service may return fewer than this value. If unspecified, at most 200 - * recurring audience lists will be returned. The maximum value is 1000 - * (higher values will be coerced to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of recurring audience lists to return. The - * service may return fewer than this value. If unspecified, at most 200 - * recurring audience lists will be returned. The maximum value is 1000 - * (higher values will be coerced to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A page token, received from a previous - * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent - * page. - * When paginating, all other parameters provided to - * `ListRecurringAudienceLists` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A page token, received from a previous - * `ListRecurringAudienceLists` call. Provide this to retrieve the subsequent - * page. - * When paginating, all other parameters provided to - * `ListRecurringAudienceLists` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php deleted file mode 100644 index 0a48186323f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ListRecurringAudienceListsResponse.php +++ /dev/null @@ -1,115 +0,0 @@ -google.analytics.data.v1alpha.ListRecurringAudienceListsResponse - */ -class ListRecurringAudienceListsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Each recurring audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; - */ - private $recurring_audience_lists; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - */ - protected $next_page_token = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\RecurringAudienceList>|\Google\Protobuf\Internal\RepeatedField $recurring_audience_lists - * Each recurring audience list for a property. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Each recurring audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRecurringAudienceLists() - { - return $this->recurring_audience_lists; - } - - /** - * Each recurring audience list for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.RecurringAudienceList recurring_audience_lists = 1; - * @param array<\Google\Analytics\Data\V1alpha\RecurringAudienceList>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRecurringAudienceLists($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\RecurringAudienceList::class); - $this->recurring_audience_lists = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return isset($this->next_page_token) ? $this->next_page_token : ''; - } - - public function hasNextPageToken() - { - return isset($this->next_page_token); - } - - public function clearNextPageToken() - { - unset($this->next_page_token); - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php deleted file mode 100644 index 87da0af9af0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Metric.php +++ /dev/null @@ -1,221 +0,0 @@ -google.analytics.data.v1alpha.Metric - */ -class Metric extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - */ - protected $expression = ''; - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - */ - protected $invisible = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * @type string $expression - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * @type bool $invisible - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - * @return string - */ - public function getExpression() - { - return $this->expression; - } - - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - * @param string $var - * @return $this - */ - public function setExpression($var) - { - GPBUtil::checkString($var, True); - $this->expression = $var; - - return $this; - } - - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - * @return bool - */ - public function getInvisible() - { - return $this->invisible; - } - - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - * @param bool $var - * @return $this - */ - public function setInvisible($var) - { - GPBUtil::checkBool($var); - $this->invisible = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php deleted file mode 100644 index 941961ccf25..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricAggregation.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1alpha.MetricAggregation - */ -class MetricAggregation -{ - /** - * Unspecified operator. - * - * Generated from protobuf enum METRIC_AGGREGATION_UNSPECIFIED = 0; - */ - const METRIC_AGGREGATION_UNSPECIFIED = 0; - /** - * SUM operator. - * - * Generated from protobuf enum TOTAL = 1; - */ - const TOTAL = 1; - /** - * Minimum operator. - * - * Generated from protobuf enum MINIMUM = 5; - */ - const MINIMUM = 5; - /** - * Maximum operator. - * - * Generated from protobuf enum MAXIMUM = 6; - */ - const MAXIMUM = 6; - /** - * Count operator. - * - * Generated from protobuf enum COUNT = 4; - */ - const COUNT = 4; - - private static $valueToName = [ - self::METRIC_AGGREGATION_UNSPECIFIED => 'METRIC_AGGREGATION_UNSPECIFIED', - self::TOTAL => 'TOTAL', - self::MINIMUM => 'MINIMUM', - self::MAXIMUM => 'MAXIMUM', - self::COUNT => 'COUNT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php deleted file mode 100644 index ed4f1ecb9a8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricHeader.php +++ /dev/null @@ -1,104 +0,0 @@ -google.analytics.data.v1alpha.MetricHeader - */ -class MetricHeader extends \Google\Protobuf\Internal\Message -{ - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The metric's name. - * @type int $type - * The metric's data type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1alpha.MetricType type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\MetricType::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php deleted file mode 100644 index 8dc85c6cf15..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricType.php +++ /dev/null @@ -1,131 +0,0 @@ -google.analytics.data.v1alpha.MetricType - */ -class MetricType -{ - /** - * Unspecified type. - * - * Generated from protobuf enum METRIC_TYPE_UNSPECIFIED = 0; - */ - const METRIC_TYPE_UNSPECIFIED = 0; - /** - * Integer type. - * - * Generated from protobuf enum TYPE_INTEGER = 1; - */ - const TYPE_INTEGER = 1; - /** - * Floating point type. - * - * Generated from protobuf enum TYPE_FLOAT = 2; - */ - const TYPE_FLOAT = 2; - /** - * A duration of seconds; a special floating point type. - * - * Generated from protobuf enum TYPE_SECONDS = 4; - */ - const TYPE_SECONDS = 4; - /** - * A duration in milliseconds; a special floating point type. - * - * Generated from protobuf enum TYPE_MILLISECONDS = 5; - */ - const TYPE_MILLISECONDS = 5; - /** - * A duration in minutes; a special floating point type. - * - * Generated from protobuf enum TYPE_MINUTES = 6; - */ - const TYPE_MINUTES = 6; - /** - * A duration in hours; a special floating point type. - * - * Generated from protobuf enum TYPE_HOURS = 7; - */ - const TYPE_HOURS = 7; - /** - * A custom metric of standard type; a special floating point type. - * - * Generated from protobuf enum TYPE_STANDARD = 8; - */ - const TYPE_STANDARD = 8; - /** - * An amount of money; a special floating point type. - * - * Generated from protobuf enum TYPE_CURRENCY = 9; - */ - const TYPE_CURRENCY = 9; - /** - * A length in feet; a special floating point type. - * - * Generated from protobuf enum TYPE_FEET = 10; - */ - const TYPE_FEET = 10; - /** - * A length in miles; a special floating point type. - * - * Generated from protobuf enum TYPE_MILES = 11; - */ - const TYPE_MILES = 11; - /** - * A length in meters; a special floating point type. - * - * Generated from protobuf enum TYPE_METERS = 12; - */ - const TYPE_METERS = 12; - /** - * A length in kilometers; a special floating point type. - * - * Generated from protobuf enum TYPE_KILOMETERS = 13; - */ - const TYPE_KILOMETERS = 13; - - private static $valueToName = [ - self::METRIC_TYPE_UNSPECIFIED => 'METRIC_TYPE_UNSPECIFIED', - self::TYPE_INTEGER => 'TYPE_INTEGER', - self::TYPE_FLOAT => 'TYPE_FLOAT', - self::TYPE_SECONDS => 'TYPE_SECONDS', - self::TYPE_MILLISECONDS => 'TYPE_MILLISECONDS', - self::TYPE_MINUTES => 'TYPE_MINUTES', - self::TYPE_HOURS => 'TYPE_HOURS', - self::TYPE_STANDARD => 'TYPE_STANDARD', - self::TYPE_CURRENCY => 'TYPE_CURRENCY', - self::TYPE_FEET => 'TYPE_FEET', - self::TYPE_MILES => 'TYPE_MILES', - self::TYPE_METERS => 'TYPE_METERS', - self::TYPE_KILOMETERS => 'TYPE_KILOMETERS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php deleted file mode 100644 index 4abe417e906..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/MetricValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1alpha.MetricValue - */ -class MetricValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Measurement value. See MetricHeader for type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Measurement value. See MetricHeader for type. - * - * Generated from protobuf field string value = 4; - * @return string - */ - public function getValue() - { - return $this->readOneof(4); - } - - public function hasValue() - { - return $this->hasOneof(4); - } - - /** - * Measurement value. See MetricHeader for type. - * - * Generated from protobuf field string value = 4; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php deleted file mode 100644 index 6a6fb83e34e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter.php +++ /dev/null @@ -1,111 +0,0 @@ -google.analytics.data.v1alpha.NumericFilter - */ -class NumericFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; - */ - protected $operation = 0; - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; - */ - protected $value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $operation - * The operation type for this filter. - * @type \Google\Analytics\Data\V1alpha\NumericValue $value - * A numeric value or a date value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; - * @return int - */ - public function getOperation() - { - return $this->operation; - } - - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter.Operation operation = 1; - * @param int $var - * @return $this - */ - public function setOperation($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\NumericFilter\Operation::class); - $this->operation = $var; - - return $this; - } - - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; - * @return \Google\Analytics\Data\V1alpha\NumericValue|null - */ - public function getValue() - { - return $this->value; - } - - public function hasValue() - { - return isset($this->value); - } - - public function clearValue() - { - unset($this->value); - } - - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericValue value = 2; - * @param \Google\Analytics\Data\V1alpha\NumericValue $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericValue::class); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php deleted file mode 100644 index 90f4da5651e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericFilter/Operation.php +++ /dev/null @@ -1,85 +0,0 @@ -google.analytics.data.v1alpha.NumericFilter.Operation - */ -class Operation -{ - /** - * Unspecified. - * - * Generated from protobuf enum OPERATION_UNSPECIFIED = 0; - */ - const OPERATION_UNSPECIFIED = 0; - /** - * Equal - * - * Generated from protobuf enum EQUAL = 1; - */ - const EQUAL = 1; - /** - * Less than - * - * Generated from protobuf enum LESS_THAN = 2; - */ - const LESS_THAN = 2; - /** - * Less than or equal - * - * Generated from protobuf enum LESS_THAN_OR_EQUAL = 3; - */ - const LESS_THAN_OR_EQUAL = 3; - /** - * Greater than - * - * Generated from protobuf enum GREATER_THAN = 4; - */ - const GREATER_THAN = 4; - /** - * Greater than or equal - * - * Generated from protobuf enum GREATER_THAN_OR_EQUAL = 5; - */ - const GREATER_THAN_OR_EQUAL = 5; - - private static $valueToName = [ - self::OPERATION_UNSPECIFIED => 'OPERATION_UNSPECIFIED', - self::EQUAL => 'EQUAL', - self::LESS_THAN => 'LESS_THAN', - self::LESS_THAN_OR_EQUAL => 'LESS_THAN_OR_EQUAL', - self::GREATER_THAN => 'GREATER_THAN', - self::GREATER_THAN_OR_EQUAL => 'GREATER_THAN_OR_EQUAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Operation::class, \Google\Analytics\Data\V1alpha\NumericFilter_Operation::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php deleted file mode 100644 index 58236fe2e88..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/NumericValue.php +++ /dev/null @@ -1,108 +0,0 @@ -google.analytics.data.v1alpha.NumericValue - */ -class NumericValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $int64_value - * Integer value - * @type float $double_value - * Double value - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Integer value - * - * Generated from protobuf field int64 int64_value = 1; - * @return int|string - */ - public function getInt64Value() - { - return $this->readOneof(1); - } - - public function hasInt64Value() - { - return $this->hasOneof(1); - } - - /** - * Integer value - * - * Generated from protobuf field int64 int64_value = 1; - * @param int|string $var - * @return $this - */ - public function setInt64Value($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Double value - * - * Generated from protobuf field double double_value = 2; - * @return float - */ - public function getDoubleValue() - { - return $this->readOneof(2); - } - - public function hasDoubleValue() - { - return $this->hasOneof(2); - } - - /** - * Double value - * - * Generated from protobuf field double double_value = 2; - * @param float $var - * @return $this - */ - public function setDoubleValue($var) - { - GPBUtil::checkDouble($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php deleted file mode 100644 index 957ad52e335..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy.php +++ /dev/null @@ -1,144 +0,0 @@ -google.analytics.data.v1alpha.OrderBy - */ -class OrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - */ - protected $desc = false; - protected $one_order_by; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy $metric - * Sorts results by a metric's values. - * @type \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy $dimension - * Sorts results by a dimension's values. - * @type bool $desc - * If true, sorts by descending order. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Sorts results by a metric's values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.MetricOrderBy metric = 1; - * @return \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy|null - */ - public function getMetric() - { - return $this->readOneof(1); - } - - public function hasMetric() - { - return $this->hasOneof(1); - } - - /** - * Sorts results by a metric's values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.MetricOrderBy metric = 1; - * @param \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy $var - * @return $this - */ - public function setMetric($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\OrderBy\MetricOrderBy::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Sorts results by a dimension's values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy dimension = 2; - * @return \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy|null - */ - public function getDimension() - { - return $this->readOneof(2); - } - - public function hasDimension() - { - return $this->hasOneof(2); - } - - /** - * Sorts results by a dimension's values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy dimension = 2; - * @param \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy $var - * @return $this - */ - public function setDimension($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - * @return bool - */ - public function getDesc() - { - return $this->desc; - } - - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - * @param bool $var - * @return $this - */ - public function setDesc($var) - { - GPBUtil::checkBool($var); - $this->desc = $var; - - return $this; - } - - /** - * @return string - */ - public function getOneOrderBy() - { - return $this->whichOneof("one_order_by"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php deleted file mode 100644 index e660e209cf8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy.php +++ /dev/null @@ -1,104 +0,0 @@ -google.analytics.data.v1alpha.OrderBy.DimensionOrderBy - */ -class DimensionOrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - */ - protected $dimension_name = ''; - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; - */ - protected $order_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * A dimension name in the request to order by. - * @type int $order_type - * Controls the rule for dimension value ordering. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; - * @return int - */ - public function getOrderType() - { - return $this->order_type; - } - - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType order_type = 2; - * @param int $var - * @return $this - */ - public function setOrderType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\OrderBy\DimensionOrderBy\OrderType::class); - $this->order_type = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DimensionOrderBy::class, \Google\Analytics\Data\V1alpha\OrderBy_DimensionOrderBy::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php deleted file mode 100644 index 002c3d3b1f4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/DimensionOrderBy/OrderType.php +++ /dev/null @@ -1,76 +0,0 @@ -google.analytics.data.v1alpha.OrderBy.DimensionOrderBy.OrderType - */ -class OrderType -{ - /** - * Unspecified. - * - * Generated from protobuf enum ORDER_TYPE_UNSPECIFIED = 0; - */ - const ORDER_TYPE_UNSPECIFIED = 0; - /** - * Alphanumeric sort by Unicode code point. For example, "2" < "A" < "X" < - * "b" < "z". - * - * Generated from protobuf enum ALPHANUMERIC = 1; - */ - const ALPHANUMERIC = 1; - /** - * Case insensitive alphanumeric sort by lower case Unicode code point. - * For example, "2" < "A" < "b" < "X" < "z". - * - * Generated from protobuf enum CASE_INSENSITIVE_ALPHANUMERIC = 2; - */ - const CASE_INSENSITIVE_ALPHANUMERIC = 2; - /** - * Dimension values are converted to numbers before sorting. For example - * in NUMERIC sort, "25" < "100", and in `ALPHANUMERIC` sort, "100" < - * "25". Non-numeric dimension values all have equal ordering value below - * all numeric values. - * - * Generated from protobuf enum NUMERIC = 3; - */ - const NUMERIC = 3; - - private static $valueToName = [ - self::ORDER_TYPE_UNSPECIFIED => 'ORDER_TYPE_UNSPECIFIED', - self::ALPHANUMERIC => 'ALPHANUMERIC', - self::CASE_INSENSITIVE_ALPHANUMERIC => 'CASE_INSENSITIVE_ALPHANUMERIC', - self::NUMERIC => 'NUMERIC', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(OrderType::class, \Google\Analytics\Data\V1alpha\OrderBy_DimensionOrderBy_OrderType::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php deleted file mode 100644 index 7d209774985..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/OrderBy/MetricOrderBy.php +++ /dev/null @@ -1,70 +0,0 @@ -google.analytics.data.v1alpha.OrderBy.MetricOrderBy - */ -class MetricOrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - */ - protected $metric_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $metric_name - * A metric name in the request to order by. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - * @return string - */ - public function getMetricName() - { - return $this->metric_name; - } - - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - * @param string $var - * @return $this - */ - public function setMetricName($var) - { - GPBUtil::checkString($var, True); - $this->metric_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MetricOrderBy::class, \Google\Analytics\Data\V1alpha\OrderBy_MetricOrderBy::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php deleted file mode 100644 index 37c205d8251..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/PropertyQuota.php +++ /dev/null @@ -1,363 +0,0 @@ -google.analytics.data.v1alpha.PropertyQuota - */ -class PropertyQuota extends \Google\Protobuf\Internal\Message -{ - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; - */ - protected $tokens_per_day = null; - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; - */ - protected $tokens_per_hour = null; - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; - */ - protected $concurrent_requests = 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; - */ - protected $server_errors_per_project_per_hour = 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; - */ - protected $potentially_thresholded_requests_per_hour = null; - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; - */ - protected $tokens_per_project_per_hour = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_day - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_hour - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $concurrent_requests - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $server_errors_per_project_per_hour - * 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. - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $potentially_thresholded_requests_per_hour - * 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. - * @type \Google\Analytics\Data\V1alpha\QuotaStatus $tokens_per_project_per_hour - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getTokensPerDay() - { - return $this->tokens_per_day; - } - - public function hasTokensPerDay() - { - return isset($this->tokens_per_day); - } - - public function clearTokensPerDay() - { - unset($this->tokens_per_day); - } - - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_day = 1; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setTokensPerDay($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->tokens_per_day = $var; - - return $this; - } - - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getTokensPerHour() - { - return $this->tokens_per_hour; - } - - public function hasTokensPerHour() - { - return isset($this->tokens_per_hour); - } - - public function clearTokensPerHour() - { - unset($this->tokens_per_hour); - } - - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_hour = 2; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setTokensPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->tokens_per_hour = $var; - - return $this; - } - - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getConcurrentRequests() - { - return $this->concurrent_requests; - } - - public function hasConcurrentRequests() - { - return isset($this->concurrent_requests); - } - - public function clearConcurrentRequests() - { - unset($this->concurrent_requests); - } - - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus concurrent_requests = 3; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setConcurrentRequests($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->concurrent_requests = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getServerErrorsPerProjectPerHour() - { - return $this->server_errors_per_project_per_hour; - } - - public function hasServerErrorsPerProjectPerHour() - { - return isset($this->server_errors_per_project_per_hour); - } - - public function clearServerErrorsPerProjectPerHour() - { - unset($this->server_errors_per_project_per_hour); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus server_errors_per_project_per_hour = 4; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setServerErrorsPerProjectPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->server_errors_per_project_per_hour = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getPotentiallyThresholdedRequestsPerHour() - { - return $this->potentially_thresholded_requests_per_hour; - } - - public function hasPotentiallyThresholdedRequestsPerHour() - { - return isset($this->potentially_thresholded_requests_per_hour); - } - - public function clearPotentiallyThresholdedRequestsPerHour() - { - unset($this->potentially_thresholded_requests_per_hour); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus potentially_thresholded_requests_per_hour = 5; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setPotentiallyThresholdedRequestsPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->potentially_thresholded_requests_per_hour = $var; - - return $this; - } - - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; - * @return \Google\Analytics\Data\V1alpha\QuotaStatus|null - */ - public function getTokensPerProjectPerHour() - { - return $this->tokens_per_project_per_hour; - } - - public function hasTokensPerProjectPerHour() - { - return isset($this->tokens_per_project_per_hour); - } - - public function clearTokensPerProjectPerHour() - { - unset($this->tokens_per_project_per_hour); - } - - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1alpha.QuotaStatus tokens_per_project_per_hour = 6; - * @param \Google\Analytics\Data\V1alpha\QuotaStatus $var - * @return $this - */ - public function setTokensPerProjectPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\QuotaStatus::class); - $this->tokens_per_project_per_hour = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php deleted file mode 100644 index 1e552270bd7..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListRequest.php +++ /dev/null @@ -1,205 +0,0 @@ -google.analytics.data.v1alpha.QueryAudienceListRequest - */ -class QueryAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $offset = 0; - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $limit = 0; - - /** - * @param string $name Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * @return \Google\Analytics\Data\V1alpha\QueryAudienceListRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @type int|string $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int|string $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getOffset() - { - return $this->offset; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setOffset($var) - { - GPBUtil::checkInt64($var); - $this->offset = $var; - - return $this; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php deleted file mode 100644 index 34eacd07d7f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QueryAudienceListResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.analytics.data.v1alpha.QueryAudienceListResponse - */ -class QueryAudienceListResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Configuration data about AudienceList being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceList correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; - */ - protected $audience_list = null; - /** - * Rows for each user in an audience list. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; - */ - private $audience_rows; - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - */ - protected $row_count = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list - * Configuration data about AudienceList being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceList correspond to the columns in the AudienceRows. - * @type array<\Google\Analytics\Data\V1alpha\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $audience_rows - * Rows for each user in an audience list. The number of rows in this - * response will be less than or equal to request's page size. - * @type int $row_count - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Configuration data about AudienceList being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceList correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; - * @return \Google\Analytics\Data\V1alpha\AudienceList|null - */ - public function getAudienceList() - { - return $this->audience_list; - } - - public function hasAudienceList() - { - return isset($this->audience_list); - } - - public function clearAudienceList() - { - unset($this->audience_list); - } - - /** - * Configuration data about AudienceList being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceList correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 1; - * @param \Google\Analytics\Data\V1alpha\AudienceList $var - * @return $this - */ - public function setAudienceList($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); - $this->audience_list = $var; - - return $this; - } - - /** - * Rows for each user in an audience list. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAudienceRows() - { - return $this->audience_rows; - } - - /** - * Rows for each user in an audience list. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceRow audience_rows = 2; - * @param array<\Google\Analytics\Data\V1alpha\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAudienceRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceRow::class); - $this->audience_rows = $arr; - - return $this; - } - - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @return int - */ - public function getRowCount() - { - return isset($this->row_count) ? $this->row_count : 0; - } - - public function hasRowCount() - { - return isset($this->row_count); - } - - public function clearRowCount() - { - unset($this->row_count); - } - - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php deleted file mode 100644 index d0e52585a08..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/QuotaStatus.php +++ /dev/null @@ -1,101 +0,0 @@ -google.analytics.data.v1alpha.QuotaStatus - */ -class QuotaStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Quota consumed by this request. - * - * Generated from protobuf field int32 consumed = 1; - */ - protected $consumed = 0; - /** - * Quota remaining after this request. - * - * Generated from protobuf field int32 remaining = 2; - */ - protected $remaining = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $consumed - * Quota consumed by this request. - * @type int $remaining - * Quota remaining after this request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Quota consumed by this request. - * - * Generated from protobuf field int32 consumed = 1; - * @return int - */ - public function getConsumed() - { - return $this->consumed; - } - - /** - * Quota consumed by this request. - * - * Generated from protobuf field int32 consumed = 1; - * @param int $var - * @return $this - */ - public function setConsumed($var) - { - GPBUtil::checkInt32($var); - $this->consumed = $var; - - return $this; - } - - /** - * Quota remaining after this request. - * - * Generated from protobuf field int32 remaining = 2; - * @return int - */ - public function getRemaining() - { - return $this->remaining; - } - - /** - * Quota remaining after this request. - * - * Generated from protobuf field int32 remaining = 2; - * @param int $var - * @return $this - */ - public function setRemaining($var) - { - GPBUtil::checkInt32($var); - $this->remaining = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php deleted file mode 100644 index 39bf5024667..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RecurringAudienceList.php +++ /dev/null @@ -1,410 +0,0 @@ -google.analytics.data.v1alpha.RecurringAudienceList - */ -class RecurringAudienceList extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The recurring audience list resource name assigned - * during creation. This resource name identifies this - * `RecurringAudienceList`. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $audience = ''; - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $audience_display_name = ''; - /** - * Required. The dimensions requested and displayed in the audience list - * response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $dimensions; - /** - * Optional. The number of remaining days that a recurring audience export - * will produce an audience list instance. This counter decreases by one each - * day, and when it reaches zero, no new audience lists will be created. - * Recurring audience list request for Analytics 360 properties default to 180 - * days and have a maximum of 365 days. Requests for standard Analytics - * properties default to 14 days and have a maximum of 30 days. - * The minimum value allowed during creation is 1. Requests above their - * respective maximum will be coerced to their maximum. - * - * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $active_days_remaining = null; - /** - * Output only. Audience list resource names for audience list instances - * created for this recurring audience list. One audience list is created for - * each day, and the audience list will be listed here. - * This list is ordered with the most recently created audience list first. - * - * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $audience_lists; - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when a recurring audience - * list creates new audience lists. Webhooks allow a notification to be sent - * to your servers & avoid the need for polling. - * Two POST requests will be sent each time a recurring audience list creates - * an audience list. This happens once per day until a recurring audience list - * reaches 0 active days remaining. The first request will be sent showing a - * newly created audience list in its CREATING state. The second request will - * be sent after the audience list completes creation (either the ACTIVE or - * FAILED state). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $webhook_notification = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The recurring audience list resource name assigned - * during creation. This resource name identifies this - * `RecurringAudienceList`. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * @type string $audience - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * @type string $audience_display_name - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * @type array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * Required. The dimensions requested and displayed in the audience list - * response. - * @type int $active_days_remaining - * Optional. The number of remaining days that a recurring audience export - * will produce an audience list instance. This counter decreases by one each - * day, and when it reaches zero, no new audience lists will be created. - * Recurring audience list request for Analytics 360 properties default to 180 - * days and have a maximum of 365 days. Requests for standard Analytics - * properties default to 14 days and have a maximum of 30 days. - * The minimum value allowed during creation is 1. Requests above their - * respective maximum will be coerced to their maximum. - * @type array|\Google\Protobuf\Internal\RepeatedField $audience_lists - * Output only. Audience list resource names for audience list instances - * created for this recurring audience list. One audience list is created for - * each day, and the audience list will be listed here. - * This list is ordered with the most recently created audience list first. - * @type \Google\Analytics\Data\V1alpha\WebhookNotification $webhook_notification - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when a recurring audience - * list creates new audience lists. Webhooks allow a notification to be sent - * to your servers & avoid the need for polling. - * Two POST requests will be sent each time a recurring audience list creates - * an audience list. This happens once per day until a recurring audience list - * reaches 0 active days remaining. The first request will be sent showing a - * newly created audience list in its CREATING state. The second request will - * be sent after the audience list completes creation (either the ACTIVE or - * FAILED state). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The recurring audience list resource name assigned - * during creation. This resource name identifies this - * `RecurringAudienceList`. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The recurring audience list resource name assigned - * during creation. This resource name identifies this - * `RecurringAudienceList`. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAudience() - { - return $this->audience; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAudience($var) - { - GPBUtil::checkString($var, True); - $this->audience = $var; - - return $this; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getAudienceDisplayName() - { - return $this->audience_display_name; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setAudienceDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->audience_display_name = $var; - - return $this; - } - - /** - * Required. The dimensions requested and displayed in the audience list - * response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * Required. The dimensions requested and displayed in the audience list - * response. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Analytics\Data\V1alpha\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\AudienceDimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * Optional. The number of remaining days that a recurring audience export - * will produce an audience list instance. This counter decreases by one each - * day, and when it reaches zero, no new audience lists will be created. - * Recurring audience list request for Analytics 360 properties default to 180 - * days and have a maximum of 365 days. Requests for standard Analytics - * properties default to 14 days and have a maximum of 30 days. - * The minimum value allowed during creation is 1. Requests above their - * respective maximum will be coerced to their maximum. - * - * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getActiveDaysRemaining() - { - return isset($this->active_days_remaining) ? $this->active_days_remaining : 0; - } - - public function hasActiveDaysRemaining() - { - return isset($this->active_days_remaining); - } - - public function clearActiveDaysRemaining() - { - unset($this->active_days_remaining); - } - - /** - * Optional. The number of remaining days that a recurring audience export - * will produce an audience list instance. This counter decreases by one each - * day, and when it reaches zero, no new audience lists will be created. - * Recurring audience list request for Analytics 360 properties default to 180 - * days and have a maximum of 365 days. Requests for standard Analytics - * properties default to 14 days and have a maximum of 30 days. - * The minimum value allowed during creation is 1. Requests above their - * respective maximum will be coerced to their maximum. - * - * Generated from protobuf field optional int32 active_days_remaining = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setActiveDaysRemaining($var) - { - GPBUtil::checkInt32($var); - $this->active_days_remaining = $var; - - return $this; - } - - /** - * Output only. Audience list resource names for audience list instances - * created for this recurring audience list. One audience list is created for - * each day, and the audience list will be listed here. - * This list is ordered with the most recently created audience list first. - * - * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAudienceLists() - { - return $this->audience_lists; - } - - /** - * Output only. Audience list resource names for audience list instances - * created for this recurring audience list. One audience list is created for - * each day, and the audience list will be listed here. - * This list is ordered with the most recently created audience list first. - * - * Generated from protobuf field repeated string audience_lists = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAudienceLists($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->audience_lists = $arr; - - return $this; - } - - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when a recurring audience - * list creates new audience lists. Webhooks allow a notification to be sent - * to your servers & avoid the need for polling. - * Two POST requests will be sent each time a recurring audience list creates - * an audience list. This happens once per day until a recurring audience list - * reaches 0 active days remaining. The first request will be sent showing a - * newly created audience list in its CREATING state. The second request will - * be sent after the audience list completes creation (either the ACTIVE or - * FAILED state). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\WebhookNotification|null - */ - public function getWebhookNotification() - { - return $this->webhook_notification; - } - - public function hasWebhookNotification() - { - return isset($this->webhook_notification); - } - - public function clearWebhookNotification() - { - unset($this->webhook_notification); - } - - /** - * Optional. Configures webhook notifications to be sent from the Google - * Analytics Data API to your webhook server. Use of webhooks is optional. If - * unused, you'll need to poll this API to determine when a recurring audience - * list creates new audience lists. Webhooks allow a notification to be sent - * to your servers & avoid the need for polling. - * Two POST requests will be sent each time a recurring audience list creates - * an audience list. This happens once per day until a recurring audience list - * reaches 0 active days remaining. The first request will be sent showing a - * newly created audience list in its CREATING state. The second request will - * be sent after the audience list completes creation (either the ACTIVE or - * FAILED state). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.WebhookNotification webhook_notification = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\WebhookNotification $var - * @return $this - */ - public function setWebhookNotification($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\WebhookNotification::class); - $this->webhook_notification = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php deleted file mode 100644 index 35955f8ff9b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/ResponseMetaData.php +++ /dev/null @@ -1,407 +0,0 @@ -google.analytics.data.v1alpha.ResponseMetaData - */ -class ResponseMetaData extends \Google\Protobuf\Internal\Message -{ - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - */ - protected $data_loss_from_other_row = false; - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - */ - protected $schema_restriction_response = null; - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - */ - protected $currency_code = null; - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - */ - protected $time_zone = null; - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - */ - protected $empty_reason = null; - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630) and [About - * Demographics and - * Interests](https://support.google.com/analytics/answer/2799357). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - */ - protected $subject_to_thresholding = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $data_loss_from_other_row - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * @type \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $schema_restriction_response - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * @type string $currency_code - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * @type string $time_zone - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * @type string $empty_reason - * If empty reason is specified, the report is empty for this reason. - * @type bool $subject_to_thresholding - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630) and [About - * Demographics and - * Interests](https://support.google.com/analytics/answer/2799357). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - * @return bool - */ - public function getDataLossFromOtherRow() - { - return $this->data_loss_from_other_row; - } - - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - * @param bool $var - * @return $this - */ - public function setDataLossFromOtherRow($var) - { - GPBUtil::checkBool($var); - $this->data_loss_from_other_row = $var; - - return $this; - } - - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - * @return \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse|null - */ - public function getSchemaRestrictionResponse() - { - return $this->schema_restriction_response; - } - - public function hasSchemaRestrictionResponse() - { - return isset($this->schema_restriction_response); - } - - public function clearSchemaRestrictionResponse() - { - unset($this->schema_restriction_response); - } - - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - * @param \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse $var - * @return $this - */ - public function setSchemaRestrictionResponse($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\ResponseMetaData\SchemaRestrictionResponse::class); - $this->schema_restriction_response = $var; - - return $this; - } - - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - * @return string - */ - public function getCurrencyCode() - { - return isset($this->currency_code) ? $this->currency_code : ''; - } - - public function hasCurrencyCode() - { - return isset($this->currency_code); - } - - public function clearCurrencyCode() - { - unset($this->currency_code); - } - - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - * @param string $var - * @return $this - */ - public function setCurrencyCode($var) - { - GPBUtil::checkString($var, True); - $this->currency_code = $var; - - return $this; - } - - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - * @return string - */ - public function getTimeZone() - { - return isset($this->time_zone) ? $this->time_zone : ''; - } - - public function hasTimeZone() - { - return isset($this->time_zone); - } - - public function clearTimeZone() - { - unset($this->time_zone); - } - - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - * @param string $var - * @return $this - */ - public function setTimeZone($var) - { - GPBUtil::checkString($var, True); - $this->time_zone = $var; - - return $this; - } - - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - * @return string - */ - public function getEmptyReason() - { - return isset($this->empty_reason) ? $this->empty_reason : ''; - } - - public function hasEmptyReason() - { - return isset($this->empty_reason); - } - - public function clearEmptyReason() - { - unset($this->empty_reason); - } - - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - * @param string $var - * @return $this - */ - public function setEmptyReason($var) - { - GPBUtil::checkString($var, True); - $this->empty_reason = $var; - - return $this; - } - - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630) and [About - * Demographics and - * Interests](https://support.google.com/analytics/answer/2799357). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - * @return bool - */ - public function getSubjectToThresholding() - { - return isset($this->subject_to_thresholding) ? $this->subject_to_thresholding : false; - } - - public function hasSubjectToThresholding() - { - return isset($this->subject_to_thresholding); - } - - public function clearSubjectToThresholding() - { - unset($this->subject_to_thresholding); - } - - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630) and [About - * Demographics and - * Interests](https://support.google.com/analytics/answer/2799357). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - * @param bool $var - * @return $this - */ - public function setSubjectToThresholding($var) - { - GPBUtil::checkBool($var); - $this->subject_to_thresholding = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php deleted file mode 100644 index f6a27f8042b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Row.php +++ /dev/null @@ -1,138 +0,0 @@ -google.analytics.data.v1alpha.Row - */ -class Row extends \Google\Protobuf\Internal\Message -{ - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; - */ - private $dimension_values; - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; - */ - private $metric_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * @type array<\Google\Analytics\Data\V1alpha\MetricValue>|\Google\Protobuf\Internal\RepeatedField $metric_values - * List of requested visible metric values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionValues() - { - return $this->dimension_values; - } - - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DimensionValue dimension_values = 1; - * @param array<\Google\Analytics\Data\V1alpha\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DimensionValue::class); - $this->dimension_values = $arr; - - return $this; - } - - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricValues() - { - return $this->metric_values; - } - - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.MetricValue metric_values = 2; - * @param array<\Google\Analytics\Data\V1alpha\MetricValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\MetricValue::class); - $this->metric_values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php deleted file mode 100644 index bd1c2b97569..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest.php +++ /dev/null @@ -1,557 +0,0 @@ -google.analytics.data.v1alpha.RunFunnelReportRequest - */ -class RunFunnelReportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. 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 - * - * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $property = ''; - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $date_ranges; - /** - * Optional. The configuration of this request's funnel. This funnel - * configuration is required. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $funnel = null; - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $funnel_breakdown = null; - /** - * Optional. 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 next - * action of the `eventName` dimension will create rows for several events - * (for example `session_start` & `click`) and the total. - * Next action only supports `eventName` and most Page / Screen dimensions - * like `pageTitle` and `pagePath`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $funnel_next_action = null; - /** - * Optional. The funnel visualization type controls the dimensions present in - * the funnel visualization sub report response. If not specified, - * `STANDARD_FUNNEL` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $funnel_visualization_type = 0; - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $segments; - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $limit = 0; - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $dimension_filter = null; - /** - * Optional. Toggles whether to return the current state of this Analytics - * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $return_property_quota = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $property - * Optional. 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 - * @type array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges - * Optional. 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. - * @type \Google\Analytics\Data\V1alpha\Funnel $funnel - * Optional. The configuration of this request's funnel. This funnel - * configuration is required. - * @type \Google\Analytics\Data\V1alpha\FunnelBreakdown $funnel_breakdown - * Optional. 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. - * @type \Google\Analytics\Data\V1alpha\FunnelNextAction $funnel_next_action - * Optional. 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 next - * action of the `eventName` dimension will create rows for several events - * (for example `session_start` & `click`) and the total. - * Next action only supports `eventName` and most Page / Screen dimensions - * like `pageTitle` and `pagePath`. - * @type int $funnel_visualization_type - * Optional. The funnel visualization type controls the dimensions present in - * the funnel visualization sub report response. If not specified, - * `STANDARD_FUNNEL` is used. - * @type array<\Google\Analytics\Data\V1alpha\Segment>|\Google\Protobuf\Internal\RepeatedField $segments - * Optional. 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. - * @type int|string $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * @type \Google\Analytics\Data\V1alpha\FilterExpression $dimension_filter - * Optional. 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. - * @type bool $return_property_quota - * Optional. Toggles whether to return the current state of this Analytics - * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Optional. 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 - * - * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getProperty() - { - return $this->property; - } - - /** - * Optional. 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 - * - * Generated from protobuf field string property = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDateRanges() - { - return $this->date_ranges; - } - - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.DateRange date_ranges = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Analytics\Data\V1alpha\DateRange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDateRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\DateRange::class); - $this->date_ranges = $arr; - - return $this; - } - - /** - * Optional. The configuration of this request's funnel. This funnel - * configuration is required. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\Funnel|null - */ - public function getFunnel() - { - return $this->funnel; - } - - public function hasFunnel() - { - return isset($this->funnel); - } - - public function clearFunnel() - { - unset($this->funnel); - } - - /** - * Optional. The configuration of this request's funnel. This funnel - * configuration is required. - * - * Generated from protobuf field .google.analytics.data.v1alpha.Funnel funnel = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\Funnel $var - * @return $this - */ - public function setFunnel($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\Funnel::class); - $this->funnel = $var; - - return $this; - } - - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\FunnelBreakdown|null - */ - public function getFunnelBreakdown() - { - return $this->funnel_breakdown; - } - - public function hasFunnelBreakdown() - { - return isset($this->funnel_breakdown); - } - - public function clearFunnelBreakdown() - { - unset($this->funnel_breakdown); - } - - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelBreakdown funnel_breakdown = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\FunnelBreakdown $var - * @return $this - */ - public function setFunnelBreakdown($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelBreakdown::class); - $this->funnel_breakdown = $var; - - return $this; - } - - /** - * Optional. 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 next - * action of the `eventName` dimension will create rows for several events - * (for example `session_start` & `click`) and the total. - * Next action only supports `eventName` and most Page / Screen dimensions - * like `pageTitle` and `pagePath`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\FunnelNextAction|null - */ - public function getFunnelNextAction() - { - return $this->funnel_next_action; - } - - public function hasFunnelNextAction() - { - return isset($this->funnel_next_action); - } - - public function clearFunnelNextAction() - { - unset($this->funnel_next_action); - } - - /** - * Optional. 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 next - * action of the `eventName` dimension will create rows for several events - * (for example `session_start` & `click`) and the total. - * Next action only supports `eventName` and most Page / Screen dimensions - * like `pageTitle` and `pagePath`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelNextAction funnel_next_action = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\FunnelNextAction $var - * @return $this - */ - public function setFunnelNextAction($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelNextAction::class); - $this->funnel_next_action = $var; - - return $this; - } - - /** - * Optional. The funnel visualization type controls the dimensions present in - * the funnel visualization sub report response. If not specified, - * `STANDARD_FUNNEL` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getFunnelVisualizationType() - { - return $this->funnel_visualization_type; - } - - /** - * Optional. The funnel visualization type controls the dimensions present in - * the funnel visualization sub report response. If not specified, - * `STANDARD_FUNNEL` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType funnel_visualization_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setFunnelVisualizationType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\RunFunnelReportRequest\FunnelVisualizationType::class); - $this->funnel_visualization_type = $var; - - return $this; - } - - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSegments() - { - return $this->segments; - } - - /** - * Optional. 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.Segment segments = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param array<\Google\Analytics\Data\V1alpha\Segment>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSegments($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\Segment::class); - $this->segments = $arr; - - return $this; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * Generated from protobuf field int64 limit = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Analytics\Data\V1alpha\FilterExpression|null - */ - public function getDimensionFilter() - { - return $this->dimension_filter; - } - - public function hasDimensionFilter() - { - return isset($this->dimension_filter); - } - - public function clearDimensionFilter() - { - unset($this->dimension_filter); - } - - /** - * Optional. 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FilterExpression dimension_filter = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Analytics\Data\V1alpha\FilterExpression $var - * @return $this - */ - public function setDimensionFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FilterExpression::class); - $this->dimension_filter = $var; - - return $this; - } - - /** - * Optional. Toggles whether to return the current state of this Analytics - * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getReturnPropertyQuota() - { - return $this->return_property_quota; - } - - /** - * Optional. Toggles whether to return the current state of this Analytics - * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setReturnPropertyQuota($var) - { - GPBUtil::checkBool($var); - $this->return_property_quota = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php deleted file mode 100644 index cbb2df603a9..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportRequest/FunnelVisualizationType.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.RunFunnelReportRequest.FunnelVisualizationType - */ -class FunnelVisualizationType -{ - /** - * Unspecified type. - * - * Generated from protobuf enum FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; - */ - const FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED = 0; - /** - * A standard (stepped) funnel. The funnel visualization sub report in the - * response will not contain date. - * - * Generated from protobuf enum STANDARD_FUNNEL = 1; - */ - const STANDARD_FUNNEL = 1; - /** - * A trended (line chart) funnel. The funnel visualization sub report in the - * response will contain the date dimension. - * - * Generated from protobuf enum TRENDED_FUNNEL = 2; - */ - const TRENDED_FUNNEL = 2; - - private static $valueToName = [ - self::FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED => 'FUNNEL_VISUALIZATION_TYPE_UNSPECIFIED', - self::STANDARD_FUNNEL => 'STANDARD_FUNNEL', - self::TRENDED_FUNNEL => 'TRENDED_FUNNEL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FunnelVisualizationType::class, \Google\Analytics\Data\V1alpha\RunFunnelReportRequest_FunnelVisualizationType::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php deleted file mode 100644 index 7e62c5adcd8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/RunFunnelReportResponse.php +++ /dev/null @@ -1,248 +0,0 @@ -google.analytics.data.v1alpha.RunFunnelReportResponse - */ -class RunFunnelReportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; - */ - protected $funnel_table = 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 through the `TRENDED_FUNNEL` funnel type. The next action - * dimension is only present in the response if it was requested. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; - */ - protected $funnel_visualization = null; - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; - */ - protected $property_quota = null; - /** - * 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. - * - * Generated from protobuf field string kind = 4; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\FunnelSubReport $funnel_table - * 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. - * @type \Google\Analytics\Data\V1alpha\FunnelSubReport $funnel_visualization - * 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 through the `TRENDED_FUNNEL` funnel type. The next action - * dimension is only present in the response if it was requested. - * @type \Google\Analytics\Data\V1alpha\PropertyQuota $property_quota - * This Analytics Property's quota state including this request. - * @type string $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; - * @return \Google\Analytics\Data\V1alpha\FunnelSubReport|null - */ - public function getFunnelTable() - { - return $this->funnel_table; - } - - public function hasFunnelTable() - { - return isset($this->funnel_table); - } - - public function clearFunnelTable() - { - unset($this->funnel_table); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_table = 1; - * @param \Google\Analytics\Data\V1alpha\FunnelSubReport $var - * @return $this - */ - public function setFunnelTable($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelSubReport::class); - $this->funnel_table = $var; - - 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 through the `TRENDED_FUNNEL` funnel type. The next action - * dimension is only present in the response if it was requested. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; - * @return \Google\Analytics\Data\V1alpha\FunnelSubReport|null - */ - public function getFunnelVisualization() - { - return $this->funnel_visualization; - } - - public function hasFunnelVisualization() - { - return isset($this->funnel_visualization); - } - - public function clearFunnelVisualization() - { - unset($this->funnel_visualization); - } - - /** - * 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 through the `TRENDED_FUNNEL` funnel type. The next action - * dimension is only present in the response if it was requested. - * - * Generated from protobuf field .google.analytics.data.v1alpha.FunnelSubReport funnel_visualization = 2; - * @param \Google\Analytics\Data\V1alpha\FunnelSubReport $var - * @return $this - */ - public function setFunnelVisualization($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\FunnelSubReport::class); - $this->funnel_visualization = $var; - - return $this; - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; - * @return \Google\Analytics\Data\V1alpha\PropertyQuota|null - */ - public function getPropertyQuota() - { - return $this->property_quota; - } - - public function hasPropertyQuota() - { - return isset($this->property_quota); - } - - public function clearPropertyQuota() - { - unset($this->property_quota); - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1alpha.PropertyQuota property_quota = 3; - * @param \Google\Analytics\Data\V1alpha\PropertyQuota $var - * @return $this - */ - public function setPropertyQuota($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\PropertyQuota::class); - $this->property_quota = $var; - - 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. - * - * Generated from protobuf field string kind = 4; - * @return string - */ - public function getKind() - { - return $this->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. - * - * Generated from protobuf field string kind = 4; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php deleted file mode 100644 index 1c501d95f5e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SamplingMetadata.php +++ /dev/null @@ -1,134 +0,0 @@ -google.analytics.data.v1alpha.SamplingMetadata - */ -class SamplingMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field int64 samples_read_count = 1; - */ - protected $samples_read_count = 0; - /** - * 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`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - */ - protected $sampling_space_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $samples_read_count - * 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. - * @type int|string $sampling_space_size - * 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`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field int64 samples_read_count = 1; - * @return int|string - */ - public function getSamplesReadCount() - { - return $this->samples_read_count; - } - - /** - * 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. - * - * Generated from protobuf field int64 samples_read_count = 1; - * @param int|string $var - * @return $this - */ - public function setSamplesReadCount($var) - { - GPBUtil::checkInt64($var); - $this->samples_read_count = $var; - - 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`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - * @return int|string - */ - public function getSamplingSpaceSize() - { - return $this->sampling_space_size; - } - - /** - * 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`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - * @param int|string $var - * @return $this - */ - public function setSamplingSpaceSize($var) - { - GPBUtil::checkInt64($var); - $this->sampling_space_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php deleted file mode 100644 index 9a4ea990049..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/Segment.php +++ /dev/null @@ -1,198 +0,0 @@ -google.analytics.data.v1alpha.Segment - */ -class Segment extends \Google\Protobuf\Internal\Message -{ - /** - * 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 (for example "1. Segment", "2. Segment", etc.). - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - protected $one_segment_scope; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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 (for example "1. Segment", "2. Segment", etc.). - * @type \Google\Analytics\Data\V1alpha\UserSegment $user_segment - * User segments are subsets of users who engaged with your site or app. - * @type \Google\Analytics\Data\V1alpha\SessionSegment $session_segment - * Session segments are subsets of the sessions that occurred on your site - * or app. - * @type \Google\Analytics\Data\V1alpha\EventSegment $event_segment - * Event segments are subsets of events that were triggered on your site or - * app. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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 (for example "1. Segment", "2. Segment", etc.). - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->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 (for example "1. Segment", "2. Segment", etc.). - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * User segments are subsets of users who engaged with your site or app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegment user_segment = 2; - * @return \Google\Analytics\Data\V1alpha\UserSegment|null - */ - public function getUserSegment() - { - return $this->readOneof(2); - } - - public function hasUserSegment() - { - return $this->hasOneof(2); - } - - /** - * User segments are subsets of users who engaged with your site or app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegment user_segment = 2; - * @param \Google\Analytics\Data\V1alpha\UserSegment $var - * @return $this - */ - public function setUserSegment($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegment::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Session segments are subsets of the sessions that occurred on your site - * or app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegment session_segment = 3; - * @return \Google\Analytics\Data\V1alpha\SessionSegment|null - */ - public function getSessionSegment() - { - return $this->readOneof(3); - } - - public function hasSessionSegment() - { - return $this->hasOneof(3); - } - - /** - * Session segments are subsets of the sessions that occurred on your site - * or app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegment session_segment = 3; - * @param \Google\Analytics\Data\V1alpha\SessionSegment $var - * @return $this - */ - public function setSessionSegment($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegment::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Event segments are subsets of events that were triggered on your site or - * app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegment event_segment = 4; - * @return \Google\Analytics\Data\V1alpha\EventSegment|null - */ - public function getEventSegment() - { - return $this->readOneof(4); - } - - public function hasEventSegment() - { - return $this->hasOneof(4); - } - - /** - * Event segments are subsets of events that were triggered on your site or - * app. - * - * Generated from protobuf field .google.analytics.data.v1alpha.EventSegment event_segment = 4; - * @param \Google\Analytics\Data\V1alpha\EventSegment $var - * @return $this - */ - public function setEventSegment($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\EventSegment::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneSegmentScope() - { - return $this->whichOneof("one_segment_scope"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php deleted file mode 100644 index 4947a2698cf..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentEventFilter.php +++ /dev/null @@ -1,140 +0,0 @@ -google.analytics.data.v1alpha.SegmentEventFilter - */ -class SegmentEventFilter extends \Google\Protobuf\Internal\Message -{ - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - */ - protected $event_name = null; - /** - * 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; - */ - protected $segment_parameter_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $event_name - * This filter matches events of this single event name. Event name is - * required. - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $segment_parameter_filter_expression - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - * @return string - */ - public function getEventName() - { - return isset($this->event_name) ? $this->event_name : ''; - } - - public function hasEventName() - { - return isset($this->event_name); - } - - public function clearEventName() - { - unset($this->event_name); - } - - /** - * This filter matches events of this single event name. Event name is - * required. - * - * Generated from protobuf field optional string event_name = 1; - * @param string $var - * @return $this - */ - public function setEventName($var) - { - GPBUtil::checkString($var, True); - $this->event_name = $var; - - 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression|null - */ - public function getSegmentParameterFilterExpression() - { - return $this->segment_parameter_filter_expression; - } - - public function hasSegmentParameterFilterExpression() - { - return isset($this->segment_parameter_filter_expression); - } - - public function clearSegmentParameterFilterExpression() - { - unset($this->segment_parameter_filter_expression); - } - - /** - * 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. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.SegmentParameterFilterExpression segment_parameter_filter_expression = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $var - * @return $this - */ - public function setSegmentParameterFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); - $this->segment_parameter_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php deleted file mode 100644 index ee3af867491..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilter.php +++ /dev/null @@ -1,252 +0,0 @@ -google.analytics.data.v1alpha.SegmentFilter - */ -class SegmentFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - */ - protected $field_name = ''; - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; - */ - protected $filter_scoping = null; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field_name - * The dimension name or metric name. - * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter - * A filter for between two values. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterScoping $filter_scoping - * Specifies the scope for the filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - * @return string - */ - public function getFieldName() - { - return $this->field_name; - } - - /** - * The dimension name or metric name. - * - * Generated from protobuf field string field_name = 1; - * @param string $var - * @return $this - */ - public function setFieldName($var) - { - GPBUtil::checkString($var, True); - $this->field_name = $var; - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @return \Google\Analytics\Data\V1alpha\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(4); - } - - public function hasStringFilter() - { - return $this->hasOneof(4); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @param \Google\Analytics\Data\V1alpha\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @return \Google\Analytics\Data\V1alpha\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(5); - } - - public function hasInListFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @param \Google\Analytics\Data\V1alpha\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @return \Google\Analytics\Data\V1alpha\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(6); - } - - public function hasNumericFilter() - { - return $this->hasOneof(6); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @param \Google\Analytics\Data\V1alpha\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(7); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(7); - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterScoping|null - */ - public function getFilterScoping() - { - return $this->filter_scoping; - } - - public function hasFilterScoping() - { - return isset($this->filter_scoping); - } - - public function clearFilterScoping() - { - unset($this->filter_scoping); - } - - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterScoping filter_scoping = 8; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterScoping $var - * @return $this - */ - public function setFilterScoping($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterScoping::class); - $this->filter_scoping = $var; - - return $this; - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php deleted file mode 100644 index 6fe85c6acbc..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpression.php +++ /dev/null @@ -1,216 +0,0 @@ -google.analytics.data.v1alpha.SegmentFilterExpression - */ -class SegmentFilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $and_group - * The SegmentFilterExpression in `andGroup` have an AND relationship. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $or_group - * The SegmentFilterExpression in `orGroup` have an OR relationship. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $not_expression - * The SegmentFilterExpression is NOT of `notExpression`. - * @type \Google\Analytics\Data\V1alpha\SegmentFilter $segment_filter - * A primitive segment filter. - * @type \Google\Analytics\Data\V1alpha\SegmentEventFilter $segment_event_filter - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The SegmentFilterExpression in `andGroup` have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The SegmentFilterExpression in `andGroup` have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The SegmentFilterExpression in `orGroup` have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The SegmentFilterExpression in `orGroup` have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The SegmentFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The SegmentFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A primitive segment filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; - * @return \Google\Analytics\Data\V1alpha\SegmentFilter|null - */ - public function getSegmentFilter() - { - return $this->readOneof(4); - } - - public function hasSegmentFilter() - { - return $this->hasOneof(4); - } - - /** - * A primitive segment filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilter segment_filter = 4; - * @param \Google\Analytics\Data\V1alpha\SegmentFilter $var - * @return $this - */ - public function setSegmentFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilter::class); - $this->writeOneof(4, $var); - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; - * @return \Google\Analytics\Data\V1alpha\SegmentEventFilter|null - */ - public function getSegmentEventFilter() - { - return $this->readOneof(5); - } - - public function hasSegmentEventFilter() - { - return $this->hasOneof(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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentEventFilter segment_event_filter = 5; - * @param \Google\Analytics\Data\V1alpha\SegmentEventFilter $var - * @return $this - */ - public function setSegmentEventFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentEventFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php deleted file mode 100644 index 206cf85b572..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.SegmentFilterExpressionList - */ -class SegmentFilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * The list of segment filter expressions - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\SegmentFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * The list of segment filter expressions - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of segment filter expressions - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * The list of segment filter expressions - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentFilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1alpha\SegmentFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php deleted file mode 100644 index 8af2c7927bc..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentFilterScoping.php +++ /dev/null @@ -1,118 +0,0 @@ -google.analytics.data.v1alpha.SegmentFilterScoping - */ -class SegmentFilterScoping extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field optional bool at_any_point_in_time = 1; - */ - protected $at_any_point_in_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $at_any_point_in_time - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field optional bool at_any_point_in_time = 1; - * @return bool - */ - public function getAtAnyPointInTime() - { - return isset($this->at_any_point_in_time) ? $this->at_any_point_in_time : false; - } - - public function hasAtAnyPointInTime() - { - return isset($this->at_any_point_in_time); - } - - public function clearAtAnyPointInTime() - { - unset($this->at_any_point_in_time); - } - - /** - * 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. - * - * Generated from protobuf field optional bool at_any_point_in_time = 1; - * @param bool $var - * @return $this - */ - public function setAtAnyPointInTime($var) - { - GPBUtil::checkBool($var); - $this->at_any_point_in_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php deleted file mode 100644 index e161480fd21..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilter.php +++ /dev/null @@ -1,335 +0,0 @@ -google.analytics.data.v1alpha.SegmentParameterFilter - */ -class SegmentParameterFilter extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; - */ - protected $filter_scoping = null; - protected $one_parameter; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $event_parameter_name - * 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. - * @type string $item_parameter_name - * 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. - * @type \Google\Analytics\Data\V1alpha\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1alpha\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1alpha\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1alpha\BetweenFilter $between_filter - * A filter for between two values. - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping $filter_scoping - * Specifies the scope for the filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field string event_parameter_name = 1; - * @return string - */ - public function getEventParameterName() - { - return $this->readOneof(1); - } - - public function hasEventParameterName() - { - return $this->hasOneof(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. - * - * Generated from protobuf field string event_parameter_name = 1; - * @param string $var - * @return $this - */ - public function setEventParameterName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - 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. - * - * Generated from protobuf field string item_parameter_name = 2; - * @return string - */ - public function getItemParameterName() - { - return $this->readOneof(2); - } - - public function hasItemParameterName() - { - return $this->hasOneof(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. - * - * Generated from protobuf field string item_parameter_name = 2; - * @param string $var - * @return $this - */ - public function setItemParameterName($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @return \Google\Analytics\Data\V1alpha\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(4); - } - - public function hasStringFilter() - { - return $this->hasOneof(4); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter string_filter = 4; - * @param \Google\Analytics\Data\V1alpha\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\StringFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @return \Google\Analytics\Data\V1alpha\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(5); - } - - public function hasInListFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.InListFilter in_list_filter = 5; - * @param \Google\Analytics\Data\V1alpha\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\InListFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @return \Google\Analytics\Data\V1alpha\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(6); - } - - public function hasNumericFilter() - { - return $this->hasOneof(6); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.NumericFilter numeric_filter = 6; - * @param \Google\Analytics\Data\V1alpha\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\NumericFilter::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @return \Google\Analytics\Data\V1alpha\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(7); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(7); - } - - /** - * A filter for between two values. - * - * Generated from protobuf field .google.analytics.data.v1alpha.BetweenFilter between_filter = 7; - * @param \Google\Analytics\Data\V1alpha\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\BetweenFilter::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping|null - */ - public function getFilterScoping() - { - return $this->filter_scoping; - } - - public function hasFilterScoping() - { - return isset($this->filter_scoping); - } - - public function clearFilterScoping() - { - unset($this->filter_scoping); - } - - /** - * Specifies the scope for the filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterScoping filter_scoping = 8; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping $var - * @return $this - */ - public function setFilterScoping($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterScoping::class); - $this->filter_scoping = $var; - - return $this; - } - - /** - * @return string - */ - public function getOneParameter() - { - return $this->whichOneof("one_parameter"); - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php deleted file mode 100644 index f9983bc974a..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpression.php +++ /dev/null @@ -1,180 +0,0 @@ -google.analytics.data.v1alpha.SegmentParameterFilterExpression - */ -class SegmentParameterFilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $and_group - * The SegmentParameterFilterExpression in `andGroup` have an AND - * relationship. - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $or_group - * The SegmentParameterFilterExpression in `orGroup` have an OR - * relationship. - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $not_expression - * The SegmentParameterFilterExpression is NOT of `notExpression`. - * @type \Google\Analytics\Data\V1alpha\SegmentParameterFilter $segment_parameter_filter - * A primitive segment parameter filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The SegmentParameterFilterExpression in `andGroup` have an AND - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The SegmentParameterFilterExpression in `andGroup` have an AND - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The SegmentParameterFilterExpression in `orGroup` have an OR - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The SegmentParameterFilterExpression in `orGroup` have an OR - * relationship. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The SegmentParameterFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The SegmentParameterFilterExpression is NOT of `notExpression`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A primitive segment parameter filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; - * @return \Google\Analytics\Data\V1alpha\SegmentParameterFilter|null - */ - public function getSegmentParameterFilter() - { - return $this->readOneof(4); - } - - public function hasSegmentParameterFilter() - { - return $this->hasOneof(4); - } - - /** - * A primitive segment parameter filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentParameterFilter segment_parameter_filter = 4; - * @param \Google\Analytics\Data\V1alpha\SegmentParameterFilter $var - * @return $this - */ - public function setSegmentParameterFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentParameterFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php deleted file mode 100644 index 714a516d2f4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1alpha.SegmentParameterFilterExpressionList - */ -class SegmentParameterFilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * The list of segment parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * The list of segment parameter filter expressions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of segment parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * The list of segment parameter filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SegmentParameterFilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SegmentParameterFilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php deleted file mode 100644 index 052ccb6aefb..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SegmentParameterFilterScoping.php +++ /dev/null @@ -1,158 +0,0 @@ -google.analytics.data.v1alpha.SegmentParameterFilterScoping - */ -class SegmentParameterFilterScoping extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field optional int64 in_any_n_day_period = 1; - */ - protected $in_any_n_day_period = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $in_any_n_day_period - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field optional int64 in_any_n_day_period = 1; - * @return int|string - */ - public function getInAnyNDayPeriod() - { - return isset($this->in_any_n_day_period) ? $this->in_any_n_day_period : 0; - } - - public function hasInAnyNDayPeriod() - { - return isset($this->in_any_n_day_period); - } - - public function clearInAnyNDayPeriod() - { - unset($this->in_any_n_day_period); - } - - /** - * 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. - * - * Generated from protobuf field optional int64 in_any_n_day_period = 1; - * @param int|string $var - * @return $this - */ - public function setInAnyNDayPeriod($var) - { - GPBUtil::checkInt64($var); - $this->in_any_n_day_period = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php deleted file mode 100644 index 9c91a5d4589..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionCriteriaScoping.php +++ /dev/null @@ -1,64 +0,0 @@ -google.analytics.data.v1alpha.SessionCriteriaScoping - */ -class SessionCriteriaScoping -{ - /** - * Unspecified criteria scoping. Do not specify. - * - * Generated from protobuf enum SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; - */ - const SESSION_CRITERIA_SCOPING_UNSPECIFIED = 0; - /** - * If the criteria is satisfied within one event, the session matches the - * criteria. - * - * Generated from protobuf enum SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; - */ - const SESSION_CRITERIA_WITHIN_SAME_EVENT = 1; - /** - * If the criteria is satisfied within one session, the session matches - * the criteria. - * - * Generated from protobuf enum SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; - */ - const SESSION_CRITERIA_WITHIN_SAME_SESSION = 2; - - private static $valueToName = [ - self::SESSION_CRITERIA_SCOPING_UNSPECIFIED => 'SESSION_CRITERIA_SCOPING_UNSPECIFIED', - self::SESSION_CRITERIA_WITHIN_SAME_EVENT => 'SESSION_CRITERIA_WITHIN_SAME_EVENT', - self::SESSION_CRITERIA_WITHIN_SAME_SESSION => 'SESSION_CRITERIA_WITHIN_SAME_SESSION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php deleted file mode 100644 index 345ecc1e5b5..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionExclusionDuration.php +++ /dev/null @@ -1,64 +0,0 @@ -google.analytics.data.v1alpha.SessionExclusionDuration - */ -class SessionExclusionDuration -{ - /** - * Unspecified exclusion duration. Do not specify. - * - * Generated from protobuf enum SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; - */ - const SESSION_EXCLUSION_DURATION_UNSPECIFIED = 0; - /** - * Temporarily exclude sessions from the segment during periods when the - * session meets the `sessionExclusionCriteria` condition. - * - * Generated from protobuf enum SESSION_EXCLUSION_TEMPORARY = 1; - */ - const SESSION_EXCLUSION_TEMPORARY = 1; - /** - * Permanently exclude sessions from the segment if the session ever meets - * the `sessionExclusionCriteria` condition. - * - * Generated from protobuf enum SESSION_EXCLUSION_PERMANENT = 2; - */ - const SESSION_EXCLUSION_PERMANENT = 2; - - private static $valueToName = [ - self::SESSION_EXCLUSION_DURATION_UNSPECIFIED => 'SESSION_EXCLUSION_DURATION_UNSPECIFIED', - self::SESSION_EXCLUSION_TEMPORARY => 'SESSION_EXCLUSION_TEMPORARY', - self::SESSION_EXCLUSION_PERMANENT => 'SESSION_EXCLUSION_PERMANENT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php deleted file mode 100644 index 032ea93baa8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegment.php +++ /dev/null @@ -1,123 +0,0 @@ -google.analytics.data.v1alpha.SessionSegment - */ -class SessionSegment extends \Google\Protobuf\Internal\Message -{ - /** - * Defines which sessions are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; - */ - protected $session_inclusion_criteria = null; - /** - * Defines which sessions are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; - */ - protected $exclusion = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $session_inclusion_criteria - * Defines which sessions are included in this segment. Optional. - * @type \Google\Analytics\Data\V1alpha\SessionSegmentExclusion $exclusion - * Defines which sessions are excluded in this segment. Optional. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Defines which sessions are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; - * @return \Google\Analytics\Data\V1alpha\SessionSegmentCriteria|null - */ - public function getSessionInclusionCriteria() - { - return $this->session_inclusion_criteria; - } - - public function hasSessionInclusionCriteria() - { - return isset($this->session_inclusion_criteria); - } - - public function clearSessionInclusionCriteria() - { - unset($this->session_inclusion_criteria); - } - - /** - * Defines which sessions are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_inclusion_criteria = 1; - * @param \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $var - * @return $this - */ - public function setSessionInclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentCriteria::class); - $this->session_inclusion_criteria = $var; - - return $this; - } - - /** - * Defines which sessions are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; - * @return \Google\Analytics\Data\V1alpha\SessionSegmentExclusion|null - */ - public function getExclusion() - { - return $this->exclusion; - } - - public function hasExclusion() - { - return isset($this->exclusion); - } - - public function clearExclusion() - { - unset($this->exclusion); - } - - /** - * Defines which sessions are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentExclusion exclusion = 2; - * @param \Google\Analytics\Data\V1alpha\SessionSegmentExclusion $var - * @return $this - */ - public function setExclusion($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentExclusion::class); - $this->exclusion = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php deleted file mode 100644 index 54cfa44dc51..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentConditionGroup.php +++ /dev/null @@ -1,164 +0,0 @@ -google.analytics.data.v1alpha.SessionSegmentConditionGroup - */ -class SessionSegmentConditionGroup extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; - */ - protected $condition_scoping = 0; - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - */ - protected $segment_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $condition_scoping - * 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. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; - * @return int - */ - public function getConditionScoping() - { - return $this->condition_scoping; - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionCriteriaScoping condition_scoping = 1; - * @param int $var - * @return $this - */ - public function setConditionScoping($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\SessionCriteriaScoping::class); - $this->condition_scoping = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null - */ - public function getSegmentFilterExpression() - { - return $this->segment_filter_expression; - } - - public function hasSegmentFilterExpression() - { - return isset($this->segment_filter_expression); - } - - public function clearSegmentFilterExpression() - { - unset($this->segment_filter_expression); - } - - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var - * @return $this - */ - public function setSegmentFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->segment_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php deleted file mode 100644 index da0987320b8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentCriteria.php +++ /dev/null @@ -1,72 +0,0 @@ -google.analytics.data.v1alpha.SessionSegmentCriteria - */ -class SessionSegmentCriteria extends \Google\Protobuf\Internal\Message -{ - /** - * A session matches this criteria if the session matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; - */ - private $and_condition_groups; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups - * A session matches this criteria if the session matches each of these - * `andConditionGroups`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * A session matches this criteria if the session matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAndConditionGroups() - { - return $this->and_condition_groups; - } - - /** - * A session matches this criteria if the session matches each of these - * `andConditionGroups`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.SessionSegmentConditionGroup and_condition_groups = 1; - * @param array<\Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAndConditionGroups($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\SessionSegmentConditionGroup::class); - $this->and_condition_groups = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php deleted file mode 100644 index 7c6f5f25cf3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SessionSegmentExclusion.php +++ /dev/null @@ -1,127 +0,0 @@ -google.analytics.data.v1alpha.SessionSegmentExclusion - */ -class SessionSegmentExclusion extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies how long an exclusion will last if a session matches the - * `sessionExclusionCriteria`. - * Optional. If unspecified, a `sessionExclusionDuration` of - * `SESSION_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; - */ - protected $session_exclusion_duration = 0; - /** - * If a session meets this condition, the session is excluded from - * membership in the segment for the `sessionExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; - */ - protected $session_exclusion_criteria = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $session_exclusion_duration - * Specifies how long an exclusion will last if a session matches the - * `sessionExclusionCriteria`. - * Optional. If unspecified, a `sessionExclusionDuration` of - * `SESSION_EXCLUSION_TEMPORARY` is used. - * @type \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $session_exclusion_criteria - * If a session meets this condition, the session is excluded from - * membership in the segment for the `sessionExclusionDuration`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Specifies how long an exclusion will last if a session matches the - * `sessionExclusionCriteria`. - * Optional. If unspecified, a `sessionExclusionDuration` of - * `SESSION_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; - * @return int - */ - public function getSessionExclusionDuration() - { - return $this->session_exclusion_duration; - } - - /** - * Specifies how long an exclusion will last if a session matches the - * `sessionExclusionCriteria`. - * Optional. If unspecified, a `sessionExclusionDuration` of - * `SESSION_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionExclusionDuration session_exclusion_duration = 1; - * @param int $var - * @return $this - */ - public function setSessionExclusionDuration($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\SessionExclusionDuration::class); - $this->session_exclusion_duration = $var; - - return $this; - } - - /** - * If a session meets this condition, the session is excluded from - * membership in the segment for the `sessionExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; - * @return \Google\Analytics\Data\V1alpha\SessionSegmentCriteria|null - */ - public function getSessionExclusionCriteria() - { - return $this->session_exclusion_criteria; - } - - public function hasSessionExclusionCriteria() - { - return isset($this->session_exclusion_criteria); - } - - public function clearSessionExclusionCriteria() - { - unset($this->session_exclusion_criteria); - } - - /** - * If a session meets this condition, the session is excluded from - * membership in the segment for the `sessionExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SessionSegmentCriteria session_exclusion_criteria = 2; - * @param \Google\Analytics\Data\V1alpha\SessionSegmentCriteria $var - * @return $this - */ - public function setSessionExclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SessionSegmentCriteria::class); - $this->session_exclusion_criteria = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php deleted file mode 100644 index b431bc30f8f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListRequest.php +++ /dev/null @@ -1,206 +0,0 @@ -google.analytics.data.v1alpha.SheetExportAudienceListRequest - */ -class SheetExportAudienceListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $offset = 0; - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $limit = 0; - - /** - * @param string $name Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * Please see {@see AlphaAnalyticsDataClient::audienceListName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1alpha\SheetExportAudienceListRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @type int|string $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int|string $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getOffset() - { - return $this->offset; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setOffset($var) - { - GPBUtil::checkInt64($var); - $this->offset = $var; - - return $this; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php deleted file mode 100644 index e73e6e086e2..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/SheetExportAudienceListResponse.php +++ /dev/null @@ -1,253 +0,0 @@ -google.analytics.data.v1alpha.SheetExportAudienceListResponse - */ -class SheetExportAudienceListResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A uri for you to visit in your browser to view the Google Sheet. - * - * Generated from protobuf field optional string spreadsheet_uri = 1; - */ - protected $spreadsheet_uri = null; - /** - * An ID that identifies the created Google Sheet resource. - * - * Generated from protobuf field optional string spreadsheet_id = 2; - */ - protected $spreadsheet_id = null; - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - */ - protected $row_count = null; - /** - * Configuration data about AudienceList being exported. Returned to help - * interpret the AudienceList in the Google Sheet of this response. - * For example, the AudienceList may have more rows than are present in the - * Google Sheet, and in that case, you may want to send an additional sheet - * export request with a different `offset` value to retrieve the next page of - * rows in an additional Google Sheet. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; - */ - protected $audience_list = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $spreadsheet_uri - * A uri for you to visit in your browser to view the Google Sheet. - * @type string $spreadsheet_id - * An ID that identifies the created Google Sheet resource. - * @type int $row_count - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type \Google\Analytics\Data\V1alpha\AudienceList $audience_list - * Configuration data about AudienceList being exported. Returned to help - * interpret the AudienceList in the Google Sheet of this response. - * For example, the AudienceList may have more rows than are present in the - * Google Sheet, and in that case, you may want to send an additional sheet - * export request with a different `offset` value to retrieve the next page of - * rows in an additional Google Sheet. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * A uri for you to visit in your browser to view the Google Sheet. - * - * Generated from protobuf field optional string spreadsheet_uri = 1; - * @return string - */ - public function getSpreadsheetUri() - { - return isset($this->spreadsheet_uri) ? $this->spreadsheet_uri : ''; - } - - public function hasSpreadsheetUri() - { - return isset($this->spreadsheet_uri); - } - - public function clearSpreadsheetUri() - { - unset($this->spreadsheet_uri); - } - - /** - * A uri for you to visit in your browser to view the Google Sheet. - * - * Generated from protobuf field optional string spreadsheet_uri = 1; - * @param string $var - * @return $this - */ - public function setSpreadsheetUri($var) - { - GPBUtil::checkString($var, True); - $this->spreadsheet_uri = $var; - - return $this; - } - - /** - * An ID that identifies the created Google Sheet resource. - * - * Generated from protobuf field optional string spreadsheet_id = 2; - * @return string - */ - public function getSpreadsheetId() - { - return isset($this->spreadsheet_id) ? $this->spreadsheet_id : ''; - } - - public function hasSpreadsheetId() - { - return isset($this->spreadsheet_id); - } - - public function clearSpreadsheetId() - { - unset($this->spreadsheet_id); - } - - /** - * An ID that identifies the created Google Sheet resource. - * - * Generated from protobuf field optional string spreadsheet_id = 2; - * @param string $var - * @return $this - */ - public function setSpreadsheetId($var) - { - GPBUtil::checkString($var, True); - $this->spreadsheet_id = $var; - - return $this; - } - - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @return int - */ - public function getRowCount() - { - return isset($this->row_count) ? $this->row_count : 0; - } - - public function hasRowCount() - { - return isset($this->row_count); - } - - public function clearRowCount() - { - unset($this->row_count); - } - - /** - * The total number of rows in the AudienceList result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - - /** - * Configuration data about AudienceList being exported. Returned to help - * interpret the AudienceList in the Google Sheet of this response. - * For example, the AudienceList may have more rows than are present in the - * Google Sheet, and in that case, you may want to send an additional sheet - * export request with a different `offset` value to retrieve the next page of - * rows in an additional Google Sheet. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; - * @return \Google\Analytics\Data\V1alpha\AudienceList|null - */ - public function getAudienceList() - { - return $this->audience_list; - } - - public function hasAudienceList() - { - return isset($this->audience_list); - } - - public function clearAudienceList() - { - unset($this->audience_list); - } - - /** - * Configuration data about AudienceList being exported. Returned to help - * interpret the AudienceList in the Google Sheet of this response. - * For example, the AudienceList may have more rows than are present in the - * Google Sheet, and in that case, you may want to send an additional sheet - * export request with a different `offset` value to retrieve the next page of - * rows in an additional Google Sheet. - * - * Generated from protobuf field optional .google.analytics.data.v1alpha.AudienceList audience_list = 4; - * @param \Google\Analytics\Data\V1alpha\AudienceList $var - * @return $this - */ - public function setAudienceList($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\AudienceList::class); - $this->audience_list = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php deleted file mode 100644 index eb4772bde8f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter.php +++ /dev/null @@ -1,135 +0,0 @@ -google.analytics.data.v1alpha.StringFilter - */ -class StringFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; - */ - protected $match_type = 0; - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - */ - protected $value = ''; - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - */ - protected $case_sensitive = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $match_type - * The match type for this filter. - * @type string $value - * The string value used for the matching. - * @type bool $case_sensitive - * If true, the string value is case sensitive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; - * @return int - */ - public function getMatchType() - { - return $this->match_type; - } - - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1alpha.StringFilter.MatchType match_type = 1; - * @param int $var - * @return $this - */ - public function setMatchType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\StringFilter\MatchType::class); - $this->match_type = $var; - - return $this; - } - - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @return bool - */ - public function getCaseSensitive() - { - return $this->case_sensitive; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php deleted file mode 100644 index 8277a91a88c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/StringFilter/MatchType.php +++ /dev/null @@ -1,92 +0,0 @@ -google.analytics.data.v1alpha.StringFilter.MatchType - */ -class MatchType -{ - /** - * Unspecified - * - * Generated from protobuf enum MATCH_TYPE_UNSPECIFIED = 0; - */ - const MATCH_TYPE_UNSPECIFIED = 0; - /** - * Exact match of the string value. - * - * Generated from protobuf enum EXACT = 1; - */ - const EXACT = 1; - /** - * Begins with the string value. - * - * Generated from protobuf enum BEGINS_WITH = 2; - */ - const BEGINS_WITH = 2; - /** - * Ends with the string value. - * - * Generated from protobuf enum ENDS_WITH = 3; - */ - const ENDS_WITH = 3; - /** - * Contains the string value. - * - * Generated from protobuf enum CONTAINS = 4; - */ - const CONTAINS = 4; - /** - * Full match for the regular expression with the string value. - * - * Generated from protobuf enum FULL_REGEXP = 5; - */ - const FULL_REGEXP = 5; - /** - * Partial match for the regular expression with the string value. - * - * Generated from protobuf enum PARTIAL_REGEXP = 6; - */ - const PARTIAL_REGEXP = 6; - - private static $valueToName = [ - self::MATCH_TYPE_UNSPECIFIED => 'MATCH_TYPE_UNSPECIFIED', - self::EXACT => 'EXACT', - self::BEGINS_WITH => 'BEGINS_WITH', - self::ENDS_WITH => 'ENDS_WITH', - self::CONTAINS => 'CONTAINS', - self::FULL_REGEXP => 'FULL_REGEXP', - self::PARTIAL_REGEXP => 'PARTIAL_REGEXP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MatchType::class, \Google\Analytics\Data\V1alpha\StringFilter_MatchType::class); - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php deleted file mode 100644 index 3b9dcafc518..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserCriteriaScoping.php +++ /dev/null @@ -1,72 +0,0 @@ -google.analytics.data.v1alpha.UserCriteriaScoping - */ -class UserCriteriaScoping -{ - /** - * Unspecified criteria scoping. Do not specify. - * - * Generated from protobuf enum USER_CRITERIA_SCOPING_UNSPECIFIED = 0; - */ - const USER_CRITERIA_SCOPING_UNSPECIFIED = 0; - /** - * If the criteria is satisfied within one event, the user matches the - * criteria. - * - * Generated from protobuf enum USER_CRITERIA_WITHIN_SAME_EVENT = 1; - */ - const USER_CRITERIA_WITHIN_SAME_EVENT = 1; - /** - * If the criteria is satisfied within one session, the user matches the - * criteria. - * - * Generated from protobuf enum USER_CRITERIA_WITHIN_SAME_SESSION = 2; - */ - const USER_CRITERIA_WITHIN_SAME_SESSION = 2; - /** - * If the criteria is satisfied by any events for the user, the user - * matches the criteria. - * - * Generated from protobuf enum USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; - */ - const USER_CRITERIA_ACROSS_ALL_SESSIONS = 3; - - private static $valueToName = [ - self::USER_CRITERIA_SCOPING_UNSPECIFIED => 'USER_CRITERIA_SCOPING_UNSPECIFIED', - self::USER_CRITERIA_WITHIN_SAME_EVENT => 'USER_CRITERIA_WITHIN_SAME_EVENT', - self::USER_CRITERIA_WITHIN_SAME_SESSION => 'USER_CRITERIA_WITHIN_SAME_SESSION', - self::USER_CRITERIA_ACROSS_ALL_SESSIONS => 'USER_CRITERIA_ACROSS_ALL_SESSIONS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php deleted file mode 100644 index 8ea6e8aa479..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserExclusionDuration.php +++ /dev/null @@ -1,64 +0,0 @@ -google.analytics.data.v1alpha.UserExclusionDuration - */ -class UserExclusionDuration -{ - /** - * Unspecified exclusion duration. Do not specify. - * - * Generated from protobuf enum USER_EXCLUSION_DURATION_UNSPECIFIED = 0; - */ - const USER_EXCLUSION_DURATION_UNSPECIFIED = 0; - /** - * Temporarily exclude users from the segment during periods when the - * user meets the `userExclusionCriteria` condition. - * - * Generated from protobuf enum USER_EXCLUSION_TEMPORARY = 1; - */ - const USER_EXCLUSION_TEMPORARY = 1; - /** - * Permanently exclude users from the segment if the user ever meets the - * `userExclusionCriteria` condition. - * - * Generated from protobuf enum USER_EXCLUSION_PERMANENT = 2; - */ - const USER_EXCLUSION_PERMANENT = 2; - - private static $valueToName = [ - self::USER_EXCLUSION_DURATION_UNSPECIFIED => 'USER_EXCLUSION_DURATION_UNSPECIFIED', - self::USER_EXCLUSION_TEMPORARY => 'USER_EXCLUSION_TEMPORARY', - self::USER_EXCLUSION_PERMANENT => 'USER_EXCLUSION_PERMANENT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php deleted file mode 100644 index 0bfd9be4499..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegment.php +++ /dev/null @@ -1,123 +0,0 @@ -google.analytics.data.v1alpha.UserSegment - */ -class UserSegment extends \Google\Protobuf\Internal\Message -{ - /** - * Defines which users are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; - */ - protected $user_inclusion_criteria = null; - /** - * Defines which users are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; - */ - protected $exclusion = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1alpha\UserSegmentCriteria $user_inclusion_criteria - * Defines which users are included in this segment. Optional. - * @type \Google\Analytics\Data\V1alpha\UserSegmentExclusion $exclusion - * Defines which users are excluded in this segment. Optional. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Defines which users are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; - * @return \Google\Analytics\Data\V1alpha\UserSegmentCriteria|null - */ - public function getUserInclusionCriteria() - { - return $this->user_inclusion_criteria; - } - - public function hasUserInclusionCriteria() - { - return isset($this->user_inclusion_criteria); - } - - public function clearUserInclusionCriteria() - { - unset($this->user_inclusion_criteria); - } - - /** - * Defines which users are included in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_inclusion_criteria = 1; - * @param \Google\Analytics\Data\V1alpha\UserSegmentCriteria $var - * @return $this - */ - public function setUserInclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentCriteria::class); - $this->user_inclusion_criteria = $var; - - return $this; - } - - /** - * Defines which users are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; - * @return \Google\Analytics\Data\V1alpha\UserSegmentExclusion|null - */ - public function getExclusion() - { - return $this->exclusion; - } - - public function hasExclusion() - { - return isset($this->exclusion); - } - - public function clearExclusion() - { - unset($this->exclusion); - } - - /** - * Defines which users are excluded in this segment. Optional. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentExclusion exclusion = 2; - * @param \Google\Analytics\Data\V1alpha\UserSegmentExclusion $var - * @return $this - */ - public function setExclusion($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentExclusion::class); - $this->exclusion = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php deleted file mode 100644 index d2f547575d0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentConditionGroup.php +++ /dev/null @@ -1,164 +0,0 @@ -google.analytics.data.v1alpha.UserSegmentConditionGroup - */ -class UserSegmentConditionGroup extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; - */ - protected $condition_scoping = 0; - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - */ - protected $segment_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $condition_scoping - * 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. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; - * @return int - */ - public function getConditionScoping() - { - return $this->condition_scoping; - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping condition_scoping = 1; - * @param int $var - * @return $this - */ - public function setConditionScoping($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); - $this->condition_scoping = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null - */ - public function getSegmentFilterExpression() - { - return $this->segment_filter_expression; - } - - public function hasSegmentFilterExpression() - { - return isset($this->segment_filter_expression); - } - - public function clearSegmentFilterExpression() - { - unset($this->segment_filter_expression); - } - - /** - * Data is included or excluded from the segment based on if it matches - * this expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 2; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var - * @return $this - */ - public function setSegmentFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->segment_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php deleted file mode 100644 index 9e4f026d7e0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentCriteria.php +++ /dev/null @@ -1,118 +0,0 @@ -google.analytics.data.v1alpha.UserSegmentCriteria - */ -class UserSegmentCriteria extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; - */ - private $and_condition_groups; - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; - */ - private $and_sequence_groups; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1alpha\UserSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $and_condition_groups - * 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. - * @type array<\Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup>|\Google\Protobuf\Internal\RepeatedField $and_sequence_groups - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAndConditionGroups() - { - return $this->and_condition_groups; - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentConditionGroup and_condition_groups = 1; - * @param array<\Google\Analytics\Data\V1alpha\UserSegmentConditionGroup>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAndConditionGroups($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSegmentConditionGroup::class); - $this->and_condition_groups = $arr; - - 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAndSequenceGroups() - { - return $this->and_sequence_groups; - } - - /** - * 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSegmentSequenceGroup and_sequence_groups = 2; - * @param array<\Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAndSequenceGroups($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSegmentSequenceGroup::class); - $this->and_sequence_groups = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php deleted file mode 100644 index 25cff90f0b1..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentExclusion.php +++ /dev/null @@ -1,127 +0,0 @@ -google.analytics.data.v1alpha.UserSegmentExclusion - */ -class UserSegmentExclusion extends \Google\Protobuf\Internal\Message -{ - /** - * Specifies how long an exclusion will last if a user matches the - * `userExclusionCriteria`. - * Optional. If unspecified, `userExclusionDuration` of - * `USER_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; - */ - protected $user_exclusion_duration = 0; - /** - * If a user meets this condition, the user is excluded from membership in - * the segment for the `userExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; - */ - protected $user_exclusion_criteria = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $user_exclusion_duration - * Specifies how long an exclusion will last if a user matches the - * `userExclusionCriteria`. - * Optional. If unspecified, `userExclusionDuration` of - * `USER_EXCLUSION_TEMPORARY` is used. - * @type \Google\Analytics\Data\V1alpha\UserSegmentCriteria $user_exclusion_criteria - * If a user meets this condition, the user is excluded from membership in - * the segment for the `userExclusionDuration`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * Specifies how long an exclusion will last if a user matches the - * `userExclusionCriteria`. - * Optional. If unspecified, `userExclusionDuration` of - * `USER_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; - * @return int - */ - public function getUserExclusionDuration() - { - return $this->user_exclusion_duration; - } - - /** - * Specifies how long an exclusion will last if a user matches the - * `userExclusionCriteria`. - * Optional. If unspecified, `userExclusionDuration` of - * `USER_EXCLUSION_TEMPORARY` is used. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserExclusionDuration user_exclusion_duration = 1; - * @param int $var - * @return $this - */ - public function setUserExclusionDuration($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserExclusionDuration::class); - $this->user_exclusion_duration = $var; - - return $this; - } - - /** - * If a user meets this condition, the user is excluded from membership in - * the segment for the `userExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; - * @return \Google\Analytics\Data\V1alpha\UserSegmentCriteria|null - */ - public function getUserExclusionCriteria() - { - return $this->user_exclusion_criteria; - } - - public function hasUserExclusionCriteria() - { - return isset($this->user_exclusion_criteria); - } - - public function clearUserExclusionCriteria() - { - unset($this->user_exclusion_criteria); - } - - /** - * If a user meets this condition, the user is excluded from membership in - * the segment for the `userExclusionDuration`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserSegmentCriteria user_exclusion_criteria = 2; - * @param \Google\Analytics\Data\V1alpha\UserSegmentCriteria $var - * @return $this - */ - public function setUserExclusionCriteria($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\UserSegmentCriteria::class); - $this->user_exclusion_criteria = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php deleted file mode 100644 index 3f6d5d1ed4f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSegmentSequenceGroup.php +++ /dev/null @@ -1,202 +0,0 @@ -google.analytics.data.v1alpha.UserSegmentSequenceGroup - */ -class UserSegmentSequenceGroup extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; - */ - protected $sequence_scoping = 0; - /** - * 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. - * - * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; - */ - protected $sequence_maximum_duration = null; - /** - * An ordered sequence of condition steps. A user's events must complete - * each step in order for the user to match the - * `UserSegmentSequenceGroup`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; - */ - private $user_sequence_steps; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $sequence_scoping - * 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. - * @type \Google\Protobuf\Duration $sequence_maximum_duration - * 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. - * @type array<\Google\Analytics\Data\V1alpha\UserSequenceStep>|\Google\Protobuf\Internal\RepeatedField $user_sequence_steps - * An ordered sequence of condition steps. A user's events must complete - * each step in order for the user to match the - * `UserSegmentSequenceGroup`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; - * @return int - */ - public function getSequenceScoping() - { - return $this->sequence_scoping; - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping sequence_scoping = 1; - * @param int $var - * @return $this - */ - public function setSequenceScoping($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); - $this->sequence_scoping = $var; - - 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. - * - * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getSequenceMaximumDuration() - { - return $this->sequence_maximum_duration; - } - - public function hasSequenceMaximumDuration() - { - return isset($this->sequence_maximum_duration); - } - - public function clearSequenceMaximumDuration() - { - unset($this->sequence_maximum_duration); - } - - /** - * 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. - * - * Generated from protobuf field .google.protobuf.Duration sequence_maximum_duration = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setSequenceMaximumDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->sequence_maximum_duration = $var; - - 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`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUserSequenceSteps() - { - return $this->user_sequence_steps; - } - - /** - * An ordered sequence of condition steps. A user's events must complete - * each step in order for the user to match the - * `UserSegmentSequenceGroup`. - * - * Generated from protobuf field repeated .google.analytics.data.v1alpha.UserSequenceStep user_sequence_steps = 3; - * @param array<\Google\Analytics\Data\V1alpha\UserSequenceStep>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUserSequenceSteps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1alpha\UserSequenceStep::class); - $this->user_sequence_steps = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php deleted file mode 100644 index 25397518d56..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/UserSequenceStep.php +++ /dev/null @@ -1,198 +0,0 @@ -google.analytics.data.v1alpha.UserSequenceStep - */ -class UserSequenceStep extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field bool is_directly_followed_by = 1; - */ - protected $is_directly_followed_by = false; - /** - * 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`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; - */ - protected $step_scoping = 0; - /** - * A user matches this sequence step if their events match this - * expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; - */ - protected $segment_filter_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $is_directly_followed_by - * 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. - * @type int $step_scoping - * 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`. - * @type \Google\Analytics\Data\V1alpha\SegmentFilterExpression $segment_filter_expression - * A user matches this sequence step if their events match this - * expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field bool is_directly_followed_by = 1; - * @return bool - */ - public function getIsDirectlyFollowedBy() - { - return $this->is_directly_followed_by; - } - - /** - * 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. - * - * Generated from protobuf field bool is_directly_followed_by = 1; - * @param bool $var - * @return $this - */ - public function setIsDirectlyFollowedBy($var) - { - GPBUtil::checkBool($var); - $this->is_directly_followed_by = $var; - - 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`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; - * @return int - */ - public function getStepScoping() - { - return $this->step_scoping; - } - - /** - * 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`. - * - * Generated from protobuf field .google.analytics.data.v1alpha.UserCriteriaScoping step_scoping = 2; - * @param int $var - * @return $this - */ - public function setStepScoping($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1alpha\UserCriteriaScoping::class); - $this->step_scoping = $var; - - return $this; - } - - /** - * A user matches this sequence step if their events match this - * expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; - * @return \Google\Analytics\Data\V1alpha\SegmentFilterExpression|null - */ - public function getSegmentFilterExpression() - { - return $this->segment_filter_expression; - } - - public function hasSegmentFilterExpression() - { - return isset($this->segment_filter_expression); - } - - public function clearSegmentFilterExpression() - { - unset($this->segment_filter_expression); - } - - /** - * A user matches this sequence step if their events match this - * expression. Expressions express criteria on dimension, metrics, - * and/or parameters. - * - * Generated from protobuf field .google.analytics.data.v1alpha.SegmentFilterExpression segment_filter_expression = 3; - * @param \Google\Analytics\Data\V1alpha\SegmentFilterExpression $var - * @return $this - */ - public function setSegmentFilterExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1alpha\SegmentFilterExpression::class); - $this->segment_filter_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php b/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php deleted file mode 100644 index 7325fcd52a8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/proto/src/Google/Analytics/Data/V1alpha/WebhookNotification.php +++ /dev/null @@ -1,258 +0,0 @@ -google.analytics.data.v1alpha.WebhookNotification - */ -class WebhookNotification extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The web address that will receive the webhook notification. This - * address will receive POST requests as the state of the long running - * operation resource changes. The POST request will contain both a JSON - * version of the long running operation resource in the body and a - * `sentTimestamp` field. The sent timestamp will specify the unix - * microseconds since the epoch that the request was sent; this lets you - * identify replayed notifications. - * An example URI is - * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. - * The URI must use HTTPS and point to a site with a valid SSL certificate on - * the web server. The URI must have a maximum string length of 128 characters - * & use only the allowlisted characters from [RFC - * 1738](https://www.rfc-editor.org/rfc/rfc1738). - * When your webhook server receives a notification, it is expected to reply - * with an HTTP response status code of 200 within 5 seconds. - * A URI is required to use webhook notifications. - * Requests to this webhook server will contain an ID token authenticating the - * service account - * `google-analytics-audience-export@system.gserviceaccount.com`. To learn - * more about ID tokens, see - * https://cloud.google.com/docs/authentication/token-types#id. For Google - * Cloud Functions, this lets you configure your function to require - * authentication. In Cloud IAM, you will need to grant the service account - * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud - * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook - * post request to pass Google Cloud Functions authentication. This API can - * send webhook notifications to arbitrary URIs; for webhook servers other - * than Google Cloud Functions, this ID token in the authorization bearer - * header should be ignored if it is not needed. - * - * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $uri = null; - /** - * Optional. The channel token is an arbitrary string value and must have a - * maximum string length of 64 characters. Channel tokens allow you to verify - * the source of a webhook notification. This guards against the message being - * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` - * HTTP header of the webhook POST request. - * A channel token is not required to use webhook notifications. - * - * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $channel_token = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * Optional. The web address that will receive the webhook notification. This - * address will receive POST requests as the state of the long running - * operation resource changes. The POST request will contain both a JSON - * version of the long running operation resource in the body and a - * `sentTimestamp` field. The sent timestamp will specify the unix - * microseconds since the epoch that the request was sent; this lets you - * identify replayed notifications. - * An example URI is - * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. - * The URI must use HTTPS and point to a site with a valid SSL certificate on - * the web server. The URI must have a maximum string length of 128 characters - * & use only the allowlisted characters from [RFC - * 1738](https://www.rfc-editor.org/rfc/rfc1738). - * When your webhook server receives a notification, it is expected to reply - * with an HTTP response status code of 200 within 5 seconds. - * A URI is required to use webhook notifications. - * Requests to this webhook server will contain an ID token authenticating the - * service account - * `google-analytics-audience-export@system.gserviceaccount.com`. To learn - * more about ID tokens, see - * https://cloud.google.com/docs/authentication/token-types#id. For Google - * Cloud Functions, this lets you configure your function to require - * authentication. In Cloud IAM, you will need to grant the service account - * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud - * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook - * post request to pass Google Cloud Functions authentication. This API can - * send webhook notifications to arbitrary URIs; for webhook servers other - * than Google Cloud Functions, this ID token in the authorization bearer - * header should be ignored if it is not needed. - * @type string $channel_token - * Optional. The channel token is an arbitrary string value and must have a - * maximum string length of 64 characters. Channel tokens allow you to verify - * the source of a webhook notification. This guards against the message being - * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` - * HTTP header of the webhook POST request. - * A channel token is not required to use webhook notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Alpha\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The web address that will receive the webhook notification. This - * address will receive POST requests as the state of the long running - * operation resource changes. The POST request will contain both a JSON - * version of the long running operation resource in the body and a - * `sentTimestamp` field. The sent timestamp will specify the unix - * microseconds since the epoch that the request was sent; this lets you - * identify replayed notifications. - * An example URI is - * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. - * The URI must use HTTPS and point to a site with a valid SSL certificate on - * the web server. The URI must have a maximum string length of 128 characters - * & use only the allowlisted characters from [RFC - * 1738](https://www.rfc-editor.org/rfc/rfc1738). - * When your webhook server receives a notification, it is expected to reply - * with an HTTP response status code of 200 within 5 seconds. - * A URI is required to use webhook notifications. - * Requests to this webhook server will contain an ID token authenticating the - * service account - * `google-analytics-audience-export@system.gserviceaccount.com`. To learn - * more about ID tokens, see - * https://cloud.google.com/docs/authentication/token-types#id. For Google - * Cloud Functions, this lets you configure your function to require - * authentication. In Cloud IAM, you will need to grant the service account - * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud - * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook - * post request to pass Google Cloud Functions authentication. This API can - * send webhook notifications to arbitrary URIs; for webhook servers other - * than Google Cloud Functions, this ID token in the authorization bearer - * header should be ignored if it is not needed. - * - * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getUri() - { - return isset($this->uri) ? $this->uri : ''; - } - - public function hasUri() - { - return isset($this->uri); - } - - public function clearUri() - { - unset($this->uri); - } - - /** - * Optional. The web address that will receive the webhook notification. This - * address will receive POST requests as the state of the long running - * operation resource changes. The POST request will contain both a JSON - * version of the long running operation resource in the body and a - * `sentTimestamp` field. The sent timestamp will specify the unix - * microseconds since the epoch that the request was sent; this lets you - * identify replayed notifications. - * An example URI is - * `https://us-central1-example-project-id.cloudfunctions.net/example-function-1`. - * The URI must use HTTPS and point to a site with a valid SSL certificate on - * the web server. The URI must have a maximum string length of 128 characters - * & use only the allowlisted characters from [RFC - * 1738](https://www.rfc-editor.org/rfc/rfc1738). - * When your webhook server receives a notification, it is expected to reply - * with an HTTP response status code of 200 within 5 seconds. - * A URI is required to use webhook notifications. - * Requests to this webhook server will contain an ID token authenticating the - * service account - * `google-analytics-audience-export@system.gserviceaccount.com`. To learn - * more about ID tokens, see - * https://cloud.google.com/docs/authentication/token-types#id. For Google - * Cloud Functions, this lets you configure your function to require - * authentication. In Cloud IAM, you will need to grant the service account - * permissions to the Cloud Run Invoker (`roles/run.invoker`) & Cloud - * Functions Invoker (`roles/cloudfunctions.invoker`) roles for the webhook - * post request to pass Google Cloud Functions authentication. This API can - * send webhook notifications to arbitrary URIs; for webhook servers other - * than Google Cloud Functions, this ID token in the authorization bearer - * header should be ignored if it is not needed. - * - * Generated from protobuf field optional string uri = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Optional. The channel token is an arbitrary string value and must have a - * maximum string length of 64 characters. Channel tokens allow you to verify - * the source of a webhook notification. This guards against the message being - * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` - * HTTP header of the webhook POST request. - * A channel token is not required to use webhook notifications. - * - * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getChannelToken() - { - return isset($this->channel_token) ? $this->channel_token : ''; - } - - public function hasChannelToken() - { - return isset($this->channel_token); - } - - public function clearChannelToken() - { - unset($this->channel_token); - } - - /** - * Optional. The channel token is an arbitrary string value and must have a - * maximum string length of 64 characters. Channel tokens allow you to verify - * the source of a webhook notification. This guards against the message being - * spoofed. The channel token will be specified in the `X-Goog-Channel-Token` - * HTTP header of the webhook POST request. - * A channel token is not required to use webhook notifications. - * - * Generated from protobuf field optional string channel_token = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setChannelToken($var) - { - GPBUtil::checkString($var, True); - $this->channel_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php deleted file mode 100644 index 60f00596f47..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php +++ /dev/null @@ -1,119 +0,0 @@ -setAudience($audienceListAudience) - ->setDimensions($audienceListDimensions); - $request = (new CreateAudienceListRequest()) - ->setParent($formattedParent) - ->setAudienceList($audienceList); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $alphaAnalyticsDataClient->createAudienceList($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AudienceList $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); - $audienceListAudience = '[AUDIENCE]'; - - create_audience_list_sample($formattedParent, $audienceListAudience); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_CreateAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php deleted file mode 100644 index 3c4f80ae7c6..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php +++ /dev/null @@ -1,103 +0,0 @@ -setAudience($recurringAudienceListAudience) - ->setDimensions($recurringAudienceListDimensions); - $request = (new CreateRecurringAudienceListRequest()) - ->setParent($formattedParent) - ->setRecurringAudienceList($recurringAudienceList); - - // Call the API and handle any network failures. - try { - /** @var RecurringAudienceList $response */ - $response = $alphaAnalyticsDataClient->createRecurringAudienceList($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); - $recurringAudienceListAudience = '[AUDIENCE]'; - - create_recurring_audience_list_sample($formattedParent, $recurringAudienceListAudience); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_CreateRecurringAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php deleted file mode 100644 index 55c893ca826..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var AudienceList $response */ - $response = $alphaAnalyticsDataClient->getAudienceList($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = AlphaAnalyticsDataClient::audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - - get_audience_list_sample($formattedName); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_GetAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php deleted file mode 100644 index 2288cc91d97..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php +++ /dev/null @@ -1,86 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var RecurringAudienceList $response */ - $response = $alphaAnalyticsDataClient->getRecurringAudienceList($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = AlphaAnalyticsDataClient::recurringAudienceListName( - '[PROPERTY]', - '[RECURRING_AUDIENCE_LIST]' - ); - - get_recurring_audience_list_sample($formattedName); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_GetRecurringAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php deleted file mode 100644 index dac54f22283..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php +++ /dev/null @@ -1,90 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $alphaAnalyticsDataClient->listAudienceLists($request); - - /** @var AudienceList $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); - - list_audience_lists_sample($formattedParent); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_ListAudienceLists_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php deleted file mode 100644 index 6f67c56ae5d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php +++ /dev/null @@ -1,88 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $alphaAnalyticsDataClient->listRecurringAudienceLists($request); - - /** @var RecurringAudienceList $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = AlphaAnalyticsDataClient::propertyName('[PROPERTY]'); - - list_recurring_audience_lists_sample($formattedParent); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_ListRecurringAudienceLists_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php deleted file mode 100644 index e4d3e33d8d4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php +++ /dev/null @@ -1,88 +0,0 @@ -setName($name); - - // Call the API and handle any network failures. - try { - /** @var QueryAudienceListResponse $response */ - $response = $alphaAnalyticsDataClient->queryAudienceList($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $name = '[NAME]'; - - query_audience_list_sample($name); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_QueryAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php deleted file mode 100644 index 8d202612edc..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php +++ /dev/null @@ -1,72 +0,0 @@ -runFunnelReport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_RunFunnelReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php b/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php deleted file mode 100644 index 9d9a4259c3c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var SheetExportAudienceListResponse $response */ - $response = $alphaAnalyticsDataClient->sheetExportAudienceList($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = AlphaAnalyticsDataClient::audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - - sheet_export_audience_list_sample($formattedName); -} -// [END analyticsdata_v1alpha_generated_AlphaAnalyticsData_SheetExportAudienceList_sync] diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php deleted file mode 100644 index ca7d0b50ee3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/AlphaAnalyticsDataClient.php +++ /dev/null @@ -1,36 +0,0 @@ - self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/alpha_analytics_data_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_rest_client_config.php', - ], - ], - ]; - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - * - * @experimental - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - * - * @experimental - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * audience_list resource. - * - * @param string $property - * @param string $audienceList - * - * @return string The formatted audience_list resource. - * - * @experimental - */ - public static function audienceListName(string $property, string $audienceList): string - { - return self::getPathTemplate('audienceList')->render([ - 'property' => $property, - 'audience_list' => $audienceList, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a property - * resource. - * - * @param string $property - * - * @return string The formatted property resource. - * - * @experimental - */ - public static function propertyName(string $property): string - { - return self::getPathTemplate('property')->render([ - 'property' => $property, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * recurring_audience_list resource. - * - * @param string $property - * @param string $recurringAudienceList - * - * @return string The formatted recurring_audience_list resource. - * - * @experimental - */ - public static function recurringAudienceListName(string $property, string $recurringAudienceList): string - { - return self::getPathTemplate('recurringAudienceList')->render([ - 'property' => $property, - 'recurring_audience_list' => $recurringAudienceList, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a report_task - * resource. - * - * @param string $property - * @param string $reportTask - * - * @return string The formatted report_task resource. - * - * @experimental - */ - public static function reportTaskName(string $property, string $reportTask): string - { - return self::getPathTemplate('reportTask')->render([ - 'property' => $property, - 'report_task' => $reportTask, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - audienceList: properties/{property}/audienceLists/{audience_list} - * - property: properties/{property} - * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} - * - reportTask: properties/{property}/reportTasks/{report_task} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName(string $formattedName, string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticsdata.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates an audience list for later retrieval. This method quickly returns - * the audience list's resource name and initiates a long running asynchronous - * request to form an audience list. To list the users in an audience list, - * first create the audience list through this method and then send the - * audience resource name to the `QueryAudienceList` method. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * An audience list is a snapshot of the users currently in the audience at - * the time of audience list creation. Creating audience lists for one - * audience on different days will return different results as users enter and - * exit the audience. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. Audience lists contain - * the users in each audience. - * - * This method is available at beta stability at - * [audienceExports.create](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/create). - * To give your feedback on this API, complete the [Google Analytics Audience - * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see AlphaAnalyticsDataClient::createAudienceListAsync()} - * . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/create_audience_list.php - * - * @param CreateAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function createAudienceList(CreateAudienceListRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateAudienceList', $request, $callOptions)->wait(); - } - - /** - * Creates a recurring audience list. Recurring audience lists produces new - * audience lists each day. Audience lists are users in an audience at the - * time of the list's creation. - * - * A recurring audience list ensures that you have audience list based on the - * most recent data available for use each day. If you manually create - * audience list, you don't know when an audience list based on an additional - * day's data is available. This recurring audience list automates the - * creation of an audience list when an additional day's data is available. - * You will consume fewer quota tokens by using recurring audience list versus - * manually creating audience list at various times of day trying to guess - * when an additional day's data is ready. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is - * {@see AlphaAnalyticsDataClient::createRecurringAudienceListAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/create_recurring_audience_list.php - * - * @param CreateRecurringAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RecurringAudienceList - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function createRecurringAudienceList(CreateRecurringAudienceListRequest $request, array $callOptions = []): RecurringAudienceList - { - return $this->startApiCall('CreateRecurringAudienceList', $request, $callOptions)->wait(); - } - - /** - * Initiates the creation of a report task. This method quickly - * returns a report task and initiates a long running - * asynchronous request to form a customized report of your Google Analytics - * event data. - * - * The async variant is {@see AlphaAnalyticsDataClient::createReportTaskAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/create_report_task.php - * - * @param CreateReportTaskRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function createReportTask(CreateReportTaskRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateReportTask', $request, $callOptions)->wait(); - } - - /** - * Gets configuration metadata about a specific audience list. This method - * can be used to understand an audience list after it has been created. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * This method is available at beta stability at - * [audienceExports.get](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/get). - * To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see AlphaAnalyticsDataClient::getAudienceListAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/get_audience_list.php - * - * @param GetAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return AudienceList - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function getAudienceList(GetAudienceListRequest $request, array $callOptions = []): AudienceList - { - return $this->startApiCall('GetAudienceList', $request, $callOptions)->wait(); - } - - /** - * Gets configuration metadata about a specific recurring audience list. This - * method can be used to understand a recurring audience list's state after it - * has been created. For example, a recurring audience list resource will - * generate audience list instances for each day, and this method can be used - * to get the resource name of the most recent audience list instance. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is - * {@see AlphaAnalyticsDataClient::getRecurringAudienceListAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/get_recurring_audience_list.php - * - * @param GetRecurringAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RecurringAudienceList - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function getRecurringAudienceList(GetRecurringAudienceListRequest $request, array $callOptions = []): RecurringAudienceList - { - return $this->startApiCall('GetRecurringAudienceList', $request, $callOptions)->wait(); - } - - /** - * Gets report metadata about a specific report task. After creating a report - * task, use this method to check its processing state or inspect its - * report definition. - * - * The async variant is {@see AlphaAnalyticsDataClient::getReportTaskAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/get_report_task.php - * - * @param GetReportTaskRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ReportTask - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function getReportTask(GetReportTaskRequest $request, array $callOptions = []): ReportTask - { - return $this->startApiCall('GetReportTask', $request, $callOptions)->wait(); - } - - /** - * Lists all audience lists for a property. This method can be used for you to - * find and reuse existing audience lists rather than creating unnecessary new - * audience lists. The same audience can have multiple audience lists that - * represent the list of users that were in an audience on different days. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * This method is available at beta stability at - * [audienceExports.list](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/list). - * To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see AlphaAnalyticsDataClient::listAudienceListsAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/list_audience_lists.php - * - * @param ListAudienceListsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function listAudienceLists(ListAudienceListsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListAudienceLists', $request, $callOptions); - } - - /** - * Lists all recurring audience lists for a property. This method can be used - * for you to find and reuse existing recurring audience lists rather than - * creating unnecessary new recurring audience lists. The same audience can - * have multiple recurring audience lists that represent different dimension - * combinations; for example, just the dimension `deviceId` or both the - * dimensions `deviceId` and `userId`. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is - * {@see AlphaAnalyticsDataClient::listRecurringAudienceListsAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/list_recurring_audience_lists.php - * - * @param ListRecurringAudienceListsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function listRecurringAudienceLists(ListRecurringAudienceListsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListRecurringAudienceLists', $request, $callOptions); - } - - /** - * Lists all report tasks for a property. - * - * The async variant is {@see AlphaAnalyticsDataClient::listReportTasksAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/list_report_tasks.php - * - * @param ListReportTasksRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function listReportTasks(ListReportTasksRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListReportTasks', $request, $callOptions); - } - - /** - * Retrieves an audience list of users. After creating an audience, the users - * are not immediately available for listing. First, a request to - * `CreateAudienceList` is necessary to create an audience list of users, and - * then second, this method is used to retrieve the users in the audience - * list. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * This method is available at beta stability at - * [audienceExports.query](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/query). - * To give your feedback on this API, complete the [Google Analytics Audience - * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see AlphaAnalyticsDataClient::queryAudienceListAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/query_audience_list.php - * - * @param QueryAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return QueryAudienceListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function queryAudienceList(QueryAudienceListRequest $request, array $callOptions = []): QueryAudienceListResponse - { - return $this->startApiCall('QueryAudienceList', $request, $callOptions)->wait(); - } - - /** - * Retrieves a report task's content. After requesting the `CreateReportTask`, - * you are able to retrieve the report content once the report is - * ACTIVE. This method will return an error if the report task's state is not - * `ACTIVE`. A query response will return the tabular row & column values of - * the report. - * - * The async variant is {@see AlphaAnalyticsDataClient::queryReportTaskAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/query_report_task.php - * - * @param QueryReportTaskRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return QueryReportTaskResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function queryReportTask(QueryReportTaskRequest $request, array $callOptions = []): QueryReportTaskResponse - { - return $this->startApiCall('QueryReportTask', $request, $callOptions)->wait(); - } - - /** - * 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). - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the [Google Analytics Data API Funnel - * Reporting - * Feedback](https://docs.google.com/forms/d/e/1FAIpQLSdwOlQDJAUoBiIgUZZ3S_Lwi8gr7Bb0k1jhvc-DEg7Rol3UjA/viewform). - * - * The async variant is {@see AlphaAnalyticsDataClient::runFunnelReportAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/run_funnel_report.php - * - * @param RunFunnelReportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RunFunnelReportResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function runFunnelReport(RunFunnelReportRequest $request, array $callOptions = []): RunFunnelReportResponse - { - return $this->startApiCall('RunFunnelReport', $request, $callOptions)->wait(); - } - - /** - * Exports an audience list of users to a Google Sheet. After creating an - * audience, the users are not immediately available for listing. First, a - * request to `CreateAudienceList` is necessary to create an audience list of - * users, and then second, this method is used to export those users in the - * audience list to a Google Sheet. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is - * {@see AlphaAnalyticsDataClient::sheetExportAudienceListAsync()} . - * - * @example samples/V1alpha/AlphaAnalyticsDataClient/sheet_export_audience_list.php - * - * @param SheetExportAudienceListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SheetExportAudienceListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function sheetExportAudienceList(SheetExportAudienceListRequest $request, array $callOptions = []): SheetExportAudienceListResponse - { - return $this->startApiCall('SheetExportAudienceList', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php deleted file mode 100644 index a63144e6ee9..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/Gapic/AlphaAnalyticsDataGapicClient.php +++ /dev/null @@ -1,1477 +0,0 @@ -propertyName('[PROPERTY]'); - * $audienceList = new AudienceList(); - * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceList'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * 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 parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @experimental - * - * @deprecated Please use the new service client {@see \Google\Analytics\Data\V1alpha\Client\AlphaAnalyticsDataClient}. - */ -class AlphaAnalyticsDataGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.analytics.data.v1alpha.AlphaAnalyticsData'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'analyticsdata.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'analyticsdata.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/analytics', - 'https://www.googleapis.com/auth/analytics.readonly', - 'https://www.googleapis.com/auth/drive', - 'https://www.googleapis.com/auth/drive.file', - 'https://www.googleapis.com/auth/spreadsheets', - ]; - - private static $audienceListNameTemplate; - - private static $propertyNameTemplate; - - private static $recurringAudienceListNameTemplate; - - private static $reportTaskNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/alpha_analytics_data_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/alpha_analytics_data_rest_client_config.php', - ], - ], - ]; - } - - private static function getAudienceListNameTemplate() - { - if (self::$audienceListNameTemplate == null) { - self::$audienceListNameTemplate = new PathTemplate('properties/{property}/audienceLists/{audience_list}'); - } - - return self::$audienceListNameTemplate; - } - - private static function getPropertyNameTemplate() - { - if (self::$propertyNameTemplate == null) { - self::$propertyNameTemplate = new PathTemplate('properties/{property}'); - } - - return self::$propertyNameTemplate; - } - - private static function getRecurringAudienceListNameTemplate() - { - if (self::$recurringAudienceListNameTemplate == null) { - self::$recurringAudienceListNameTemplate = new PathTemplate('properties/{property}/recurringAudienceLists/{recurring_audience_list}'); - } - - return self::$recurringAudienceListNameTemplate; - } - - private static function getReportTaskNameTemplate() - { - if (self::$reportTaskNameTemplate == null) { - self::$reportTaskNameTemplate = new PathTemplate('properties/{property}/reportTasks/{report_task}'); - } - - return self::$reportTaskNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'audienceList' => self::getAudienceListNameTemplate(), - 'property' => self::getPropertyNameTemplate(), - 'recurringAudienceList' => self::getRecurringAudienceListNameTemplate(), - 'reportTask' => self::getReportTaskNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * audience_list resource. - * - * @param string $property - * @param string $audienceList - * - * @return string The formatted audience_list resource. - * - * @experimental - */ - public static function audienceListName($property, $audienceList) - { - return self::getAudienceListNameTemplate()->render([ - 'property' => $property, - 'audience_list' => $audienceList, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a property - * resource. - * - * @param string $property - * - * @return string The formatted property resource. - * - * @experimental - */ - public static function propertyName($property) - { - return self::getPropertyNameTemplate()->render([ - 'property' => $property, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * recurring_audience_list resource. - * - * @param string $property - * @param string $recurringAudienceList - * - * @return string The formatted recurring_audience_list resource. - * - * @experimental - */ - public static function recurringAudienceListName($property, $recurringAudienceList) - { - return self::getRecurringAudienceListNameTemplate()->render([ - 'property' => $property, - 'recurring_audience_list' => $recurringAudienceList, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a report_task - * resource. - * - * @param string $property - * @param string $reportTask - * - * @return string The formatted report_task resource. - * - * @experimental - */ - public static function reportTaskName($property, $reportTask) - { - return self::getReportTaskNameTemplate()->render([ - 'property' => $property, - 'report_task' => $reportTask, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - audienceList: properties/{property}/audienceLists/{audience_list} - * - property: properties/{property} - * - recurringAudienceList: properties/{property}/recurringAudienceLists/{recurring_audience_list} - * - reportTask: properties/{property}/reportTasks/{report_task} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - * - * @experimental - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - * - * @experimental - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticsdata.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates an audience list for later retrieval. This method quickly returns - * the audience list's resource name and initiates a long running asynchronous - * request to form an audience list. To list the users in an audience list, - * first create the audience list through this method and then send the - * audience resource name to the `QueryAudienceList` method. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * An audience list is a snapshot of the users currently in the audience at - * the time of audience list creation. Creating audience lists for one - * audience on different days will return different results as users enter and - * exit the audience. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. Audience lists contain - * the users in each audience. - * - * This method is available at beta stability at - * [audienceExports.create](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/create). - * To give your feedback on this API, complete the [Google Analytics Audience - * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * $audienceList = new AudienceList(); - * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $alphaAnalyticsDataClient->createAudienceList($formattedParent, $audienceList); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceList'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource where this audience list will be created. - * Format: `properties/{property}` - * @param AudienceList $audienceList Required. The audience list to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createAudienceList($parent, $audienceList, array $optionalArgs = []) - { - $request = new CreateAudienceListRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAudienceList($audienceList); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateAudienceList', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a recurring audience list. Recurring audience lists produces new - * audience lists each day. Audience lists are users in an audience at the - * time of the list's creation. - * - * A recurring audience list ensures that you have audience list based on the - * most recent data available for use each day. If you manually create - * audience list, you don't know when an audience list based on an additional - * day's data is available. This recurring audience list automates the - * creation of an audience list when an additional day's data is available. - * You will consume fewer quota tokens by using recurring audience list versus - * manually creating audience list at various times of day trying to guess - * when an additional day's data is ready. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * $recurringAudienceList = new RecurringAudienceList(); - * $response = $alphaAnalyticsDataClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource where this recurring audience list will be - * created. Format: `properties/{property}` - * @param RecurringAudienceList $recurringAudienceList Required. The recurring audience list to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createRecurringAudienceList($parent, $recurringAudienceList, array $optionalArgs = []) - { - $request = new CreateRecurringAudienceListRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setRecurringAudienceList($recurringAudienceList); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateRecurringAudienceList', RecurringAudienceList::class, $optionalArgs, $request)->wait(); - } - - /** - * Initiates the creation of a report task. This method quickly - * returns a report task and initiates a long running - * asynchronous request to form a customized report of your Google Analytics - * event data. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * $reportTask = new ReportTask(); - * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $alphaAnalyticsDataClient->createReportTask($formattedParent, $reportTask); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $alphaAnalyticsDataClient->resumeOperation($operationName, 'createReportTask'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource where this report task will be created. - * Format: `properties/{propertyId}` - * @param ReportTask $reportTask Required. The report task configuration to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createReportTask($parent, $reportTask, array $optionalArgs = []) - { - $request = new CreateReportTaskRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setReportTask($reportTask); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateReportTask', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets configuration metadata about a specific audience list. This method - * can be used to understand an audience list after it has been created. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * This method is available at beta stability at - * [audienceExports.get](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/get). - * To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedName = $alphaAnalyticsDataClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - * $response = $alphaAnalyticsDataClient->getAudienceList($formattedName); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The audience list resource name. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\AudienceList - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getAudienceList($name, array $optionalArgs = []) - { - $request = new GetAudienceListRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetAudienceList', AudienceList::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets configuration metadata about a specific recurring audience list. This - * method can be used to understand a recurring audience list's state after it - * has been created. For example, a recurring audience list resource will - * generate audience list instances for each day, and this method can be used - * to get the resource name of the most recent audience list instance. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedName = $alphaAnalyticsDataClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); - * $response = $alphaAnalyticsDataClient->getRecurringAudienceList($formattedName); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The recurring audience list resource name. - * Format: - * `properties/{property}/recurringAudienceLists/{recurring_audience_list}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\RecurringAudienceList - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getRecurringAudienceList($name, array $optionalArgs = []) - { - $request = new GetRecurringAudienceListRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetRecurringAudienceList', RecurringAudienceList::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets report metadata about a specific report task. After creating a report - * task, use this method to check its processing state or inspect its - * report definition. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedName = $alphaAnalyticsDataClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); - * $response = $alphaAnalyticsDataClient->getReportTask($formattedName); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The report task resource name. - * Format: `properties/{property}/reportTasks/{report_task}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\ReportTask - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getReportTask($name, array $optionalArgs = []) - { - $request = new GetReportTaskRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetReportTask', ReportTask::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists all audience lists for a property. This method can be used for you to - * find and reuse existing audience lists rather than creating unnecessary new - * audience lists. The same audience can have multiple audience lists that - * represent the list of users that were in an audience on different days. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * This method is available at beta stability at - * [audienceExports.list](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/list). - * To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * // Iterate over pages of elements - * $pagedResponse = $alphaAnalyticsDataClient->listAudienceLists($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $alphaAnalyticsDataClient->listAudienceLists($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. All audience lists for this property will be listed in the - * response. Format: `properties/{property}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listAudienceLists($parent, array $optionalArgs = []) - { - $request = new ListAudienceListsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAudienceLists', $optionalArgs, ListAudienceListsResponse::class, $request); - } - - /** - * Lists all recurring audience lists for a property. This method can be used - * for you to find and reuse existing recurring audience lists rather than - * creating unnecessary new recurring audience lists. The same audience can - * have multiple recurring audience lists that represent different dimension - * combinations; for example, just the dimension `deviceId` or both the - * dimensions `deviceId` and `userId`. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * // Iterate over pages of elements - * $pagedResponse = $alphaAnalyticsDataClient->listRecurringAudienceLists($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $alphaAnalyticsDataClient->listRecurringAudienceLists($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. All recurring audience lists for this property will be listed in - * the response. Format: `properties/{property}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listRecurringAudienceLists($parent, array $optionalArgs = []) - { - $request = new ListRecurringAudienceListsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListRecurringAudienceLists', $optionalArgs, ListRecurringAudienceListsResponse::class, $request); - } - - /** - * Lists all report tasks for a property. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedParent = $alphaAnalyticsDataClient->propertyName('[PROPERTY]'); - * // Iterate over pages of elements - * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $alphaAnalyticsDataClient->listReportTasks($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. All report tasks for this property will be listed in the - * response. Format: `properties/{property}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listReportTasks($parent, array $optionalArgs = []) - { - $request = new ListReportTasksRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListReportTasks', $optionalArgs, ListReportTasksResponse::class, $request); - } - - /** - * Retrieves an audience list of users. After creating an audience, the users - * are not immediately available for listing. First, a request to - * `CreateAudienceList` is necessary to create an audience list of users, and - * then second, this method is used to retrieve the users in the audience - * list. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * This method is available at beta stability at - * [audienceExports.query](https://developers.google.com/analytics/devguides/reporting/data/v1/rest/v1beta/properties.audienceExports/query). - * To give your feedback on this API, complete the [Google Analytics Audience - * Export API Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $name = 'name'; - * $response = $alphaAnalyticsDataClient->queryAudienceList($name); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @param array $optionalArgs { - * Optional. - * - * @type int $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\QueryAudienceListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function queryAudienceList($name, array $optionalArgs = []) - { - $request = new QueryAudienceListRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['offset'])) { - $request->setOffset($optionalArgs['offset']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('QueryAudienceList', QueryAudienceListResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Retrieves a report task's content. After requesting the `CreateReportTask`, - * you are able to retrieve the report content once the report is - * ACTIVE. This method will return an error if the report task's state is not - * `ACTIVE`. A query response will return the tabular row & column values of - * the report. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $name = 'name'; - * $response = $alphaAnalyticsDataClient->queryReportTask($name); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The report source name. - * Format: `properties/{property}/reportTasks/{report}` - * @param array $optionalArgs { - * Optional. - * - * @type int $offset - * Optional. The row count of the start row in the report. The first row is - * counted as row 0. - * - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int $limit - * Optional. The number of rows to return from the report. If unspecified, - * 10,000 rows are returned. The API returns a maximum of 250,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`. The number of rows - * available to a QueryReportTaskRequest is further limited by the limit of - * the associated ReportTask. A query can retrieve at most ReportTask.limit - * rows. For example, if the ReportTask has a limit of 1,000, then a - * QueryReportTask request with offset=900 and limit=500 will return at most - * 100 rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\QueryReportTaskResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function queryReportTask($name, array $optionalArgs = []) - { - $request = new QueryReportTaskRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['offset'])) { - $request->setOffset($optionalArgs['offset']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('QueryReportTask', QueryReportTaskResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * 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). - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the [Google Analytics Data API Funnel - * Reporting - * Feedback](https://docs.google.com/forms/d/e/1FAIpQLSdwOlQDJAUoBiIgUZZ3S_Lwi8gr7Bb0k1jhvc-DEg7Rol3UjA/viewform). - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $response = $alphaAnalyticsDataClient->runFunnelReport(); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $property - * Optional. 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 - * @type DateRange[] $dateRanges - * Optional. 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. - * @type Funnel $funnel - * Optional. The configuration of this request's funnel. This funnel - * configuration is required. - * @type FunnelBreakdown $funnelBreakdown - * Optional. 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. - * @type FunnelNextAction $funnelNextAction - * Optional. 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 next - * action of the `eventName` dimension will create rows for several events - * (for example `session_start` & `click`) and the total. - * - * Next action only supports `eventName` and most Page / Screen dimensions - * like `pageTitle` and `pagePath`. - * @type int $funnelVisualizationType - * Optional. The funnel visualization type controls the dimensions present in - * the funnel visualization sub report response. If not specified, - * `STANDARD_FUNNEL` is used. - * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1alpha\RunFunnelReportRequest\FunnelVisualizationType} - * @type Segment[] $segments - * Optional. 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. - * @type int $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * @type FilterExpression $dimensionFilter - * Optional. 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. - * @type bool $returnPropertyQuota - * Optional. Toggles whether to return the current state of this Analytics - * Property's quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\RunFunnelReportResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function runFunnelReport(array $optionalArgs = []) - { - $request = new RunFunnelReportRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['dateRanges'])) { - $request->setDateRanges($optionalArgs['dateRanges']); - } - - if (isset($optionalArgs['funnel'])) { - $request->setFunnel($optionalArgs['funnel']); - } - - if (isset($optionalArgs['funnelBreakdown'])) { - $request->setFunnelBreakdown($optionalArgs['funnelBreakdown']); - } - - if (isset($optionalArgs['funnelNextAction'])) { - $request->setFunnelNextAction($optionalArgs['funnelNextAction']); - } - - if (isset($optionalArgs['funnelVisualizationType'])) { - $request->setFunnelVisualizationType($optionalArgs['funnelVisualizationType']); - } - - if (isset($optionalArgs['segments'])) { - $request->setSegments($optionalArgs['segments']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - if (isset($optionalArgs['dimensionFilter'])) { - $request->setDimensionFilter($optionalArgs['dimensionFilter']); - } - - if (isset($optionalArgs['returnPropertyQuota'])) { - $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RunFunnelReport', RunFunnelReportResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Exports an audience list of users to a Google Sheet. After creating an - * audience, the users are not immediately available for listing. First, a - * request to `CreateAudienceList` is necessary to create an audience list of - * users, and then second, this method is used to export those users in the - * audience list to a Google Sheet. - * - * See [Creating an Audience - * List](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Lists with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * This method is introduced at alpha stability with the intention of - * gathering feedback on syntax and capabilities before entering beta. To give - * your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $alphaAnalyticsDataClient = new AlphaAnalyticsDataClient(); - * try { - * $formattedName = $alphaAnalyticsDataClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - * $response = $alphaAnalyticsDataClient->sheetExportAudienceList($formattedName); - * } finally { - * $alphaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the audience list to retrieve users from. - * Format: `properties/{property}/audienceLists/{audience_list}` - * @param array $optionalArgs { - * Optional. - * - * @type int $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1alpha\SheetExportAudienceListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function sheetExportAudienceList($name, array $optionalArgs = []) - { - $request = new SheetExportAudienceListRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['offset'])) { - $request->setOffset($optionalArgs['offset']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SheetExportAudienceList', SheetExportAudienceListResponse::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json deleted file mode 100644 index 6b8b6ebe92b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/gapic_metadata.json +++ /dev/null @@ -1,83 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.analytics.data.v1alpha", - "libraryPackage": "Google\\Analytics\\Data\\V1alpha", - "services": { - "AlphaAnalyticsData": { - "clients": { - "grpc": { - "libraryClient": "AlphaAnalyticsDataGapicClient", - "rpcs": { - "CreateAudienceList": { - "methods": [ - "createAudienceList" - ] - }, - "CreateRecurringAudienceList": { - "methods": [ - "createRecurringAudienceList" - ] - }, - "CreateReportTask": { - "methods": [ - "createReportTask" - ] - }, - "GetAudienceList": { - "methods": [ - "getAudienceList" - ] - }, - "GetRecurringAudienceList": { - "methods": [ - "getRecurringAudienceList" - ] - }, - "GetReportTask": { - "methods": [ - "getReportTask" - ] - }, - "ListAudienceLists": { - "methods": [ - "listAudienceLists" - ] - }, - "ListRecurringAudienceLists": { - "methods": [ - "listRecurringAudienceLists" - ] - }, - "ListReportTasks": { - "methods": [ - "listReportTasks" - ] - }, - "QueryAudienceList": { - "methods": [ - "queryAudienceList" - ] - }, - "QueryReportTask": { - "methods": [ - "queryReportTask" - ] - }, - "RunFunnelReport": { - "methods": [ - "runFunnelReport" - ] - }, - "SheetExportAudienceList": { - "methods": [ - "sheetExportAudienceList" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json deleted file mode 100644 index 730a2dea65b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_client_config.json +++ /dev/null @@ -1,109 +0,0 @@ -{ - "interfaces": { - "google.analytics.data.v1alpha.AlphaAnalyticsData": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNKNOWN" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "CreateAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateRecurringAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateReportTask": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetRecurringAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetReportTask": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListAudienceLists": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListRecurringAudienceLists": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListReportTasks": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "QueryAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "QueryReportTask": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RunFunnelReport": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "SheetExportAudienceList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php deleted file mode 100644 index 6903c5bf2ef..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_descriptor_config.php +++ /dev/null @@ -1,228 +0,0 @@ - [ - 'google.analytics.data.v1alpha.AlphaAnalyticsData' => [ - 'CreateAudienceList' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Analytics\Data\V1alpha\AudienceList', - 'metadataReturnType' => '\Google\Analytics\Data\V1alpha\AudienceListMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateReportTask' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Analytics\Data\V1alpha\ReportTask', - 'metadataReturnType' => '\Google\Analytics\Data\V1alpha\ReportTaskMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRecurringAudienceList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\RecurringAudienceList', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GetAudienceList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\AudienceList', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetRecurringAudienceList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\RecurringAudienceList', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetReportTask' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\ReportTask', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAudienceLists' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAudienceLists', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\ListAudienceListsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListRecurringAudienceLists' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRecurringAudienceLists', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\ListRecurringAudienceListsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListReportTasks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getReportTasks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\ListReportTasksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'QueryAudienceList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\QueryAudienceListResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'QueryReportTask' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\QueryReportTaskResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RunFunnelReport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\RunFunnelReportResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'SheetExportAudienceList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1alpha\SheetExportAudienceListResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'audienceList' => 'properties/{property}/audienceLists/{audience_list}', - 'property' => 'properties/{property}', - 'recurringAudienceList' => 'properties/{property}/recurringAudienceLists/{recurring_audience_list}', - 'reportTask' => 'properties/{property}/reportTasks/{report_task}', - ], - ], - ], -]; diff --git a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php b/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php deleted file mode 100644 index 6b05bd39065..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/src/V1alpha/resources/alpha_analytics_data_rest_client_config.php +++ /dev/null @@ -1,179 +0,0 @@ - [ - 'google.analytics.data.v1alpha.AlphaAnalyticsData' => [ - 'CreateAudienceList' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/audienceLists', - 'body' => 'audience_list', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRecurringAudienceList' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/recurringAudienceLists', - 'body' => 'recurring_audience_list', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateReportTask' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', - 'body' => 'report_task', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'GetAudienceList' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetRecurringAudienceList' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{name=properties/*/recurringAudienceLists/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetReportTask' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAudienceLists' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/audienceLists', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListRecurringAudienceLists' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/recurringAudienceLists', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListReportTasks' => [ - 'method' => 'get', - 'uriTemplate' => '/v1alpha/{parent=properties/*}/reportTasks', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'QueryAudienceList' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}:query', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'QueryReportTask' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{name=properties/*/reportTasks/*}:query', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'RunFunnelReport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{property=properties/*}:runFunnelReport', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'SheetExportAudienceList' => [ - 'method' => 'post', - 'uriTemplate' => '/v1alpha/{name=properties/*/audienceLists/*}:exportSheet', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php deleted file mode 100644 index c915f17b643..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/AlphaAnalyticsDataClientTest.php +++ /dev/null @@ -1,1062 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AlphaAnalyticsDataClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AlphaAnalyticsDataClient($options); - } - - /** @test */ - public function createAudienceListTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $recurringAudienceList = 'recurringAudienceList2056789015'; - $expectedResponse = new AudienceList(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $expectedResponse->setRecurringAudienceList($recurringAudienceList); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAudienceListTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceList = new AudienceList(); - $audienceListAudience = 'audienceListAudience867162342'; - $audienceList->setAudience($audienceListAudience); - $audienceListDimensions = []; - $audienceList->setDimensions($audienceListDimensions); - $response = $gapicClient->createAudienceList($formattedParent, $audienceList); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAudienceList(); - $this->assertProtobufEquals($audienceList, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAudienceListExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceList = new AudienceList(); - $audienceListAudience = 'audienceListAudience867162342'; - $audienceList->setAudience($audienceListAudience); - $audienceListDimensions = []; - $audienceList->setDimensions($audienceListDimensions); - $response = $gapicClient->createAudienceList($formattedParent, $audienceList); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createRecurringAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $activeDaysRemaining = 1427137945; - $expectedResponse = new RecurringAudienceList(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $recurringAudienceList = new RecurringAudienceList(); - $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; - $recurringAudienceList->setAudience($recurringAudienceListAudience); - $recurringAudienceListDimensions = []; - $recurringAudienceList->setDimensions($recurringAudienceListDimensions); - $response = $gapicClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateRecurringAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRecurringAudienceList(); - $this->assertProtobufEquals($recurringAudienceList, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createRecurringAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $recurringAudienceList = new RecurringAudienceList(); - $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; - $recurringAudienceList->setAudience($recurringAudienceListAudience); - $recurringAudienceListDimensions = []; - $recurringAudienceList->setDimensions($recurringAudienceListDimensions); - try { - $gapicClient->createRecurringAudienceList($formattedParent, $recurringAudienceList); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createReportTaskTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createReportTaskTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $expectedResponse = new ReportTask(); - $expectedResponse->setName($name); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createReportTaskTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $reportTask = new ReportTask(); - $response = $gapicClient->createReportTask($formattedParent, $reportTask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getReportTask(); - $this->assertProtobufEquals($reportTask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createReportTaskExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createReportTaskTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $reportTask = new ReportTask(); - $response = $gapicClient->createReportTask($formattedParent, $reportTask); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $recurringAudienceList = 'recurringAudienceList2056789015'; - $expectedResponse = new AudienceList(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $expectedResponse->setRecurringAudienceList($recurringAudienceList); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $response = $gapicClient->getAudienceList($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - try { - $gapicClient->getAudienceList($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRecurringAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $activeDaysRemaining = 1427137945; - $expectedResponse = new RecurringAudienceList(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); - $response = $gapicClient->getRecurringAudienceList($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetRecurringAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRecurringAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); - try { - $gapicClient->getRecurringAudienceList($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getReportTaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new ReportTask(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); - $response = $gapicClient->getReportTask($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getReportTaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); - try { - $gapicClient->getReportTask($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceListsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $audienceListsElement = new AudienceList(); - $audienceLists = [ - $audienceListsElement, - ]; - $expectedResponse = new ListAudienceListsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAudienceLists($audienceLists); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $response = $gapicClient->listAudienceLists($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAudienceLists()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListAudienceLists', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceListsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - try { - $gapicClient->listAudienceLists($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRecurringAudienceListsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $recurringAudienceListsElement = new RecurringAudienceList(); - $recurringAudienceLists = [ - $recurringAudienceListsElement, - ]; - $expectedResponse = new ListRecurringAudienceListsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRecurringAudienceLists($recurringAudienceLists); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $response = $gapicClient->listRecurringAudienceLists($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRecurringAudienceLists()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListRecurringAudienceLists', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRecurringAudienceListsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - try { - $gapicClient->listRecurringAudienceLists($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listReportTasksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $reportTasksElement = new ReportTask(); - $reportTasks = [ - $reportTasksElement, - ]; - $expectedResponse = new ListReportTasksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setReportTasks($reportTasks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $response = $gapicClient->listReportTasks($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listReportTasksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - try { - $gapicClient->listReportTasks($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryAudienceListResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $response = $gapicClient->queryAudienceList($name); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - try { - $gapicClient->queryAudienceList($name); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryReportTaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryReportTaskResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $response = $gapicClient->queryReportTask($name); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryReportTaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - try { - $gapicClient->queryReportTask($name); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runFunnelReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new RunFunnelReportResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->runFunnelReport(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/RunFunnelReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runFunnelReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->runFunnelReport(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function sheetExportAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $spreadsheetUri = 'spreadsheetUri-1521055111'; - $spreadsheetId = 'spreadsheetId1336406638'; - $rowCount = 1340416618; - $expectedResponse = new SheetExportAudienceListResponse(); - $expectedResponse->setSpreadsheetUri($spreadsheetUri); - $expectedResponse->setSpreadsheetId($spreadsheetId); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $response = $gapicClient->sheetExportAudienceList($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/SheetExportAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function sheetExportAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - try { - $gapicClient->sheetExportAudienceList($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php deleted file mode 100644 index 27ed731150f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1alpha/tests/Unit/V1alpha/Client/AlphaAnalyticsDataClientTest.php +++ /dev/null @@ -1,1219 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return AlphaAnalyticsDataClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new AlphaAnalyticsDataClient($options); - } - - /** @test */ - public function createAudienceListTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $recurringAudienceList = 'recurringAudienceList2056789015'; - $expectedResponse = new AudienceList(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $expectedResponse->setRecurringAudienceList($recurringAudienceList); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAudienceListTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceList = new AudienceList(); - $audienceListAudience = 'audienceListAudience867162342'; - $audienceList->setAudience($audienceListAudience); - $audienceListDimensions = []; - $audienceList->setDimensions($audienceListDimensions); - $request = (new CreateAudienceListRequest()) - ->setParent($formattedParent) - ->setAudienceList($audienceList); - $response = $gapicClient->createAudienceList($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAudienceList(); - $this->assertProtobufEquals($audienceList, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAudienceListExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceList = new AudienceList(); - $audienceListAudience = 'audienceListAudience867162342'; - $audienceList->setAudience($audienceListAudience); - $audienceListDimensions = []; - $audienceList->setDimensions($audienceListDimensions); - $request = (new CreateAudienceListRequest()) - ->setParent($formattedParent) - ->setAudienceList($audienceList); - $response = $gapicClient->createAudienceList($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createRecurringAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $activeDaysRemaining = 1427137945; - $expectedResponse = new RecurringAudienceList(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $recurringAudienceList = new RecurringAudienceList(); - $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; - $recurringAudienceList->setAudience($recurringAudienceListAudience); - $recurringAudienceListDimensions = []; - $recurringAudienceList->setDimensions($recurringAudienceListDimensions); - $request = (new CreateRecurringAudienceListRequest()) - ->setParent($formattedParent) - ->setRecurringAudienceList($recurringAudienceList); - $response = $gapicClient->createRecurringAudienceList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateRecurringAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRecurringAudienceList(); - $this->assertProtobufEquals($recurringAudienceList, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createRecurringAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $recurringAudienceList = new RecurringAudienceList(); - $recurringAudienceListAudience = 'recurringAudienceListAudience230288227'; - $recurringAudienceList->setAudience($recurringAudienceListAudience); - $recurringAudienceListDimensions = []; - $recurringAudienceList->setDimensions($recurringAudienceListDimensions); - $request = (new CreateRecurringAudienceListRequest()) - ->setParent($formattedParent) - ->setRecurringAudienceList($recurringAudienceList); - try { - $gapicClient->createRecurringAudienceList($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createReportTaskTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createReportTaskTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $expectedResponse = new ReportTask(); - $expectedResponse->setName($name); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createReportTaskTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $reportTask = new ReportTask(); - $request = (new CreateReportTaskRequest()) - ->setParent($formattedParent) - ->setReportTask($reportTask); - $response = $gapicClient->createReportTask($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateReportTask', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getReportTask(); - $this->assertProtobufEquals($reportTask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createReportTaskExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createReportTaskTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $reportTask = new ReportTask(); - $request = (new CreateReportTaskRequest()) - ->setParent($formattedParent) - ->setReportTask($reportTask); - $response = $gapicClient->createReportTask($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createReportTaskTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $recurringAudienceList = 'recurringAudienceList2056789015'; - $expectedResponse = new AudienceList(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $expectedResponse->setRecurringAudienceList($recurringAudienceList); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $request = (new GetAudienceListRequest()) - ->setName($formattedName); - $response = $gapicClient->getAudienceList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $request = (new GetAudienceListRequest()) - ->setName($formattedName); - try { - $gapicClient->getAudienceList($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRecurringAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $activeDaysRemaining = 1427137945; - $expectedResponse = new RecurringAudienceList(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setActiveDaysRemaining($activeDaysRemaining); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); - $request = (new GetRecurringAudienceListRequest()) - ->setName($formattedName); - $response = $gapicClient->getRecurringAudienceList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetRecurringAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRecurringAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->recurringAudienceListName('[PROPERTY]', '[RECURRING_AUDIENCE_LIST]'); - $request = (new GetRecurringAudienceListRequest()) - ->setName($formattedName); - try { - $gapicClient->getRecurringAudienceList($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getReportTaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new ReportTask(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); - $request = (new GetReportTaskRequest()) - ->setName($formattedName); - $response = $gapicClient->getReportTask($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/GetReportTask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getReportTaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->reportTaskName('[PROPERTY]', '[REPORT_TASK]'); - $request = (new GetReportTaskRequest()) - ->setName($formattedName); - try { - $gapicClient->getReportTask($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceListsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $audienceListsElement = new AudienceList(); - $audienceLists = [ - $audienceListsElement, - ]; - $expectedResponse = new ListAudienceListsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAudienceLists($audienceLists); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListAudienceListsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listAudienceLists($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAudienceLists()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListAudienceLists', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceListsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListAudienceListsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listAudienceLists($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRecurringAudienceListsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $recurringAudienceListsElement = new RecurringAudienceList(); - $recurringAudienceLists = [ - $recurringAudienceListsElement, - ]; - $expectedResponse = new ListRecurringAudienceListsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRecurringAudienceLists($recurringAudienceLists); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListRecurringAudienceListsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listRecurringAudienceLists($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRecurringAudienceLists()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListRecurringAudienceLists', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRecurringAudienceListsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListRecurringAudienceListsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listRecurringAudienceLists($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listReportTasksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $reportTasksElement = new ReportTask(); - $reportTasks = [ - $reportTasksElement, - ]; - $expectedResponse = new ListReportTasksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setReportTasks($reportTasks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListReportTasksRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listReportTasks($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getReportTasks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/ListReportTasks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listReportTasksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListReportTasksRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listReportTasks($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryAudienceListResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $request = (new QueryAudienceListRequest()) - ->setName($name); - $response = $gapicClient->queryAudienceList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - $request = (new QueryAudienceListRequest()) - ->setName($name); - try { - $gapicClient->queryAudienceList($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryReportTaskTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryReportTaskResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $request = (new QueryReportTaskRequest()) - ->setName($name); - $response = $gapicClient->queryReportTask($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/QueryReportTask', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryReportTaskExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - $request = (new QueryReportTaskRequest()) - ->setName($name); - try { - $gapicClient->queryReportTask($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runFunnelReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new RunFunnelReportResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new RunFunnelReportRequest(); - $response = $gapicClient->runFunnelReport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/RunFunnelReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runFunnelReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new RunFunnelReportRequest(); - try { - $gapicClient->runFunnelReport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function sheetExportAudienceListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $spreadsheetUri = 'spreadsheetUri-1521055111'; - $spreadsheetId = 'spreadsheetId1336406638'; - $rowCount = 1340416618; - $expectedResponse = new SheetExportAudienceListResponse(); - $expectedResponse->setSpreadsheetUri($spreadsheetUri); - $expectedResponse->setSpreadsheetId($spreadsheetId); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $request = (new SheetExportAudienceListRequest()) - ->setName($formattedName); - $response = $gapicClient->sheetExportAudienceList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/SheetExportAudienceList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function sheetExportAudienceListExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceListName('[PROPERTY]', '[AUDIENCE_LIST]'); - $request = (new SheetExportAudienceListRequest()) - ->setName($formattedName); - try { - $gapicClient->sheetExportAudienceList($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createAudienceListAsyncTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $recurringAudienceList = 'recurringAudienceList2056789015'; - $expectedResponse = new AudienceList(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $expectedResponse->setRecurringAudienceList($recurringAudienceList); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAudienceListTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceList = new AudienceList(); - $audienceListAudience = 'audienceListAudience867162342'; - $audienceList->setAudience($audienceListAudience); - $audienceListDimensions = []; - $audienceList->setDimensions($audienceListDimensions); - $request = (new CreateAudienceListRequest()) - ->setParent($formattedParent) - ->setAudienceList($audienceList); - $response = $gapicClient->createAudienceListAsync($request)->wait(); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1alpha.AlphaAnalyticsData/CreateAudienceList', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAudienceList(); - $this->assertProtobufEquals($audienceList, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceListTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/AnalyticsDataApi.php deleted file mode 100644 index 97e6fc78757970226441983404c768b1d2781063..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 10331 zcmeHN&2JRR72o#QX8eqeU0^d9$o4iY7#3z0o6i9+^w`GsE(^vuB#Ioh+B4;Gi*fhR z-2+Tk&LNkLl3Q}v%bs$}CAlS1E|GGGA`X#~+>j!1$Vw6aL87dbS5;j--80R6m_48< zzS!=r_v(HA>b+Ne<7Rcc3MbShYE#$rX-VCztNu1stFGfaMW>=}*0#2&s}`M|s#T$G zR#g}7sdw+KtBVUO>+d0{=hWOH&8ua{DOYIDw9QK0w~Ah_Wcp_A$%Rddzrv>mduo_f zE6aBPu+1InRm~z*msSg(;##&~V~I1{&?U2t1@`peg#s?P4p6L^o~MRy*-O1@!Dpc2 zPqnsLv5Knan<$2Q(((+;wtUO1SU*7h=F}~-;!$MMx^}B(7k$gIRYq{nF4E~Us^H1i zo~$}(k2zHex5`X}=Gj=Wed?m58w=Dcx>nV9+*Mqf&zGqm8kRkoJ`-%q*jZcZw2(2M zZxM1%_1zkc?yjmX^=qzuoy*M_?1q1BbZa_p#(ch^UV~dAkE(?(upMSe$M$+7oUd5a z_IsnbZP7}pK)1~&mgDwDx<-RQ>{`1!j$L+Zwr$zvjeAuV{=F#~`hVTR5cbWTYO=&U zZq9#X1yQ1xN?}mk#*~^4-N>AJ8veBmm-duP6{ZSPSkNQq4SdPY%|=^=tSRzeoG$K09eQ&ZE! zGaIL~LY8FXWEUg>xdi)msP7_xWm25MVJzI#*s>~!2$_BqXLu&to*qL0 z*DgM*qV1T(WD!P$0FuqXp4hCwA%@wZy(G6m# zW@`|-T>mZ0mK!jPx>3V5?J@>Qe|I^G6l;tiG1>N(B`wLu z(xdmB9fd(>Ys;g4W*^e0$OsHntR2hGr1`&h;2^pMVZt!WWtW!4Ns}2uwMS<<#2ES; z3H1gYxe7y$TcWP9S@$x)P4|BLD7(j&7wTjJMv67prFOAy6rB>y4D-mJgW;mHjZtEF zRa(sK=O&nL&vKpV315LK6iIPhcIp1ESFdLUS6)C`IV0Fnxq~zK5Y=prB9y#de3W=lO zz4nxA&Qo#$27OeqB7?dMl37Uan9r=8+K!hQ;O^{_2+KH5G}tZCI1HgS==z#1B6Wb= z!p#H3;KAB4_OZ_5u#aXkS>27eIojmjAs#>-j+oWp(7w+ifHka%_^vQ-^~*!aLv~L9dVHjrIhN%B>>6*G9X=7VT!+M|5*~@CHh&!?EOj z11Ud|*%Q~cLrLGfSE9=Ifh%Y0HfDRIEpM% z9I`}OVLb*jvm9p5!v}4f?>HyzXE+$SV|h&*gpfUtWuA%MmM;cVgzvRQdrhUrrhEZk-~;o?Dh!^u=@mx1s)sm&9pBDBomPo*$0f0OT_(0bU3(4%a&~vnZs~IZm`od zBg()j$r>9!eg%>ZN8o~mf+0Z8!f`?D*rM+@c&vIxaocpuw8Up6JepJFXtXnBX)m5H z_c2EA!U%O;$2D-w?qM$A-~^Lf?37{)PQf7@02eXSSf;RHVTIyd7Vjn%v92H2X$vsG z^+bP-KUmk-7maV_XG?Ym55&%H5?gg#Zld^Xn@Q7svY8-?#OZ zJGd&9|Ecmy|6J(_Dae(eMQ$3_$>;{UD7g##Z7`?odBSo!PVp z!8x=n$KZiw7Wy3hLe`XnY}^faG7U!=-Hl!!JTWVHwb9+^Trvr<;2|T{K7{d>H<)Cj zjnNv%AyHy8XK0rj&W`gU2Vj6pBu=sAcM8KefV8Q>AI^MEV4U5`#x7&YFBBN!g%vw- zNsnFER0sSE8OwfCyZEEO{p06-S?!FxZw?3IbCJY5yPJ3AKs>LUCBIQ%6nRCuEwYym zYHCldkamsBJga59kU1hE6a04y9FRSmXmC8zL5Qa1L8?w&l1LtwJ<&VEYzvjhLM_i_ zzo_Lp$-WtH)tT^rR^X828_~-n*SeD>N+Z?C?}aqb&HpCTtiiCHqoB0anY+9iKbf-!rvAtsmGZ^=_EN+3nO z(lcFP<{Mn-%i4ud=pZxeF~Nfrjc(0s{6_^y>lGyFAWbWURO4!UHIfJeJ?6L`SG1W< zdK6o(teGNTWArE0z@4H$iAE}OTq+Z}XU~RTG-y9jp6k;sh3spN_80o3=vmG+onKt- zTiW@C+Pt-iJ1-}Rf@&onmM=j;L;j+`!G!ajbZ|%liPXLWY$Q?!zFdsv(^YLY)U7q2 zniR|7S@M`wK+LDV#SCj{GdpEi3xU+9r#?ly5mg~a8t&;v1@audkt@a0 zZhWV9uIrUqY>-NhU8xs-uK@c_PG(~$OY}%BOvDN${Az8L^-!zI_ihCrsFa-wUUFw0 zx11|e8$r@{a*b~Q8WKjoue;9FeWl-oQ{kp&31?%?I^tgZOBpf|fN#7X*&O8C&7KZF dNjfLKLyLU2#(E8_nDEIOUn#yP+l5_#{{oI-sW1Ql diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/GPBMetadata/Google/Analytics/Data/V1Beta/Data.php deleted file mode 100644 index 649e364c14ef6c8012712e1a949cb9a4ca0bab4f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8211 zcmcIpU2_{(8ICMVkzU!dymlN%X@j~1;-p2Hx{!gSX}glvmJ(S~rFA~2r^{M8mbaC( zVt3`>GQD7c8E$|XE;`&Z!yP|?EB*jC+;kXjxMcVbyze=?tCcOwb|>V*(Vji$Iq&z^ zzW?Fya0uVdZLsbH8J_#{Hvr_Zj|2zw;auU|{r_Gc?*Px7{f0 z;9GjRx6P05DgN=j60JUaw}2ZS0knIDp2P6q>AeS|LEAO0L5>d82W_@-HzzP@@9m+5TtCkF1T{zyD1^Prz-2a4 zw^w3L+ct-;WjAo^!-rkw2I8ZYjl15p1ZN)PHUy0iAD$xean7|zEPQ(|XES$X4<2#4 z3E<1%7pLrdADA8;N~aTCyM?OR2sYBOJMiB}uy^NzN|D|W8}oto@?2v=d-8{nM9H(J zG3YW$0zigrSH~S}J(7!TB&7@_*q|d;=J?72%#)tiqx2;IG6Ja`b1?ETZo#s^=<`KK zH@X&wij}YYCK8d}fF;5Uza`jMIYMtIunVgo>8HR75@hrf5b|fphS_HW2bCXy2nOn~ z+VNlM>}NxpIkan?ZcS~zo1Z0~d;qEj2jxFUVP(p?^bDY9y<)cBHXOD-&*4A1GX!XnVjPuKwm zGzUkfWA68aWhdmn%s~dd4{sQ=C2d2}K=bX|)@aDhI<>huTVy98s;1+jR<|Hw*&dEC z#czgFhV;O4Lu_-uOl{^bM-@`^0OALnUC(xJUj(6ir4WaC5~utLtWM)qDne>3ZlSBc3&4DfpA-)$ho_J>2YL_Ht7@yIYh|T|qFnDH&sPb zn_}m@gz({&@#a|ew-H#JFhS`9^km!W>%vAzOqb$JdLI(5<((EW^b&F@EC5i#IN&i) z{yGL%>vo6Pg=0yDc%LT@FT%e!TiV{Syht|Q6AvWGAbWY`#)FF?1?9yUtO&88d1Sd> zct6MEeUchF49^ez%+psu6va|vz!FMRMX8#j`%t?CA%H)!UG9@932tqnZ zZ=O>F`J|q_BhOz@7?DjhU_#|F1;azVSt5%&9Ujmgm1+ZRc6Uc@R*GoIZ^4^IrKRc^ z1=L!rqE()$`oxwwDFs*k{n6~-BCrq^+EkfHpFoBy10z|F@s7hm1xL|*m5V7jd_|r= zw0xwjf{}^T7Ob2p?TPXz6le=+SRm6Ds@Ol4k*gTTBzDHh(~oOE#AwB}wtwvN@tq6t zK@rkAIB=LS%P0kWUX^hRi%L~k@eIo7c5T+>@z7b1p{UZE_h(-rOj8-3lfRAt6s<$c zc3VT%mVN+N+x*F|Db6Wa#8F9sMemqyQ`h5p<~fl=9Ck#X)Pywwq1$YT?2y>FnK^EzO|GlmCGhKEcgXNOe&X zqn=@#?y;Ax&Iwdufc*COw6qEfqGR*SfC9A8D%F?h&;ar0s`?avbI;wu6ko=NsC*ArrwNwsHrnk`ANli|+JyX795PLuR9FLt zp`95h9Ye~&I*QfMdzRzqJTF-|F0pmndd2mckZic=v=3R|K)qAB$vvNbb0Dv5F3(oP z$!qg1j)==Xpua=(%ULwnk!`a<`&e&V9fr<>ZMW!_*C6SlZRlU1v-AEfS)QXV`UWhp z{?I)}(hLU+kgNPilwRG2>&|HZGYncfrcU<|i9fV@9W>tc1nx?d=V{jykQ}2w>`_6D z4$Q|m&U%tZxN{ndmUoWCO5)7^bq;Qv$)ohE2xJYE;}N5as7ywRd`b9@{gc-v(!9d2 zLfY`AkjS%tjKK9X-bw3IvZByU3$FXrG8}0L`l)snQ8ayCYv@zJI)Wm~Zxp+IC~9yD zx8MzZhSgEut4~-66*hWc7lkEQ)WgS1=2q!GI;uixWy9h?oMu(H5H zgx?^)jgvy|BmDSyGqu;rlbfHwLb!{Ou0aaNqYu6xY8IkcW3RzN$HIBBcLz6?$Vse! zM`00%z1U2-#~+U@jP+P!xz^{{hUzp}>lh;Kr8dvuo*!=ETzce41y~9}9O9^)Uw$c! zEm)xu9FOlVde=`!82tPy;u5s%g6uH+2w7paZP|h=oXPVzPaJac#2DieuzP!OcWB{! zkcRKQ<8ivcXy+5l1<2vWVB-?-HMkj);3;y&Xyf8|@^eUq6?6>}C|n0eC>(|`rpaqZ_aPiCA84|91D4w($HlI=!w&d&4?IYsP0)pOrfb>9 zBBjfJh(cPp)c=_(KNb@qmx#r@@CzpAqC}a_A(bczsRc{>J*)jWw=XJP9IQ&HS9o}l zsN~BaUl15gUj0mn4M;6A+V$e(o?DPDRO`j3Y6&MqO6$~U1P36sI=*_Q)^=5WN7b;q zY+*IJ0!z4FthcmaaZdhc1l9s`DdN{PY%2u#)5(XRn;;OfZ%NinxY}AxLw7GU@Nmg?!gzHR;qPmlol87>99Jj z@Rhy`a#L-QXKCn$XUheN;0{+(GzEo%Lh${Pugu+Rz~ZE3z6m#q^_>PPuu!Rgoogle.analytics.data.v1beta.AudienceDimension - */ -class AudienceDimension extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $dimension_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * Optional. The API name of the dimension. See the [API - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-api-schema#dimensions) - * for the list of dimension names. - * - * Generated from protobuf field string dimension_name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php deleted file mode 100644 index 8681ff01f47..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceDimensionValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1beta.AudienceDimensionValue - */ -class AudienceDimensionValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Value as a string if the dimension type is a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->readOneof(1); - } - - public function hasValue() - { - return $this->hasOneof(1); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php deleted file mode 100644 index 3630d8dfb88..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport.php +++ /dev/null @@ -1,473 +0,0 @@ -google.analytics.data.v1beta.AudienceExport - */ -class AudienceExport extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The audience export resource name assigned during - * creation. This resource name identifies this `AudienceExport`. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $audience = ''; - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $audience_display_name = ''; - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $dimensions; - /** - * Output only. The current state for this AudienceExport. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = null; - /** - * Output only. The time when CreateAudienceExport was called and the - * AudienceExport began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $begin_creating_time = null; - /** - * Output only. The total quota tokens charged during creation of the - * AudienceExport. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceExport - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $creation_quota_tokens_charged = 0; - /** - * Output only. The total number of rows in the AudienceExport result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $row_count = null; - /** - * Output only. Error message is populated when an audience export fails - * during creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $error_message = null; - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $percentage_completed = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The audience export resource name assigned during - * creation. This resource name identifies this `AudienceExport`. - * Format: `properties/{property}/audienceExports/{audience_export}` - * @type string $audience - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * @type string $audience_display_name - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * @type array<\Google\Analytics\Data\V1beta\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * Required. The dimensions requested and displayed in the query response. - * @type int $state - * Output only. The current state for this AudienceExport. - * @type \Google\Protobuf\Timestamp $begin_creating_time - * Output only. The time when CreateAudienceExport was called and the - * AudienceExport began the `CREATING` state. - * @type int $creation_quota_tokens_charged - * Output only. The total quota tokens charged during creation of the - * AudienceExport. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceExport - * enters the `ACTIVE` or `FAILED` states. - * @type int $row_count - * Output only. The total number of rows in the AudienceExport result. - * @type string $error_message - * Output only. Error message is populated when an audience export fails - * during creation. A common reason for such a failure is quota exhaustion. - * @type float $percentage_completed - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The audience export resource name assigned during - * creation. This resource name identifies this `AudienceExport`. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The audience export resource name assigned during - * creation. This resource name identifies this `AudienceExport`. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAudience() - { - return $this->audience; - } - - /** - * Required. The audience resource name. This resource name identifies the - * audience being listed and is shared between the Analytics Data & Admin - * APIs. - * Format: `properties/{property}/audiences/{audience}` - * - * Generated from protobuf field string audience = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAudience($var) - { - GPBUtil::checkString($var, True); - $this->audience = $var; - - return $this; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getAudienceDisplayName() - { - return $this->audience_display_name; - } - - /** - * Output only. The descriptive display name for this audience. For example, - * "Purchasers". - * - * Generated from protobuf field string audience_display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setAudienceDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->audience_display_name = $var; - - return $this; - } - - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * Required. The dimensions requested and displayed in the query response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimension dimensions = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Analytics\Data\V1beta\AudienceDimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceDimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * Output only. The current state for this AudienceExport. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return isset($this->state) ? $this->state : 0; - } - - public function hasState() - { - return isset($this->state); - } - - public function clearState() - { - unset($this->state); - } - - /** - * Output only. The current state for this AudienceExport. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\AudienceExport\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. The time when CreateAudienceExport was called and the - * AudienceExport began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBeginCreatingTime() - { - return $this->begin_creating_time; - } - - public function hasBeginCreatingTime() - { - return isset($this->begin_creating_time); - } - - public function clearBeginCreatingTime() - { - unset($this->begin_creating_time); - } - - /** - * Output only. The time when CreateAudienceExport was called and the - * AudienceExport began the `CREATING` state. - * - * Generated from protobuf field optional .google.protobuf.Timestamp begin_creating_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBeginCreatingTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->begin_creating_time = $var; - - return $this; - } - - /** - * Output only. The total quota tokens charged during creation of the - * AudienceExport. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceExport - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getCreationQuotaTokensCharged() - { - return $this->creation_quota_tokens_charged; - } - - /** - * Output only. The total quota tokens charged during creation of the - * AudienceExport. Because this token count is based on activity from the - * `CREATING` state, this tokens charged will be fixed once an AudienceExport - * enters the `ACTIVE` or `FAILED` states. - * - * Generated from protobuf field int32 creation_quota_tokens_charged = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setCreationQuotaTokensCharged($var) - { - GPBUtil::checkInt32($var); - $this->creation_quota_tokens_charged = $var; - - return $this; - } - - /** - * Output only. The total number of rows in the AudienceExport result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getRowCount() - { - return isset($this->row_count) ? $this->row_count : 0; - } - - public function hasRowCount() - { - return isset($this->row_count); - } - - public function clearRowCount() - { - unset($this->row_count); - } - - /** - * Output only. The total number of rows in the AudienceExport result. - * - * Generated from protobuf field optional int32 row_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - - /** - * Output only. Error message is populated when an audience export fails - * during creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getErrorMessage() - { - return isset($this->error_message) ? $this->error_message : ''; - } - - public function hasErrorMessage() - { - return isset($this->error_message); - } - - public function clearErrorMessage() - { - unset($this->error_message); - } - - /** - * Output only. Error message is populated when an audience export fails - * during creation. A common reason for such a failure is quota exhaustion. - * - * Generated from protobuf field optional string error_message = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setErrorMessage($var) - { - GPBUtil::checkString($var, True); - $this->error_message = $var; - - return $this; - } - - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return float - */ - public function getPercentageCompleted() - { - return isset($this->percentage_completed) ? $this->percentage_completed : 0.0; - } - - public function hasPercentageCompleted() - { - return isset($this->percentage_completed); - } - - public function clearPercentageCompleted() - { - unset($this->percentage_completed); - } - - /** - * Output only. The percentage completed for this audience export ranging - * between 0 to 100. - * - * Generated from protobuf field optional double percentage_completed = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param float $var - * @return $this - */ - public function setPercentageCompleted($var) - { - GPBUtil::checkDouble($var); - $this->percentage_completed = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php deleted file mode 100644 index 334e8a4212f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExport/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1beta.AudienceExport.State - */ -class State -{ - /** - * Unspecified state will never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The AudienceExport is currently creating and will be available in the - * future. Creating occurs immediately after the CreateAudienceExport call. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The AudienceExport is fully created and ready for querying. An - * AudienceExport is updated to active asynchronously from a request; this - * occurs some time (for example 15 minutes) after the initial create call. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * The AudienceExport failed to be created. It is possible that - * re-requesting this audience export will succeed. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::FAILED => 'FAILED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Analytics\Data\V1beta\AudienceExport_State::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php deleted file mode 100644 index 1b70d333184..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceExportMetadata.php +++ /dev/null @@ -1,33 +0,0 @@ -google.analytics.data.v1beta.AudienceExportMetadata - */ -class AudienceExportMetadata extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php deleted file mode 100644 index e30895ff219..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/AudienceRow.php +++ /dev/null @@ -1,71 +0,0 @@ -google.analytics.data.v1beta.AudienceRow - */ -class AudienceRow extends \Google\Protobuf\Internal\Message -{ - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; - */ - private $dimension_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionValues() - { - return $this->dimension_values; - } - - /** - * Each dimension value attribute for an audience user. One dimension value - * will be added for each dimension column requested. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceDimensionValue dimension_values = 1; - * @param array<\Google\Analytics\Data\V1beta\AudienceDimensionValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceDimensionValue::class); - $this->dimension_values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php deleted file mode 100644 index 1d487d14e74..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsRequest.php +++ /dev/null @@ -1,133 +0,0 @@ -google.analytics.data.v1beta.BatchRunPivotReportsRequest - */ -class BatchRunPivotReportsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * 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). - * This property must be specified for the batch. The property within - * RunPivotReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * Individual requests. Each request has a separate pivot report response. - * Each batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; - */ - private $requests; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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). - * This property must be specified for the batch. The property within - * RunPivotReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * @type array<\Google\Analytics\Data\V1beta\RunPivotReportRequest>|\Google\Protobuf\Internal\RepeatedField $requests - * Individual requests. Each request has a separate pivot report response. - * Each batch request is allowed up to 5 requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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). - * This property must be specified for the batch. The property within - * RunPivotReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->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). - * This property must be specified for the batch. The property within - * RunPivotReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * Individual requests. Each request has a separate pivot report response. - * Each batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Individual requests. Each request has a separate pivot report response. - * Each batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportRequest requests = 2; - * @param array<\Google\Analytics\Data\V1beta\RunPivotReportRequest>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunPivotReportRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php deleted file mode 100644 index 3b7abe9c8ac..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunPivotReportsResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.analytics.data.v1beta.BatchRunPivotReportsResponse - */ -class BatchRunPivotReportsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Individual responses. Each response has a separate pivot report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; - */ - private $pivot_reports; - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 2; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\RunPivotReportResponse>|\Google\Protobuf\Internal\RepeatedField $pivot_reports - * Individual responses. Each response has a separate pivot report request. - * @type string $kind - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish - * between response types in JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Individual responses. Each response has a separate pivot report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPivotReports() - { - return $this->pivot_reports; - } - - /** - * Individual responses. Each response has a separate pivot report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunPivotReportResponse pivot_reports = 1; - * @param array<\Google\Analytics\Data\V1beta\RunPivotReportResponse>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPivotReports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunPivotReportResponse::class); - $this->pivot_reports = $arr; - - return $this; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 2; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunPivotReports". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 2; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php deleted file mode 100644 index 5eebae015a4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsRequest.php +++ /dev/null @@ -1,133 +0,0 @@ -google.analytics.data.v1beta.BatchRunReportsRequest - */ -class BatchRunReportsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * 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). - * This property must be specified for the batch. The property within - * RunReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * Individual requests. Each request has a separate report response. Each - * batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; - */ - private $requests; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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). - * This property must be specified for the batch. The property within - * RunReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * @type array<\Google\Analytics\Data\V1beta\RunReportRequest>|\Google\Protobuf\Internal\RepeatedField $requests - * Individual requests. Each request has a separate report response. Each - * batch request is allowed up to 5 requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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). - * This property must be specified for the batch. The property within - * RunReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->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). - * This property must be specified for the batch. The property within - * RunReportRequest may either be unspecified or consistent with this - * property. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * Individual requests. Each request has a separate report response. Each - * batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Individual requests. Each request has a separate report response. Each - * batch request is allowed up to 5 requests. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportRequest requests = 2; - * @param array<\Google\Analytics\Data\V1beta\RunReportRequest>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunReportRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php deleted file mode 100644 index f45db6b80c2..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/BatchRunReportsResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.analytics.data.v1beta.BatchRunReportsResponse - */ -class BatchRunReportsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Individual responses. Each response has a separate report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; - */ - private $reports; - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunReports". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 2; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\RunReportResponse>|\Google\Protobuf\Internal\RepeatedField $reports - * Individual responses. Each response has a separate report request. - * @type string $kind - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunReports". Useful to distinguish between - * response types in JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Individual responses. Each response has a separate report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getReports() - { - return $this->reports; - } - - /** - * Individual responses. Each response has a separate report request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RunReportResponse reports = 1; - * @param array<\Google\Analytics\Data\V1beta\RunReportResponse>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setReports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\RunReportResponse::class); - $this->reports = $arr; - - return $this; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunReports". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 2; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#batchRunReports". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 2; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php deleted file mode 100644 index dffa0b43fe7..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityRequest.php +++ /dev/null @@ -1,300 +0,0 @@ -google.analytics.data.v1beta.CheckCompatibilityRequest - */ -class CheckCompatibilityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * A Google Analytics GA4 property identifier whose events are tracked. To - * learn more, see [where to find your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * `property` should be the same value as in your `runReport` request. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * The dimensions in this report. `dimensions` should be the same value as in - * your `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - */ - private $dimensions; - /** - * The metrics in this report. `metrics` should be the same value as in your - * `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - */ - private $metrics; - /** - * The filter clause of dimensions. `dimensionFilter` should be the same value - * as in your `runReport` request. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - */ - protected $dimension_filter = null; - /** - * The filter clause of metrics. `metricFilter` should be the same value as in - * your `runReport` request - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - */ - protected $metric_filter = null; - /** - * Filters the dimensions and metrics in the response to just this - * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` - * to only return compatible dimensions & metrics. - * - * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; - */ - protected $compatibility_filter = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $property - * A Google Analytics GA4 property identifier whose events are tracked. To - * learn more, see [where to find your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * `property` should be the same value as in your `runReport` request. - * Example: properties/1234 - * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * The dimensions in this report. `dimensions` should be the same value as in - * your `runReport` request. - * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metrics in this report. `metrics` should be the same value as in your - * `runReport` request. - * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter - * The filter clause of dimensions. `dimensionFilter` should be the same value - * as in your `runReport` request. - * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter - * The filter clause of metrics. `metricFilter` should be the same value as in - * your `runReport` request - * @type int $compatibility_filter - * Filters the dimensions and metrics in the response to just this - * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` - * to only return compatible dimensions & metrics. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * A Google Analytics GA4 property identifier whose events are tracked. To - * learn more, see [where to find your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * `property` should be the same value as in your `runReport` request. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->property; - } - - /** - * A Google Analytics GA4 property identifier whose events are tracked. To - * learn more, see [where to find your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * `property` should be the same value as in your `runReport` request. - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * The dimensions in this report. `dimensions` should be the same value as in - * your `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * The dimensions in this report. `dimensions` should be the same value as in - * your `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * The metrics in this report. `metrics` should be the same value as in your - * `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metrics in this report. `metrics` should be the same value as in your - * `runReport` request. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); - $this->metrics = $arr; - - return $this; - } - - /** - * The filter clause of dimensions. `dimensionFilter` should be the same value - * as in your `runReport` request. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getDimensionFilter() - { - return $this->dimension_filter; - } - - public function hasDimensionFilter() - { - return isset($this->dimension_filter); - } - - public function clearDimensionFilter() - { - unset($this->dimension_filter); - } - - /** - * The filter clause of dimensions. `dimensionFilter` should be the same value - * as in your `runReport` request. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setDimensionFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->dimension_filter = $var; - - return $this; - } - - /** - * The filter clause of metrics. `metricFilter` should be the same value as in - * your `runReport` request - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getMetricFilter() - { - return $this->metric_filter; - } - - public function hasMetricFilter() - { - return isset($this->metric_filter); - } - - public function clearMetricFilter() - { - unset($this->metric_filter); - } - - /** - * The filter clause of metrics. `metricFilter` should be the same value as in - * your `runReport` request - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setMetricFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->metric_filter = $var; - - return $this; - } - - /** - * Filters the dimensions and metrics in the response to just this - * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` - * to only return compatible dimensions & metrics. - * - * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; - * @return int - */ - public function getCompatibilityFilter() - { - return $this->compatibility_filter; - } - - /** - * Filters the dimensions and metrics in the response to just this - * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` - * to only return compatible dimensions & metrics. - * - * Generated from protobuf field .google.analytics.data.v1beta.Compatibility compatibility_filter = 6; - * @param int $var - * @return $this - */ - public function setCompatibilityFilter($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); - $this->compatibility_filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php deleted file mode 100644 index 09d73dc1bcd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CheckCompatibilityResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.analytics.data.v1beta.CheckCompatibilityResponse - */ -class CheckCompatibilityResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The compatibility of each dimension. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; - */ - private $dimension_compatibilities; - /** - * The compatibility of each metric. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; - */ - private $metric_compatibilities; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\DimensionCompatibility>|\Google\Protobuf\Internal\RepeatedField $dimension_compatibilities - * The compatibility of each dimension. - * @type array<\Google\Analytics\Data\V1beta\MetricCompatibility>|\Google\Protobuf\Internal\RepeatedField $metric_compatibilities - * The compatibility of each metric. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * The compatibility of each dimension. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionCompatibilities() - { - return $this->dimension_compatibilities; - } - - /** - * The compatibility of each dimension. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionCompatibility dimension_compatibilities = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionCompatibility>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionCompatibilities($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionCompatibility::class); - $this->dimension_compatibilities = $arr; - - return $this; - } - - /** - * The compatibility of each metric. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricCompatibilities() - { - return $this->metric_compatibilities; - } - - /** - * The compatibility of each metric. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricCompatibility metric_compatibilities = 2; - * @param array<\Google\Analytics\Data\V1beta\MetricCompatibility>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricCompatibilities($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricCompatibility::class); - $this->metric_compatibilities = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php deleted file mode 100644 index 2af25ee8e36..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Cohort.php +++ /dev/null @@ -1,215 +0,0 @@ -google.analytics.data.v1beta.Cohort - */ -class Cohort extends \Google\Protobuf\Internal\Message -{ - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - */ - protected $dimension = ''; - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; - */ - protected $date_range = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * @type string $dimension - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * @type \Google\Analytics\Data\V1beta\DateRange $date_range - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Assigns a name to this cohort. The dimension `cohort` is valued to this - * name in a report response. If set, cannot begin with `cohort_` or - * `RESERVED_`. If not set, cohorts are named by their zero based index - * `cohort_0`, `cohort_1`, etc. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - * @return string - */ - public function getDimension() - { - return $this->dimension; - } - - /** - * Dimension used by the cohort. Required and only supports - * `firstSessionDate`. - * - * Generated from protobuf field string dimension = 2; - * @param string $var - * @return $this - */ - public function setDimension($var) - { - GPBUtil::checkString($var, True); - $this->dimension = $var; - - return $this; - } - - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; - * @return \Google\Analytics\Data\V1beta\DateRange|null - */ - public function getDateRange() - { - return $this->date_range; - } - - public function hasDateRange() - { - return isset($this->date_range); - } - - public function clearDateRange() - { - unset($this->date_range); - } - - /** - * The cohort selects users whose first touch date is between start date and - * end date defined in the `dateRange`. This `dateRange` does not specify the - * full date range of event data that is present in a cohort report. In a - * cohort report, this `dateRange` is extended by the granularity and offset - * present in the `cohortsRange`; event data for the extended reporting date - * range is present in a cohort report. - * In a cohort request, this `dateRange` is required and the `dateRanges` in - * the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. - * This `dateRange` should generally be aligned with the cohort's granularity. - * If `CohortsRange` uses daily granularity, this `dateRange` can be a single - * day. If `CohortsRange` uses weekly granularity, this `dateRange` can be - * aligned to a week boundary, starting at Sunday and ending Saturday. If - * `CohortsRange` uses monthly granularity, this `dateRange` can be aligned to - * a month, starting at the first and ending on the last day of the month. - * - * Generated from protobuf field .google.analytics.data.v1beta.DateRange date_range = 3; - * @param \Google\Analytics\Data\V1beta\DateRange $var - * @return $this - */ - public function setDateRange($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DateRange::class); - $this->date_range = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php deleted file mode 100644 index 18831386174..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortReportSettings.php +++ /dev/null @@ -1,71 +0,0 @@ -google.analytics.data.v1beta.CohortReportSettings - */ -class CohortReportSettings extends \Google\Protobuf\Internal\Message -{ - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - */ - protected $accumulate = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $accumulate - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - * @return bool - */ - public function getAccumulate() - { - return $this->accumulate; - } - - /** - * If true, accumulates the result from first touch day to the end day. Not - * supported in `RunReportRequest`. - * - * Generated from protobuf field bool accumulate = 1; - * @param bool $var - * @return $this - */ - public function setAccumulate($var) - { - GPBUtil::checkBool($var); - $this->accumulate = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php deleted file mode 100644 index 3fb245a459c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortSpec.php +++ /dev/null @@ -1,179 +0,0 @@ -google.analytics.data.v1beta.CohortSpec - */ -class CohortSpec extends \Google\Protobuf\Internal\Message -{ - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; - */ - private $cohorts; - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; - */ - protected $cohorts_range = null; - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; - */ - protected $cohort_report_settings = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\Cohort>|\Google\Protobuf\Internal\RepeatedField $cohorts - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * @type \Google\Analytics\Data\V1beta\CohortsRange $cohorts_range - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * @type \Google\Analytics\Data\V1beta\CohortReportSettings $cohort_report_settings - * Optional settings for a cohort report. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCohorts() - { - return $this->cohorts; - } - - /** - * Defines the selection criteria to group users into cohorts. - * Most cohort reports define only a single cohort. If multiple cohorts are - * specified, each cohort can be recognized in the report by their name. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Cohort cohorts = 1; - * @param array<\Google\Analytics\Data\V1beta\Cohort>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCohorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Cohort::class); - $this->cohorts = $arr; - - return $this; - } - - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; - * @return \Google\Analytics\Data\V1beta\CohortsRange|null - */ - public function getCohortsRange() - { - return $this->cohorts_range; - } - - public function hasCohortsRange() - { - return isset($this->cohorts_range); - } - - public function clearCohortsRange() - { - unset($this->cohorts_range); - } - - /** - * Cohort reports follow cohorts over an extended reporting date range. This - * range specifies an offset duration to follow the cohorts over. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange cohorts_range = 2; - * @param \Google\Analytics\Data\V1beta\CohortsRange $var - * @return $this - */ - public function setCohortsRange($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortsRange::class); - $this->cohorts_range = $var; - - return $this; - } - - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; - * @return \Google\Analytics\Data\V1beta\CohortReportSettings|null - */ - public function getCohortReportSettings() - { - return $this->cohort_report_settings; - } - - public function hasCohortReportSettings() - { - return isset($this->cohort_report_settings); - } - - public function clearCohortReportSettings() - { - unset($this->cohort_report_settings); - } - - /** - * Optional settings for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3; - * @param \Google\Analytics\Data\V1beta\CohortReportSettings $var - * @return $this - */ - public function setCohortReportSettings($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortReportSettings::class); - $this->cohort_report_settings = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php deleted file mode 100644 index 2877e4dbc3a..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange.php +++ /dev/null @@ -1,208 +0,0 @@ -google.analytics.data.v1beta.CohortsRange - */ -class CohortsRange extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; - */ - protected $granularity = 0; - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - */ - protected $start_offset = 0; - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - */ - protected $end_offset = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $granularity - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * @type int $start_offset - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * @type int $end_offset - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; - * @return int - */ - public function getGranularity() - { - return $this->granularity; - } - - /** - * Required. The granularity used to interpret the `startOffset` and - * `endOffset` for the extended reporting date range for a cohort report. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortsRange.Granularity granularity = 1; - * @param int $var - * @return $this - */ - public function setGranularity($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\CohortsRange\Granularity::class); - $this->granularity = $var; - - return $this; - } - - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - * @return int - */ - public function getStartOffset() - { - return $this->start_offset; - } - - /** - * `startOffset` specifies the start date of the extended reporting date range - * for a cohort report. `startOffset` is commonly set to 0 so that reports - * contain data from the acquisition of the cohort forward. - * If `granularity` is `DAILY`, the `startDate` of the extended reporting date - * range is `startDate` of the cohort plus `startOffset` days. - * If `granularity` is `WEEKLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 7` days. - * If `granularity` is `MONTHLY`, the `startDate` of the extended reporting - * date range is `startDate` of the cohort plus `startOffset * 30` days. - * - * Generated from protobuf field int32 start_offset = 2; - * @param int $var - * @return $this - */ - public function setStartOffset($var) - { - GPBUtil::checkInt32($var); - $this->start_offset = $var; - - return $this; - } - - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - * @return int - */ - public function getEndOffset() - { - return $this->end_offset; - } - - /** - * Required. `endOffset` specifies the end date of the extended reporting date - * range for a cohort report. `endOffset` can be any positive integer but is - * commonly set to 5 to 10 so that reports contain data on the cohort for the - * next several granularity time periods. - * If `granularity` is `DAILY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset` days. - * If `granularity` is `WEEKLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 7` days. - * If `granularity` is `MONTHLY`, the `endDate` of the extended reporting date - * range is `endDate` of the cohort plus `endOffset * 30` days. - * - * Generated from protobuf field int32 end_offset = 3; - * @param int $var - * @return $this - */ - public function setEndOffset($var) - { - GPBUtil::checkInt32($var); - $this->end_offset = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php deleted file mode 100644 index 541e282e316..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CohortsRange/Granularity.php +++ /dev/null @@ -1,76 +0,0 @@ -google.analytics.data.v1beta.CohortsRange.Granularity - */ -class Granularity -{ - /** - * Should never be specified. - * - * Generated from protobuf enum GRANULARITY_UNSPECIFIED = 0; - */ - const GRANULARITY_UNSPECIFIED = 0; - /** - * Daily granularity. Commonly used if the cohort's `dateRange` is a single - * day and the request contains `cohortNthDay`. - * - * Generated from protobuf enum DAILY = 1; - */ - const DAILY = 1; - /** - * Weekly granularity. Commonly used if the cohort's `dateRange` is a week - * in duration (starting on Sunday and ending on Saturday) and the request - * contains `cohortNthWeek`. - * - * Generated from protobuf enum WEEKLY = 2; - */ - const WEEKLY = 2; - /** - * Monthly granularity. Commonly used if the cohort's `dateRange` is a month - * in duration and the request contains `cohortNthMonth`. - * - * Generated from protobuf enum MONTHLY = 3; - */ - const MONTHLY = 3; - - private static $valueToName = [ - self::GRANULARITY_UNSPECIFIED => 'GRANULARITY_UNSPECIFIED', - self::DAILY => 'DAILY', - self::WEEKLY => 'WEEKLY', - self::MONTHLY => 'MONTHLY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Granularity::class, \Google\Analytics\Data\V1beta\CohortsRange_Granularity::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php deleted file mode 100644 index 6a97b7928ec..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Compatibility.php +++ /dev/null @@ -1,63 +0,0 @@ -google.analytics.data.v1beta.Compatibility - */ -class Compatibility -{ - /** - * Unspecified compatibility. - * - * Generated from protobuf enum COMPATIBILITY_UNSPECIFIED = 0; - */ - const COMPATIBILITY_UNSPECIFIED = 0; - /** - * The dimension or metric is compatible. This dimension or metric can be - * successfully added to a report. - * - * Generated from protobuf enum COMPATIBLE = 1; - */ - const COMPATIBLE = 1; - /** - * The dimension or metric is incompatible. This dimension or metric cannot be - * successfully added to a report. - * - * Generated from protobuf enum INCOMPATIBLE = 2; - */ - const INCOMPATIBLE = 2; - - private static $valueToName = [ - self::COMPATIBILITY_UNSPECIFIED => 'COMPATIBILITY_UNSPECIFIED', - self::COMPATIBLE => 'COMPATIBLE', - self::INCOMPATIBLE => 'INCOMPATIBLE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php deleted file mode 100644 index 5fbfebf75fd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/CreateAudienceExportRequest.php +++ /dev/null @@ -1,132 +0,0 @@ -google.analytics.data.v1beta.CreateAudienceExportRequest - */ -class CreateAudienceExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The audience export to create. - * - * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $audience_export = null; - - /** - * @param string $parent Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * Please see {@see BetaAnalyticsDataClient::propertyName()} for help formatting this field. - * @param \Google\Analytics\Data\V1beta\AudienceExport $audienceExport Required. The audience export to create. - * - * @return \Google\Analytics\Data\V1beta\CreateAudienceExportRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Analytics\Data\V1beta\AudienceExport $audienceExport): self - { - return (new self()) - ->setParent($parent) - ->setAudienceExport($audienceExport); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * @type \Google\Analytics\Data\V1beta\AudienceExport $audience_export - * Required. The audience export to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The audience export to create. - * - * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Analytics\Data\V1beta\AudienceExport|null - */ - public function getAudienceExport() - { - return $this->audience_export; - } - - public function hasAudienceExport() - { - return isset($this->audience_export); - } - - public function clearAudienceExport() - { - unset($this->audience_export); - } - - /** - * Required. The audience export to create. - * - * Generated from protobuf field .google.analytics.data.v1beta.AudienceExport audience_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Analytics\Data\V1beta\AudienceExport $var - * @return $this - */ - public function setAudienceExport($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\AudienceExport::class); - $this->audience_export = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php deleted file mode 100644 index 9c0ef0525f6..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DateRange.php +++ /dev/null @@ -1,172 +0,0 @@ -google.analytics.data.v1beta.DateRange - */ -class DateRange extends \Google\Protobuf\Internal\Message -{ - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - */ - protected $start_date = ''; - /** - * 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. - * - * Generated from protobuf field string end_date = 2; - */ - protected $end_date = ''; - /** - * 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. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $start_date - * 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. - * @type string $end_date - * 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. - * @type string $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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - * @return string - */ - public function getStartDate() - { - return $this->start_date; - } - - /** - * 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. - * - * Generated from protobuf field string start_date = 1; - * @param string $var - * @return $this - */ - public function setStartDate($var) - { - GPBUtil::checkString($var, True); - $this->start_date = $var; - - 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. - * - * Generated from protobuf field string end_date = 2; - * @return string - */ - public function getEndDate() - { - return $this->end_date; - } - - /** - * 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. - * - * Generated from protobuf field string end_date = 2; - * @param string $var - * @return $this - */ - public function setEndDate($var) - { - GPBUtil::checkString($var, True); - $this->end_date = $var; - - 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. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->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. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php deleted file mode 100644 index 4fe7c3aed86..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Dimension.php +++ /dev/null @@ -1,190 +0,0 @@ -google.analytics.data.v1beta.Dimension - */ -class Dimension extends \Google\Protobuf\Internal\Message -{ - /** - * 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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; - */ - protected $dimension_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * @type \Google\Analytics\Data\V1beta\DimensionExpression $dimension_expression - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->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 supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#dimensions) - * for the list of dimension names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Dimensions](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#dimensions) - * for the list of dimension names supported by the `runFunnelReport` - * method. - * 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`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; - * @return \Google\Analytics\Data\V1beta\DimensionExpression|null - */ - public function getDimensionExpression() - { - return $this->dimension_expression; - } - - public function hasDimensionExpression() - { - return isset($this->dimension_expression); - } - - public function clearDimensionExpression() - { - unset($this->dimension_expression); - } - - /** - * One dimension can be the result of an expression of multiple dimensions. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression dimension_expression = 2; - * @param \Google\Analytics\Data\V1beta\DimensionExpression $var - * @return $this - */ - public function setDimensionExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression::class); - $this->dimension_expression = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php deleted file mode 100644 index ff6d5ae0fc6..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionCompatibility.php +++ /dev/null @@ -1,133 +0,0 @@ -google.analytics.data.v1beta.DimensionCompatibility - */ -class DimensionCompatibility extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension metadata contains the API name for this compatibility - * information. The dimension metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; - */ - protected $dimension_metadata = null; - /** - * The compatibility of this dimension. If the compatibility is COMPATIBLE, - * this dimension can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - */ - protected $compatibility = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\DimensionMetadata $dimension_metadata - * The dimension metadata contains the API name for this compatibility - * information. The dimension metadata also contains other helpful information - * like the UI name and description. - * @type int $compatibility - * The compatibility of this dimension. If the compatibility is COMPATIBLE, - * this dimension can be successfully added to the report. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension metadata contains the API name for this compatibility - * information. The dimension metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; - * @return \Google\Analytics\Data\V1beta\DimensionMetadata|null - */ - public function getDimensionMetadata() - { - return $this->dimension_metadata; - } - - public function hasDimensionMetadata() - { - return isset($this->dimension_metadata); - } - - public function clearDimensionMetadata() - { - unset($this->dimension_metadata); - } - - /** - * The dimension metadata contains the API name for this compatibility - * information. The dimension metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.DimensionMetadata dimension_metadata = 1; - * @param \Google\Analytics\Data\V1beta\DimensionMetadata $var - * @return $this - */ - public function setDimensionMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionMetadata::class); - $this->dimension_metadata = $var; - - return $this; - } - - /** - * The compatibility of this dimension. If the compatibility is COMPATIBLE, - * this dimension can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - * @return int - */ - public function getCompatibility() - { - return isset($this->compatibility) ? $this->compatibility : 0; - } - - public function hasCompatibility() - { - return isset($this->compatibility); - } - - public function clearCompatibility() - { - unset($this->compatibility); - } - - /** - * The compatibility of this dimension. If the compatibility is COMPATIBLE, - * this dimension can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - * @param int $var - * @return $this - */ - public function setCompatibility($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); - $this->compatibility = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php deleted file mode 100644 index c7819e050c8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression.php +++ /dev/null @@ -1,147 +0,0 @@ -google.analytics.data.v1beta.DimensionExpression - */ -class DimensionExpression extends \Google\Protobuf\Internal\Message -{ - protected $one_expression; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $lower_case - * Used to convert a dimension value to lower case. - * @type \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $upper_case - * Used to convert a dimension value to upper case. - * @type \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $concatenate - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Used to convert a dimension value to lower case. - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4; - * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null - */ - public function getLowerCase() - { - return $this->readOneof(4); - } - - public function hasLowerCase() - { - return $this->hasOneof(4); - } - - /** - * Used to convert a dimension value to lower case. - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression lower_case = 4; - * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var - * @return $this - */ - public function setLowerCase($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Used to convert a dimension value to upper case. - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5; - * @return \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression|null - */ - public function getUpperCase() - { - return $this->readOneof(5); - } - - public function hasUpperCase() - { - return $this->hasOneof(5); - } - - /** - * Used to convert a dimension value to upper case. - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.CaseExpression upper_case = 5; - * @param \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression $var - * @return $this - */ - public function setUpperCase($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\CaseExpression::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6; - * @return \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression|null - */ - public function getConcatenate() - { - return $this->readOneof(6); - } - - public function hasConcatenate() - { - return $this->hasOneof(6); - } - - /** - * Used to combine dimension values to a single dimension. - * For example, dimension "country, city": concatenate(country, ", ", city). - * - * Generated from protobuf field .google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression concatenate = 6; - * @param \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression $var - * @return $this - */ - public function setConcatenate($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\DimensionExpression\ConcatenateExpression::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneExpression() - { - return $this->whichOneof("one_expression"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php deleted file mode 100644 index af1e679e55d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/CaseExpression.php +++ /dev/null @@ -1,74 +0,0 @@ -google.analytics.data.v1beta.DimensionExpression.CaseExpression - */ -class CaseExpression extends \Google\Protobuf\Internal\Message -{ - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - */ - protected $dimension_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * Name of a dimension. The name must refer back to a name in dimensions - * field of the request. - * - * Generated from protobuf field string dimension_name = 1; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CaseExpression::class, \Google\Analytics\Data\V1beta\DimensionExpression_CaseExpression::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php deleted file mode 100644 index 9d7a101bddd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionExpression/ConcatenateExpression.php +++ /dev/null @@ -1,128 +0,0 @@ -google.analytics.data.v1beta.DimensionExpression.ConcatenateExpression - */ -class ConcatenateExpression extends \Google\Protobuf\Internal\Message -{ - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - */ - private $dimension_names; - /** - * 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". - * - * Generated from protobuf field string delimiter = 2; - */ - protected $delimiter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $dimension_names - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * @type string $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". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionNames() - { - return $this->dimension_names; - } - - /** - * Names of dimensions. The names must refer back to names in the dimensions - * field of the request. - * - * Generated from protobuf field repeated string dimension_names = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->dimension_names = $arr; - - 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". - * - * Generated from protobuf field string delimiter = 2; - * @return string - */ - public function getDelimiter() - { - return $this->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". - * - * Generated from protobuf field string delimiter = 2; - * @param string $var - * @return $this - */ - public function setDelimiter($var) - { - GPBUtil::checkString($var, True); - $this->delimiter = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ConcatenateExpression::class, \Google\Analytics\Data\V1beta\DimensionExpression_ConcatenateExpression::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php deleted file mode 100644 index fe4f90d2a87..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionHeader.php +++ /dev/null @@ -1,70 +0,0 @@ -google.analytics.data.v1beta.DimensionHeader - */ -class DimensionHeader extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The dimension's name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The dimension's name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php deleted file mode 100644 index bb0ccba25fd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionMetadata.php +++ /dev/null @@ -1,261 +0,0 @@ -google.analytics.data.v1beta.DimensionMetadata - */ -class DimensionMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For - * example, `eventName`. - * - * Generated from protobuf field string api_name = 1; - */ - protected $api_name = ''; - /** - * This dimension's name within the Google Analytics user interface. For - * example, `Event name`. - * - * Generated from protobuf field string ui_name = 2; - */ - protected $ui_name = ''; - /** - * Description of how this dimension is used and calculated. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Still usable but deprecated names for this dimension. If populated, this - * dimension is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the dimension will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - */ - private $deprecated_api_names; - /** - * True if the dimension is a custom dimension for this property. - * - * Generated from protobuf field bool custom_definition = 5; - */ - protected $custom_definition = false; - /** - * The display name of the category that this dimension belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 7; - */ - protected $category = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $api_name - * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For - * example, `eventName`. - * @type string $ui_name - * This dimension's name within the Google Analytics user interface. For - * example, `Event name`. - * @type string $description - * Description of how this dimension is used and calculated. - * @type array|\Google\Protobuf\Internal\RepeatedField $deprecated_api_names - * Still usable but deprecated names for this dimension. If populated, this - * dimension is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the dimension will be - * available only by `apiName`. - * @type bool $custom_definition - * True if the dimension is a custom dimension for this property. - * @type string $category - * The display name of the category that this dimension belongs to. Similar - * dimensions and metrics are categorized together. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For - * example, `eventName`. - * - * Generated from protobuf field string api_name = 1; - * @return string - */ - public function getApiName() - { - return $this->api_name; - } - - /** - * This dimension's name. Useable in [Dimension](#Dimension)'s `name`. For - * example, `eventName`. - * - * Generated from protobuf field string api_name = 1; - * @param string $var - * @return $this - */ - public function setApiName($var) - { - GPBUtil::checkString($var, True); - $this->api_name = $var; - - return $this; - } - - /** - * This dimension's name within the Google Analytics user interface. For - * example, `Event name`. - * - * Generated from protobuf field string ui_name = 2; - * @return string - */ - public function getUiName() - { - return $this->ui_name; - } - - /** - * This dimension's name within the Google Analytics user interface. For - * example, `Event name`. - * - * Generated from protobuf field string ui_name = 2; - * @param string $var - * @return $this - */ - public function setUiName($var) - { - GPBUtil::checkString($var, True); - $this->ui_name = $var; - - return $this; - } - - /** - * Description of how this dimension is used and calculated. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of how this dimension is used and calculated. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Still usable but deprecated names for this dimension. If populated, this - * dimension is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the dimension will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDeprecatedApiNames() - { - return $this->deprecated_api_names; - } - - /** - * Still usable but deprecated names for this dimension. If populated, this - * dimension is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the dimension will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDeprecatedApiNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->deprecated_api_names = $arr; - - return $this; - } - - /** - * True if the dimension is a custom dimension for this property. - * - * Generated from protobuf field bool custom_definition = 5; - * @return bool - */ - public function getCustomDefinition() - { - return $this->custom_definition; - } - - /** - * True if the dimension is a custom dimension for this property. - * - * Generated from protobuf field bool custom_definition = 5; - * @param bool $var - * @return $this - */ - public function setCustomDefinition($var) - { - GPBUtil::checkBool($var); - $this->custom_definition = $var; - - return $this; - } - - /** - * The display name of the category that this dimension belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 7; - * @return string - */ - public function getCategory() - { - return $this->category; - } - - /** - * The display name of the category that this dimension belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 7; - * @param string $var - * @return $this - */ - public function setCategory($var) - { - GPBUtil::checkString($var, True); - $this->category = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php deleted file mode 100644 index 7e0d684c982..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/DimensionValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1beta.DimensionValue - */ -class DimensionValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Value as a string if the dimension type is a string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->readOneof(1); - } - - public function hasValue() - { - return $this->hasOneof(1); - } - - /** - * Value as a string if the dimension type is a string. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php deleted file mode 100644 index 01c955105c4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter.php +++ /dev/null @@ -1,224 +0,0 @@ -google.analytics.data.v1beta.Filter - */ -class Filter extends \Google\Protobuf\Internal\Message -{ - /** - * The dimension name or metric name. - * In most methods, dimensions & metrics can be used for the first time in - * this field. However in a RunPivotReportRequest, this field must be - * additionally specified by name in the RunPivotReportRequest's dimensions or - * metrics. - * - * Generated from protobuf field string field_name = 1; - */ - protected $field_name = ''; - protected $one_filter; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field_name - * The dimension name or metric name. - * In most methods, dimensions & metrics can be used for the first time in - * this field. However in a RunPivotReportRequest, this field must be - * additionally specified by name in the RunPivotReportRequest's dimensions or - * metrics. - * @type \Google\Analytics\Data\V1beta\Filter\StringFilter $string_filter - * Strings related filter. - * @type \Google\Analytics\Data\V1beta\Filter\InListFilter $in_list_filter - * A filter for in list values. - * @type \Google\Analytics\Data\V1beta\Filter\NumericFilter $numeric_filter - * A filter for numeric or date values. - * @type \Google\Analytics\Data\V1beta\Filter\BetweenFilter $between_filter - * A filter for two values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The dimension name or metric name. - * In most methods, dimensions & metrics can be used for the first time in - * this field. However in a RunPivotReportRequest, this field must be - * additionally specified by name in the RunPivotReportRequest's dimensions or - * metrics. - * - * Generated from protobuf field string field_name = 1; - * @return string - */ - public function getFieldName() - { - return $this->field_name; - } - - /** - * The dimension name or metric name. - * In most methods, dimensions & metrics can be used for the first time in - * this field. However in a RunPivotReportRequest, this field must be - * additionally specified by name in the RunPivotReportRequest's dimensions or - * metrics. - * - * Generated from protobuf field string field_name = 1; - * @param string $var - * @return $this - */ - public function setFieldName($var) - { - GPBUtil::checkString($var, True); - $this->field_name = $var; - - return $this; - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter string_filter = 3; - * @return \Google\Analytics\Data\V1beta\Filter\StringFilter|null - */ - public function getStringFilter() - { - return $this->readOneof(3); - } - - public function hasStringFilter() - { - return $this->hasOneof(3); - } - - /** - * Strings related filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter string_filter = 3; - * @param \Google\Analytics\Data\V1beta\Filter\StringFilter $var - * @return $this - */ - public function setStringFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\StringFilter::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.InListFilter in_list_filter = 4; - * @return \Google\Analytics\Data\V1beta\Filter\InListFilter|null - */ - public function getInListFilter() - { - return $this->readOneof(4); - } - - public function hasInListFilter() - { - return $this->hasOneof(4); - } - - /** - * A filter for in list values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.InListFilter in_list_filter = 4; - * @param \Google\Analytics\Data\V1beta\Filter\InListFilter $var - * @return $this - */ - public function setInListFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\InListFilter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter numeric_filter = 5; - * @return \Google\Analytics\Data\V1beta\Filter\NumericFilter|null - */ - public function getNumericFilter() - { - return $this->readOneof(5); - } - - public function hasNumericFilter() - { - return $this->hasOneof(5); - } - - /** - * A filter for numeric or date values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter numeric_filter = 5; - * @param \Google\Analytics\Data\V1beta\Filter\NumericFilter $var - * @return $this - */ - public function setNumericFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\NumericFilter::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * A filter for two values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.BetweenFilter between_filter = 6; - * @return \Google\Analytics\Data\V1beta\Filter\BetweenFilter|null - */ - public function getBetweenFilter() - { - return $this->readOneof(6); - } - - public function hasBetweenFilter() - { - return $this->hasOneof(6); - } - - /** - * A filter for two values. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.BetweenFilter between_filter = 6; - * @param \Google\Analytics\Data\V1beta\Filter\BetweenFilter $var - * @return $this - */ - public function setBetweenFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter\BetweenFilter::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneFilter() - { - return $this->whichOneof("one_filter"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php deleted file mode 100644 index 39b91d0e3f6..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/BetweenFilter.php +++ /dev/null @@ -1,124 +0,0 @@ -google.analytics.data.v1beta.Filter.BetweenFilter - */ -class BetweenFilter extends \Google\Protobuf\Internal\Message -{ - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; - */ - protected $from_value = null; - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; - */ - protected $to_value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\NumericValue $from_value - * Begins with this number. - * @type \Google\Analytics\Data\V1beta\NumericValue $to_value - * Ends with this number. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; - * @return \Google\Analytics\Data\V1beta\NumericValue|null - */ - public function getFromValue() - { - return $this->from_value; - } - - public function hasFromValue() - { - return isset($this->from_value); - } - - public function clearFromValue() - { - unset($this->from_value); - } - - /** - * Begins with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue from_value = 1; - * @param \Google\Analytics\Data\V1beta\NumericValue $var - * @return $this - */ - public function setFromValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); - $this->from_value = $var; - - return $this; - } - - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; - * @return \Google\Analytics\Data\V1beta\NumericValue|null - */ - public function getToValue() - { - return $this->to_value; - } - - public function hasToValue() - { - return isset($this->to_value); - } - - public function clearToValue() - { - unset($this->to_value); - } - - /** - * Ends with this number. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue to_value = 2; - * @param \Google\Analytics\Data\V1beta\NumericValue $var - * @return $this - */ - public function setToValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); - $this->to_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(BetweenFilter::class, \Google\Analytics\Data\V1beta\Filter_BetweenFilter::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php deleted file mode 100644 index cad215417f8..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/InListFilter.php +++ /dev/null @@ -1,108 +0,0 @@ -google.analytics.data.v1beta.Filter.InListFilter - */ -class InListFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - */ - private $values; - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - */ - protected $case_sensitive = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $values - * The list of string values. - * Must be non-empty. - * @type bool $case_sensitive - * If true, the string value is case sensitive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getValues() - { - return $this->values; - } - - /** - * The list of string values. - * Must be non-empty. - * - * Generated from protobuf field repeated string values = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->values = $arr; - - return $this; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - * @return bool - */ - public function getCaseSensitive() - { - return $this->case_sensitive; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 2; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InListFilter::class, \Google\Analytics\Data\V1beta\Filter_InListFilter::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php deleted file mode 100644 index cd95e5399a2..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter.php +++ /dev/null @@ -1,114 +0,0 @@ -google.analytics.data.v1beta.Filter.NumericFilter - */ -class NumericFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; - */ - protected $operation = 0; - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; - */ - protected $value = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $operation - * The operation type for this filter. - * @type \Google\Analytics\Data\V1beta\NumericValue $value - * A numeric value or a date value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; - * @return int - */ - public function getOperation() - { - return $this->operation; - } - - /** - * The operation type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.NumericFilter.Operation operation = 1; - * @param int $var - * @return $this - */ - public function setOperation($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Filter\NumericFilter\Operation::class); - $this->operation = $var; - - return $this; - } - - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; - * @return \Google\Analytics\Data\V1beta\NumericValue|null - */ - public function getValue() - { - return $this->value; - } - - public function hasValue() - { - return isset($this->value); - } - - public function clearValue() - { - unset($this->value); - } - - /** - * A numeric value or a date value. - * - * Generated from protobuf field .google.analytics.data.v1beta.NumericValue value = 2; - * @param \Google\Analytics\Data\V1beta\NumericValue $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\NumericValue::class); - $this->value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NumericFilter::class, \Google\Analytics\Data\V1beta\Filter_NumericFilter::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php deleted file mode 100644 index 4633829403b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/NumericFilter/Operation.php +++ /dev/null @@ -1,85 +0,0 @@ -google.analytics.data.v1beta.Filter.NumericFilter.Operation - */ -class Operation -{ - /** - * Unspecified. - * - * Generated from protobuf enum OPERATION_UNSPECIFIED = 0; - */ - const OPERATION_UNSPECIFIED = 0; - /** - * Equal - * - * Generated from protobuf enum EQUAL = 1; - */ - const EQUAL = 1; - /** - * Less than - * - * Generated from protobuf enum LESS_THAN = 2; - */ - const LESS_THAN = 2; - /** - * Less than or equal - * - * Generated from protobuf enum LESS_THAN_OR_EQUAL = 3; - */ - const LESS_THAN_OR_EQUAL = 3; - /** - * Greater than - * - * Generated from protobuf enum GREATER_THAN = 4; - */ - const GREATER_THAN = 4; - /** - * Greater than or equal - * - * Generated from protobuf enum GREATER_THAN_OR_EQUAL = 5; - */ - const GREATER_THAN_OR_EQUAL = 5; - - private static $valueToName = [ - self::OPERATION_UNSPECIFIED => 'OPERATION_UNSPECIFIED', - self::EQUAL => 'EQUAL', - self::LESS_THAN => 'LESS_THAN', - self::LESS_THAN_OR_EQUAL => 'LESS_THAN_OR_EQUAL', - self::GREATER_THAN => 'GREATER_THAN', - self::GREATER_THAN_OR_EQUAL => 'GREATER_THAN_OR_EQUAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Operation::class, \Google\Analytics\Data\V1beta\Filter_NumericFilter_Operation::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php deleted file mode 100644 index f4feeb9aff3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter.php +++ /dev/null @@ -1,138 +0,0 @@ -google.analytics.data.v1beta.Filter.StringFilter - */ -class StringFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; - */ - protected $match_type = 0; - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - */ - protected $value = ''; - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - */ - protected $case_sensitive = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $match_type - * The match type for this filter. - * @type string $value - * The string value used for the matching. - * @type bool $case_sensitive - * If true, the string value is case sensitive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; - * @return int - */ - public function getMatchType() - { - return $this->match_type; - } - - /** - * The match type for this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter.StringFilter.MatchType match_type = 1; - * @param int $var - * @return $this - */ - public function setMatchType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Filter\StringFilter\MatchType::class); - $this->match_type = $var; - - return $this; - } - - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The string value used for the matching. - * - * Generated from protobuf field string value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @return bool - */ - public function getCaseSensitive() - { - return $this->case_sensitive; - } - - /** - * If true, the string value is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StringFilter::class, \Google\Analytics\Data\V1beta\Filter_StringFilter::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php deleted file mode 100644 index 4e40f9c5c3b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Filter/StringFilter/MatchType.php +++ /dev/null @@ -1,92 +0,0 @@ -google.analytics.data.v1beta.Filter.StringFilter.MatchType - */ -class MatchType -{ - /** - * Unspecified - * - * Generated from protobuf enum MATCH_TYPE_UNSPECIFIED = 0; - */ - const MATCH_TYPE_UNSPECIFIED = 0; - /** - * Exact match of the string value. - * - * Generated from protobuf enum EXACT = 1; - */ - const EXACT = 1; - /** - * Begins with the string value. - * - * Generated from protobuf enum BEGINS_WITH = 2; - */ - const BEGINS_WITH = 2; - /** - * Ends with the string value. - * - * Generated from protobuf enum ENDS_WITH = 3; - */ - const ENDS_WITH = 3; - /** - * Contains the string value. - * - * Generated from protobuf enum CONTAINS = 4; - */ - const CONTAINS = 4; - /** - * Full match for the regular expression with the string value. - * - * Generated from protobuf enum FULL_REGEXP = 5; - */ - const FULL_REGEXP = 5; - /** - * Partial match for the regular expression with the string value. - * - * Generated from protobuf enum PARTIAL_REGEXP = 6; - */ - const PARTIAL_REGEXP = 6; - - private static $valueToName = [ - self::MATCH_TYPE_UNSPECIFIED => 'MATCH_TYPE_UNSPECIFIED', - self::EXACT => 'EXACT', - self::BEGINS_WITH => 'BEGINS_WITH', - self::ENDS_WITH => 'ENDS_WITH', - self::CONTAINS => 'CONTAINS', - self::FULL_REGEXP => 'FULL_REGEXP', - self::PARTIAL_REGEXP => 'PARTIAL_REGEXP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MatchType::class, \Google\Analytics\Data\V1beta\Filter_StringFilter_MatchType::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php deleted file mode 100644 index 99e554d09c3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpression.php +++ /dev/null @@ -1,178 +0,0 @@ -google.analytics.data.v1beta.FilterExpression - */ -class FilterExpression extends \Google\Protobuf\Internal\Message -{ - protected $expr; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\FilterExpressionList $and_group - * The FilterExpressions in and_group have an AND relationship. - * @type \Google\Analytics\Data\V1beta\FilterExpressionList $or_group - * The FilterExpressions in or_group have an OR relationship. - * @type \Google\Analytics\Data\V1beta\FilterExpression $not_expression - * The FilterExpression is NOT of not_expression. - * @type \Google\Analytics\Data\V1beta\Filter $filter - * A primitive filter. In the same FilterExpression, all of the filter's - * field names need to be either all dimensions or all metrics. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The FilterExpressions in and_group have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList and_group = 1; - * @return \Google\Analytics\Data\V1beta\FilterExpressionList|null - */ - public function getAndGroup() - { - return $this->readOneof(1); - } - - public function hasAndGroup() - { - return $this->hasOneof(1); - } - - /** - * The FilterExpressions in and_group have an AND relationship. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList and_group = 1; - * @param \Google\Analytics\Data\V1beta\FilterExpressionList $var - * @return $this - */ - public function setAndGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpressionList::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The FilterExpressions in or_group have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList or_group = 2; - * @return \Google\Analytics\Data\V1beta\FilterExpressionList|null - */ - public function getOrGroup() - { - return $this->readOneof(2); - } - - public function hasOrGroup() - { - return $this->hasOneof(2); - } - - /** - * The FilterExpressions in or_group have an OR relationship. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpressionList or_group = 2; - * @param \Google\Analytics\Data\V1beta\FilterExpressionList $var - * @return $this - */ - public function setOrGroup($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpressionList::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The FilterExpression is NOT of not_expression. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression not_expression = 3; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getNotExpression() - { - return $this->readOneof(3); - } - - public function hasNotExpression() - { - return $this->hasOneof(3); - } - - /** - * The FilterExpression is NOT of not_expression. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression not_expression = 3; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setNotExpression($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->writeOneof(3, $var); - - 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter filter = 4; - * @return \Google\Analytics\Data\V1beta\Filter|null - */ - public function getFilter() - { - return $this->readOneof(4); - } - - public function hasFilter() - { - return $this->hasOneof(4); - } - - /** - * A primitive filter. In the same FilterExpression, all of the filter's - * field names need to be either all dimensions or all metrics. - * - * Generated from protobuf field .google.analytics.data.v1beta.Filter filter = 4; - * @param \Google\Analytics\Data\V1beta\Filter $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\Filter::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getExpr() - { - return $this->whichOneof("expr"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php deleted file mode 100644 index d7eb56f9b25..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/FilterExpressionList.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1beta.FilterExpressionList - */ -class FilterExpressionList extends \Google\Protobuf\Internal\Message -{ - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; - */ - private $expressions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $expressions - * A list of filter expressions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getExpressions() - { - return $this->expressions; - } - - /** - * A list of filter expressions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.FilterExpression expressions = 1; - * @param array<\Google\Analytics\Data\V1beta\FilterExpression>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setExpressions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->expressions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php deleted file mode 100644 index 766f05b4bf6..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetAudienceExportRequest.php +++ /dev/null @@ -1,87 +0,0 @@ -google.analytics.data.v1beta.GetAudienceExportRequest - */ -class GetAudienceExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * Please see {@see BetaAnalyticsDataClient::audienceExportName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1beta\GetAudienceExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php deleted file mode 100644 index e2c983e6925..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/GetMetadataRequest.php +++ /dev/null @@ -1,123 +0,0 @@ -google.analytics.data.v1beta.GetMetadataRequest - */ -class GetMetadataRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * Example: properties/1234/metadata - * 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. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * - * Example: properties/1234/metadata - * - * 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. Please see - * {@see BetaAnalyticsDataClient::metadataName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1beta\GetMetadataRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * Example: properties/1234/metadata - * 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * Example: properties/1234/metadata - * 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. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * Example: properties/1234/metadata - * 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. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php deleted file mode 100644 index 33ef5680867..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsRequest.php +++ /dev/null @@ -1,178 +0,0 @@ -google.analytics.data.v1beta.ListAudienceExportsRequest - */ -class ListAudienceExportsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The maximum number of audience exports to return. The service may - * return fewer than this value. If unspecified, at most 200 audience exports - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. A page token, received from a previous `ListAudienceExports` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * Please see {@see BetaAnalyticsDataClient::propertyName()} for help formatting this field. - * - * @return \Google\Analytics\Data\V1beta\ListAudienceExportsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * @type int $page_size - * Optional. The maximum number of audience exports to return. The service may - * return fewer than this value. If unspecified, at most 200 audience exports - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * @type string $page_token - * Optional. A page token, received from a previous `ListAudienceExports` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceExports` - * must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Optional. The maximum number of audience exports to return. The service may - * return fewer than this value. If unspecified, at most 200 audience exports - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The maximum number of audience exports to return. The service may - * return fewer than this value. If unspecified, at most 200 audience exports - * will be returned. The maximum value is 1000 (higher values will be coerced - * to the maximum). - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. A page token, received from a previous `ListAudienceExports` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. A page token, received from a previous `ListAudienceExports` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListAudienceExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php deleted file mode 100644 index 36ed768b89f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ListAudienceExportsResponse.php +++ /dev/null @@ -1,115 +0,0 @@ -google.analytics.data.v1beta.ListAudienceExportsResponse - */ -class ListAudienceExportsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Each audience export for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; - */ - private $audience_exports; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - */ - protected $next_page_token = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\AudienceExport>|\Google\Protobuf\Internal\RepeatedField $audience_exports - * Each audience export for a property. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Each audience export for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAudienceExports() - { - return $this->audience_exports; - } - - /** - * Each audience export for a property. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceExport audience_exports = 1; - * @param array<\Google\Analytics\Data\V1beta\AudienceExport>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAudienceExports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceExport::class); - $this->audience_exports = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return isset($this->next_page_token) ? $this->next_page_token : ''; - } - - public function hasNextPageToken() - { - return isset($this->next_page_token); - } - - public function clearNextPageToken() - { - unset($this->next_page_token); - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field optional string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php deleted file mode 100644 index 8897087638e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metadata.php +++ /dev/null @@ -1,136 +0,0 @@ -google.analytics.data.v1beta.Metadata - */ -class Metadata extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of this metadata. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - /** - * The dimension descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; - */ - private $dimensions; - /** - * The metric descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; - */ - private $metrics; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name of this metadata. - * @type array<\Google\Analytics\Data\V1beta\DimensionMetadata>|\Google\Protobuf\Internal\RepeatedField $dimensions - * The dimension descriptions. - * @type array<\Google\Analytics\Data\V1beta\MetricMetadata>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metric descriptions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of this metadata. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name of this metadata. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The dimension descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * The dimension descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionMetadata dimensions = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionMetadata::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * The metric descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metric descriptions. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata metrics = 2; - * @param array<\Google\Analytics\Data\V1beta\MetricMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricMetadata::class); - $this->metrics = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php deleted file mode 100644 index d58fd9f004d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Metric.php +++ /dev/null @@ -1,221 +0,0 @@ -google.analytics.data.v1beta.Metric - */ -class Metric extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - */ - protected $expression = ''; - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - */ - protected $invisible = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * @type string $expression - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * @type bool $invisible - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the metric. See the [API - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema#metrics) - * for the list of metric names supported by core reporting methods such - * as `runReport` and `batchRunReports`. See - * [Realtime - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-api-schema#metrics) - * for the list of metric names supported by the `runRealtimeReport` - * method. See - * [Funnel - * Metrics](https://developers.google.com/analytics/devguides/reporting/data/v1/exploration-api-schema#metrics) - * for the list of metric names supported by the `runFunnelReport` - * method. - * If `expression` is specified, `name` can be any string that you would like - * within the allowed character set. For example if `expression` is - * `screenPageViews/sessions`, you could call that metric's name = - * `viewsPerSession`. Metric names that you choose must match the regular - * expression `^[a-zA-Z0-9_]$`. - * Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric - * `expression`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - * @return string - */ - public function getExpression() - { - return $this->expression; - } - - /** - * A mathematical expression for derived metrics. For example, the metric - * Event count per user is `eventCount/totalUsers`. - * - * Generated from protobuf field string expression = 2; - * @param string $var - * @return $this - */ - public function setExpression($var) - { - GPBUtil::checkString($var, True); - $this->expression = $var; - - return $this; - } - - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - * @return bool - */ - public function getInvisible() - { - return $this->invisible; - } - - /** - * Indicates if a metric is invisible in the report response. If a metric is - * invisible, the metric will not produce a column in the response, but can be - * used in `metricFilter`, `orderBys`, or a metric `expression`. - * - * Generated from protobuf field bool invisible = 3; - * @param bool $var - * @return $this - */ - public function setInvisible($var) - { - GPBUtil::checkBool($var); - $this->invisible = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php deleted file mode 100644 index af5158b3729..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricAggregation.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1beta.MetricAggregation - */ -class MetricAggregation -{ - /** - * Unspecified operator. - * - * Generated from protobuf enum METRIC_AGGREGATION_UNSPECIFIED = 0; - */ - const METRIC_AGGREGATION_UNSPECIFIED = 0; - /** - * SUM operator. - * - * Generated from protobuf enum TOTAL = 1; - */ - const TOTAL = 1; - /** - * Minimum operator. - * - * Generated from protobuf enum MINIMUM = 5; - */ - const MINIMUM = 5; - /** - * Maximum operator. - * - * Generated from protobuf enum MAXIMUM = 6; - */ - const MAXIMUM = 6; - /** - * Count operator. - * - * Generated from protobuf enum COUNT = 4; - */ - const COUNT = 4; - - private static $valueToName = [ - self::METRIC_AGGREGATION_UNSPECIFIED => 'METRIC_AGGREGATION_UNSPECIFIED', - self::TOTAL => 'TOTAL', - self::MINIMUM => 'MINIMUM', - self::MAXIMUM => 'MAXIMUM', - self::COUNT => 'COUNT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php deleted file mode 100644 index f76bff55631..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricCompatibility.php +++ /dev/null @@ -1,133 +0,0 @@ -google.analytics.data.v1beta.MetricCompatibility - */ -class MetricCompatibility extends \Google\Protobuf\Internal\Message -{ - /** - * The metric metadata contains the API name for this compatibility - * information. The metric metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; - */ - protected $metric_metadata = null; - /** - * The compatibility of this metric. If the compatibility is COMPATIBLE, - * this metric can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - */ - protected $compatibility = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\MetricMetadata $metric_metadata - * The metric metadata contains the API name for this compatibility - * information. The metric metadata also contains other helpful information - * like the UI name and description. - * @type int $compatibility - * The compatibility of this metric. If the compatibility is COMPATIBLE, - * this metric can be successfully added to the report. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The metric metadata contains the API name for this compatibility - * information. The metric metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; - * @return \Google\Analytics\Data\V1beta\MetricMetadata|null - */ - public function getMetricMetadata() - { - return $this->metric_metadata; - } - - public function hasMetricMetadata() - { - return isset($this->metric_metadata); - } - - public function clearMetricMetadata() - { - unset($this->metric_metadata); - } - - /** - * The metric metadata contains the API name for this compatibility - * information. The metric metadata also contains other helpful information - * like the UI name and description. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.MetricMetadata metric_metadata = 1; - * @param \Google\Analytics\Data\V1beta\MetricMetadata $var - * @return $this - */ - public function setMetricMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\MetricMetadata::class); - $this->metric_metadata = $var; - - return $this; - } - - /** - * The compatibility of this metric. If the compatibility is COMPATIBLE, - * this metric can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - * @return int - */ - public function getCompatibility() - { - return isset($this->compatibility) ? $this->compatibility : 0; - } - - public function hasCompatibility() - { - return isset($this->compatibility); - } - - public function clearCompatibility() - { - unset($this->compatibility); - } - - /** - * The compatibility of this metric. If the compatibility is COMPATIBLE, - * this metric can be successfully added to the report. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.Compatibility compatibility = 2; - * @param int $var - * @return $this - */ - public function setCompatibility($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\Compatibility::class); - $this->compatibility = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php deleted file mode 100644 index db125c0ae60..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricHeader.php +++ /dev/null @@ -1,104 +0,0 @@ -google.analytics.data.v1beta.MetricHeader - */ -class MetricHeader extends \Google\Protobuf\Internal\Message -{ - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The metric's name. - * @type int $type - * The metric's data type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The metric's name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The metric's data type. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\MetricType::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php deleted file mode 100644 index 9ef96ff2bc1..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata.php +++ /dev/null @@ -1,395 +0,0 @@ -google.analytics.data.v1beta.MetricMetadata - */ -class MetricMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * A metric name. Useable in [Metric](#Metric)'s `name`. For example, - * `eventCount`. - * - * Generated from protobuf field string api_name = 1; - */ - protected $api_name = ''; - /** - * This metric's name within the Google Analytics user interface. For example, - * `Event count`. - * - * Generated from protobuf field string ui_name = 2; - */ - protected $ui_name = ''; - /** - * Description of how this metric is used and calculated. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Still usable but deprecated names for this metric. If populated, this - * metric is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the metric will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - */ - private $deprecated_api_names; - /** - * The type of this metric. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; - */ - protected $type = 0; - /** - * The mathematical expression for this derived metric. Can be used in - * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics - * are not expressions, and for non-expressions, this field is empty. - * - * Generated from protobuf field string expression = 6; - */ - protected $expression = ''; - /** - * True if the metric is a custom metric for this property. - * - * Generated from protobuf field bool custom_definition = 7; - */ - protected $custom_definition = false; - /** - * If reasons are specified, your access is blocked to this metric for this - * property. API requests from you to this property for this metric will - * succeed; however, the report will contain only zeros for this metric. API - * requests with metric filters on blocked metrics will fail. If reasons are - * empty, you have access to this metric. - * To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; - */ - private $blocked_reasons; - /** - * The display name of the category that this metrics belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 10; - */ - protected $category = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $api_name - * A metric name. Useable in [Metric](#Metric)'s `name`. For example, - * `eventCount`. - * @type string $ui_name - * This metric's name within the Google Analytics user interface. For example, - * `Event count`. - * @type string $description - * Description of how this metric is used and calculated. - * @type array|\Google\Protobuf\Internal\RepeatedField $deprecated_api_names - * Still usable but deprecated names for this metric. If populated, this - * metric is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the metric will be - * available only by `apiName`. - * @type int $type - * The type of this metric. - * @type string $expression - * The mathematical expression for this derived metric. Can be used in - * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics - * are not expressions, and for non-expressions, this field is empty. - * @type bool $custom_definition - * True if the metric is a custom metric for this property. - * @type array|\Google\Protobuf\Internal\RepeatedField $blocked_reasons - * If reasons are specified, your access is blocked to this metric for this - * property. API requests from you to this property for this metric will - * succeed; however, the report will contain only zeros for this metric. API - * requests with metric filters on blocked metrics will fail. If reasons are - * empty, you have access to this metric. - * To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * @type string $category - * The display name of the category that this metrics belongs to. Similar - * dimensions and metrics are categorized together. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * A metric name. Useable in [Metric](#Metric)'s `name`. For example, - * `eventCount`. - * - * Generated from protobuf field string api_name = 1; - * @return string - */ - public function getApiName() - { - return $this->api_name; - } - - /** - * A metric name. Useable in [Metric](#Metric)'s `name`. For example, - * `eventCount`. - * - * Generated from protobuf field string api_name = 1; - * @param string $var - * @return $this - */ - public function setApiName($var) - { - GPBUtil::checkString($var, True); - $this->api_name = $var; - - return $this; - } - - /** - * This metric's name within the Google Analytics user interface. For example, - * `Event count`. - * - * Generated from protobuf field string ui_name = 2; - * @return string - */ - public function getUiName() - { - return $this->ui_name; - } - - /** - * This metric's name within the Google Analytics user interface. For example, - * `Event count`. - * - * Generated from protobuf field string ui_name = 2; - * @param string $var - * @return $this - */ - public function setUiName($var) - { - GPBUtil::checkString($var, True); - $this->ui_name = $var; - - return $this; - } - - /** - * Description of how this metric is used and calculated. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of how this metric is used and calculated. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Still usable but deprecated names for this metric. If populated, this - * metric is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the metric will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDeprecatedApiNames() - { - return $this->deprecated_api_names; - } - - /** - * Still usable but deprecated names for this metric. If populated, this - * metric is available by either `apiName` or one of `deprecatedApiNames` - * for a period of time. After the deprecation period, the metric will be - * available only by `apiName`. - * - * Generated from protobuf field repeated string deprecated_api_names = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDeprecatedApiNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->deprecated_api_names = $arr; - - return $this; - } - - /** - * The type of this metric. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * The type of this metric. - * - * Generated from protobuf field .google.analytics.data.v1beta.MetricType type = 5; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\MetricType::class); - $this->type = $var; - - return $this; - } - - /** - * The mathematical expression for this derived metric. Can be used in - * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics - * are not expressions, and for non-expressions, this field is empty. - * - * Generated from protobuf field string expression = 6; - * @return string - */ - public function getExpression() - { - return $this->expression; - } - - /** - * The mathematical expression for this derived metric. Can be used in - * [Metric](#Metric)'s `expression` field for equivalent reports. Most metrics - * are not expressions, and for non-expressions, this field is empty. - * - * Generated from protobuf field string expression = 6; - * @param string $var - * @return $this - */ - public function setExpression($var) - { - GPBUtil::checkString($var, True); - $this->expression = $var; - - return $this; - } - - /** - * True if the metric is a custom metric for this property. - * - * Generated from protobuf field bool custom_definition = 7; - * @return bool - */ - public function getCustomDefinition() - { - return $this->custom_definition; - } - - /** - * True if the metric is a custom metric for this property. - * - * Generated from protobuf field bool custom_definition = 7; - * @param bool $var - * @return $this - */ - public function setCustomDefinition($var) - { - GPBUtil::checkBool($var); - $this->custom_definition = $var; - - return $this; - } - - /** - * If reasons are specified, your access is blocked to this metric for this - * property. API requests from you to this property for this metric will - * succeed; however, the report will contain only zeros for this metric. API - * requests with metric filters on blocked metrics will fail. If reasons are - * empty, you have access to this metric. - * To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBlockedReasons() - { - return $this->blocked_reasons; - } - - /** - * If reasons are specified, your access is blocked to this metric for this - * property. API requests from you to this property for this metric will - * succeed; however, the report will contain only zeros for this metric. API - * requests with metric filters on blocked metrics will fail. If reasons are - * empty, you have access to this metric. - * To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricMetadata.BlockedReason blocked_reasons = 8; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBlockedReasons($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricMetadata\BlockedReason::class); - $this->blocked_reasons = $arr; - - return $this; - } - - /** - * The display name of the category that this metrics belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 10; - * @return string - */ - public function getCategory() - { - return $this->category; - } - - /** - * The display name of the category that this metrics belongs to. Similar - * dimensions and metrics are categorized together. - * - * Generated from protobuf field string category = 10; - * @param string $var - * @return $this - */ - public function setCategory($var) - { - GPBUtil::checkString($var, True); - $this->category = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php deleted file mode 100644 index 1b6aaf8bdc0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricMetadata/BlockedReason.php +++ /dev/null @@ -1,66 +0,0 @@ -google.analytics.data.v1beta.MetricMetadata.BlockedReason - */ -class BlockedReason -{ - /** - * Will never be specified in API response. - * - * Generated from protobuf enum BLOCKED_REASON_UNSPECIFIED = 0; - */ - const BLOCKED_REASON_UNSPECIFIED = 0; - /** - * If present, your access is blocked to revenue related metrics for this - * property, and this metric is revenue related. - * - * Generated from protobuf enum NO_REVENUE_METRICS = 1; - */ - const NO_REVENUE_METRICS = 1; - /** - * If present, your access is blocked to cost related metrics for this - * property, and this metric is cost related. - * - * Generated from protobuf enum NO_COST_METRICS = 2; - */ - const NO_COST_METRICS = 2; - - private static $valueToName = [ - self::BLOCKED_REASON_UNSPECIFIED => 'BLOCKED_REASON_UNSPECIFIED', - self::NO_REVENUE_METRICS => 'NO_REVENUE_METRICS', - self::NO_COST_METRICS => 'NO_COST_METRICS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(BlockedReason::class, \Google\Analytics\Data\V1beta\MetricMetadata_BlockedReason::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php deleted file mode 100644 index 641bfa44a62..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricType.php +++ /dev/null @@ -1,131 +0,0 @@ -google.analytics.data.v1beta.MetricType - */ -class MetricType -{ - /** - * Unspecified type. - * - * Generated from protobuf enum METRIC_TYPE_UNSPECIFIED = 0; - */ - const METRIC_TYPE_UNSPECIFIED = 0; - /** - * Integer type. - * - * Generated from protobuf enum TYPE_INTEGER = 1; - */ - const TYPE_INTEGER = 1; - /** - * Floating point type. - * - * Generated from protobuf enum TYPE_FLOAT = 2; - */ - const TYPE_FLOAT = 2; - /** - * A duration of seconds; a special floating point type. - * - * Generated from protobuf enum TYPE_SECONDS = 4; - */ - const TYPE_SECONDS = 4; - /** - * A duration in milliseconds; a special floating point type. - * - * Generated from protobuf enum TYPE_MILLISECONDS = 5; - */ - const TYPE_MILLISECONDS = 5; - /** - * A duration in minutes; a special floating point type. - * - * Generated from protobuf enum TYPE_MINUTES = 6; - */ - const TYPE_MINUTES = 6; - /** - * A duration in hours; a special floating point type. - * - * Generated from protobuf enum TYPE_HOURS = 7; - */ - const TYPE_HOURS = 7; - /** - * A custom metric of standard type; a special floating point type. - * - * Generated from protobuf enum TYPE_STANDARD = 8; - */ - const TYPE_STANDARD = 8; - /** - * An amount of money; a special floating point type. - * - * Generated from protobuf enum TYPE_CURRENCY = 9; - */ - const TYPE_CURRENCY = 9; - /** - * A length in feet; a special floating point type. - * - * Generated from protobuf enum TYPE_FEET = 10; - */ - const TYPE_FEET = 10; - /** - * A length in miles; a special floating point type. - * - * Generated from protobuf enum TYPE_MILES = 11; - */ - const TYPE_MILES = 11; - /** - * A length in meters; a special floating point type. - * - * Generated from protobuf enum TYPE_METERS = 12; - */ - const TYPE_METERS = 12; - /** - * A length in kilometers; a special floating point type. - * - * Generated from protobuf enum TYPE_KILOMETERS = 13; - */ - const TYPE_KILOMETERS = 13; - - private static $valueToName = [ - self::METRIC_TYPE_UNSPECIFIED => 'METRIC_TYPE_UNSPECIFIED', - self::TYPE_INTEGER => 'TYPE_INTEGER', - self::TYPE_FLOAT => 'TYPE_FLOAT', - self::TYPE_SECONDS => 'TYPE_SECONDS', - self::TYPE_MILLISECONDS => 'TYPE_MILLISECONDS', - self::TYPE_MINUTES => 'TYPE_MINUTES', - self::TYPE_HOURS => 'TYPE_HOURS', - self::TYPE_STANDARD => 'TYPE_STANDARD', - self::TYPE_CURRENCY => 'TYPE_CURRENCY', - self::TYPE_FEET => 'TYPE_FEET', - self::TYPE_MILES => 'TYPE_MILES', - self::TYPE_METERS => 'TYPE_METERS', - self::TYPE_KILOMETERS => 'TYPE_KILOMETERS', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php deleted file mode 100644 index 5ae81b6fc47..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MetricValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.analytics.data.v1beta.MetricValue - */ -class MetricValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * Measurement value. See MetricHeader for type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Measurement value. See MetricHeader for type. - * - * Generated from protobuf field string value = 4; - * @return string - */ - public function getValue() - { - return $this->readOneof(4); - } - - public function hasValue() - { - return $this->hasOneof(4); - } - - /** - * Measurement value. See MetricHeader for type. - * - * Generated from protobuf field string value = 4; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php deleted file mode 100644 index d71a5cdffb4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/MinuteRange.php +++ /dev/null @@ -1,220 +0,0 @@ -google.analytics.data.v1beta.MinuteRange - */ -class MinuteRange extends \Google\Protobuf\Internal\Message -{ - /** - * The inclusive start minute for the query as a number of minutes before now. - * For example, `"startMinutesAgo": 29` specifies the report should include - * 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`). - * - * Generated from protobuf field optional int32 start_minutes_ago = 1; - */ - protected $start_minutes_ago = null; - /** - * The inclusive end minute for the query as a number of minutes before now. - * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` - * specifies the report should include event data from prior to 15 minutes - * 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`). - * - * Generated from protobuf field optional int32 end_minutes_ago = 2; - */ - protected $end_minutes_ago = null; - /** - * Assigns a name to this minute 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, minute ranges are named by their zero based index - * in the request: `date_range_0`, `date_range_1`, etc. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $start_minutes_ago - * The inclusive start minute for the query as a number of minutes before now. - * For example, `"startMinutesAgo": 29` specifies the report should include - * 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`). - * @type int $end_minutes_ago - * The inclusive end minute for the query as a number of minutes before now. - * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` - * specifies the report should include event data from prior to 15 minutes - * 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`). - * @type string $name - * Assigns a name to this minute 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, minute ranges are named by their zero based index - * in the request: `date_range_0`, `date_range_1`, etc. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The inclusive start minute for the query as a number of minutes before now. - * For example, `"startMinutesAgo": 29` specifies the report should include - * 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`). - * - * Generated from protobuf field optional int32 start_minutes_ago = 1; - * @return int - */ - public function getStartMinutesAgo() - { - return isset($this->start_minutes_ago) ? $this->start_minutes_ago : 0; - } - - public function hasStartMinutesAgo() - { - return isset($this->start_minutes_ago); - } - - public function clearStartMinutesAgo() - { - unset($this->start_minutes_ago); - } - - /** - * The inclusive start minute for the query as a number of minutes before now. - * For example, `"startMinutesAgo": 29` specifies the report should include - * 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`). - * - * Generated from protobuf field optional int32 start_minutes_ago = 1; - * @param int $var - * @return $this - */ - public function setStartMinutesAgo($var) - { - GPBUtil::checkInt32($var); - $this->start_minutes_ago = $var; - - return $this; - } - - /** - * The inclusive end minute for the query as a number of minutes before now. - * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` - * specifies the report should include event data from prior to 15 minutes - * 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`). - * - * Generated from protobuf field optional int32 end_minutes_ago = 2; - * @return int - */ - public function getEndMinutesAgo() - { - return isset($this->end_minutes_ago) ? $this->end_minutes_ago : 0; - } - - public function hasEndMinutesAgo() - { - return isset($this->end_minutes_ago); - } - - public function clearEndMinutesAgo() - { - unset($this->end_minutes_ago); - } - - /** - * The inclusive end minute for the query as a number of minutes before now. - * Cannot be before `startMinutesAgo`. For example, `"endMinutesAgo": 15` - * specifies the report should include event data from prior to 15 minutes - * 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`). - * - * Generated from protobuf field optional int32 end_minutes_ago = 2; - * @param int $var - * @return $this - */ - public function setEndMinutesAgo($var) - { - GPBUtil::checkInt32($var); - $this->end_minutes_ago = $var; - - return $this; - } - - /** - * Assigns a name to this minute 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, minute ranges are named by their zero based index - * in the request: `date_range_0`, `date_range_1`, etc. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Assigns a name to this minute 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, minute ranges are named by their zero based index - * in the request: `date_range_0`, `date_range_1`, etc. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php deleted file mode 100644 index ac466fe4865..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/NumericValue.php +++ /dev/null @@ -1,108 +0,0 @@ -google.analytics.data.v1beta.NumericValue - */ -class NumericValue extends \Google\Protobuf\Internal\Message -{ - protected $one_value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $int64_value - * Integer value - * @type float $double_value - * Double value - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Integer value - * - * Generated from protobuf field int64 int64_value = 1; - * @return int|string - */ - public function getInt64Value() - { - return $this->readOneof(1); - } - - public function hasInt64Value() - { - return $this->hasOneof(1); - } - - /** - * Integer value - * - * Generated from protobuf field int64 int64_value = 1; - * @param int|string $var - * @return $this - */ - public function setInt64Value($var) - { - GPBUtil::checkInt64($var); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Double value - * - * Generated from protobuf field double double_value = 2; - * @return float - */ - public function getDoubleValue() - { - return $this->readOneof(2); - } - - public function hasDoubleValue() - { - return $this->hasOneof(2); - } - - /** - * Double value - * - * Generated from protobuf field double double_value = 2; - * @param float $var - * @return $this - */ - public function setDoubleValue($var) - { - GPBUtil::checkDouble($var); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getOneValue() - { - return $this->whichOneof("one_value"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php deleted file mode 100644 index bf52aa38f37..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy.php +++ /dev/null @@ -1,177 +0,0 @@ -google.analytics.data.v1beta.OrderBy - */ -class OrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - */ - protected $desc = false; - protected $one_order_by; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy $metric - * Sorts results by a metric's values. - * @type \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy $dimension - * Sorts results by a dimension's values. - * @type \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy $pivot - * Sorts results by a metric's values within a pivot column group. - * @type bool $desc - * If true, sorts by descending order. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Sorts results by a metric's values. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.MetricOrderBy metric = 1; - * @return \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy|null - */ - public function getMetric() - { - return $this->readOneof(1); - } - - public function hasMetric() - { - return $this->hasOneof(1); - } - - /** - * Sorts results by a metric's values. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.MetricOrderBy metric = 1; - * @param \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy $var - * @return $this - */ - public function setMetric($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\MetricOrderBy::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Sorts results by a dimension's values. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy dimension = 2; - * @return \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy|null - */ - public function getDimension() - { - return $this->readOneof(2); - } - - public function hasDimension() - { - return $this->hasOneof(2); - } - - /** - * Sorts results by a dimension's values. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy dimension = 2; - * @param \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy $var - * @return $this - */ - public function setDimension($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Sorts results by a metric's values within a pivot column group. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.PivotOrderBy pivot = 3; - * @return \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy|null - */ - public function getPivot() - { - return $this->readOneof(3); - } - - public function hasPivot() - { - return $this->hasOneof(3); - } - - /** - * Sorts results by a metric's values within a pivot column group. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.PivotOrderBy pivot = 3; - * @param \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy $var - * @return $this - */ - public function setPivot($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - * @return bool - */ - public function getDesc() - { - return $this->desc; - } - - /** - * If true, sorts by descending order. - * - * Generated from protobuf field bool desc = 4; - * @param bool $var - * @return $this - */ - public function setDesc($var) - { - GPBUtil::checkBool($var); - $this->desc = $var; - - return $this; - } - - /** - * @return string - */ - public function getOneOrderBy() - { - return $this->whichOneof("one_order_by"); - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php deleted file mode 100644 index caaffd85a29..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy.php +++ /dev/null @@ -1,104 +0,0 @@ -google.analytics.data.v1beta.OrderBy.DimensionOrderBy - */ -class DimensionOrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - */ - protected $dimension_name = ''; - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; - */ - protected $order_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * A dimension name in the request to order by. - * @type int $order_type - * Controls the rule for dimension value ordering. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * A dimension name in the request to order by. - * - * Generated from protobuf field string dimension_name = 1; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; - * @return int - */ - public function getOrderType() - { - return $this->order_type; - } - - /** - * Controls the rule for dimension value ordering. - * - * Generated from protobuf field .google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType order_type = 2; - * @param int $var - * @return $this - */ - public function setOrderType($var) - { - GPBUtil::checkEnum($var, \Google\Analytics\Data\V1beta\OrderBy\DimensionOrderBy\OrderType::class); - $this->order_type = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DimensionOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_DimensionOrderBy::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php deleted file mode 100644 index d0ce40c9141..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/DimensionOrderBy/OrderType.php +++ /dev/null @@ -1,76 +0,0 @@ -google.analytics.data.v1beta.OrderBy.DimensionOrderBy.OrderType - */ -class OrderType -{ - /** - * Unspecified. - * - * Generated from protobuf enum ORDER_TYPE_UNSPECIFIED = 0; - */ - const ORDER_TYPE_UNSPECIFIED = 0; - /** - * Alphanumeric sort by Unicode code point. For example, "2" < "A" < "X" < - * "b" < "z". - * - * Generated from protobuf enum ALPHANUMERIC = 1; - */ - const ALPHANUMERIC = 1; - /** - * Case insensitive alphanumeric sort by lower case Unicode code point. - * For example, "2" < "A" < "b" < "X" < "z". - * - * Generated from protobuf enum CASE_INSENSITIVE_ALPHANUMERIC = 2; - */ - const CASE_INSENSITIVE_ALPHANUMERIC = 2; - /** - * Dimension values are converted to numbers before sorting. For example - * in NUMERIC sort, "25" < "100", and in `ALPHANUMERIC` sort, "100" < - * "25". Non-numeric dimension values all have equal ordering value below - * all numeric values. - * - * Generated from protobuf enum NUMERIC = 3; - */ - const NUMERIC = 3; - - private static $valueToName = [ - self::ORDER_TYPE_UNSPECIFIED => 'ORDER_TYPE_UNSPECIFIED', - self::ALPHANUMERIC => 'ALPHANUMERIC', - self::CASE_INSENSITIVE_ALPHANUMERIC => 'CASE_INSENSITIVE_ALPHANUMERIC', - self::NUMERIC => 'NUMERIC', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(OrderType::class, \Google\Analytics\Data\V1beta\OrderBy_DimensionOrderBy_OrderType::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php deleted file mode 100644 index 27ab3306a35..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/MetricOrderBy.php +++ /dev/null @@ -1,70 +0,0 @@ -google.analytics.data.v1beta.OrderBy.MetricOrderBy - */ -class MetricOrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - */ - protected $metric_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $metric_name - * A metric name in the request to order by. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - * @return string - */ - public function getMetricName() - { - return $this->metric_name; - } - - /** - * A metric name in the request to order by. - * - * Generated from protobuf field string metric_name = 1; - * @param string $var - * @return $this - */ - public function setMetricName($var) - { - GPBUtil::checkString($var, True); - $this->metric_name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MetricOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_MetricOrderBy::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php deleted file mode 100644 index 4fd1c22f4b2..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy.php +++ /dev/null @@ -1,120 +0,0 @@ -google.analytics.data.v1beta.OrderBy.PivotOrderBy - */ -class PivotOrderBy extends \Google\Protobuf\Internal\Message -{ - /** - * In the response to order by, order rows by this column. Must be a metric - * name from the request. - * - * Generated from protobuf field string metric_name = 1; - */ - protected $metric_name = ''; - /** - * Used to select a dimension name and value pivot. If multiple pivot - * selections are given, the sort occurs on rows where all pivot selection - * dimension name and value pairs match the row's dimension name and value - * pair. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; - */ - private $pivot_selections; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $metric_name - * In the response to order by, order rows by this column. Must be a metric - * name from the request. - * @type array<\Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection>|\Google\Protobuf\Internal\RepeatedField $pivot_selections - * Used to select a dimension name and value pivot. If multiple pivot - * selections are given, the sort occurs on rows where all pivot selection - * dimension name and value pairs match the row's dimension name and value - * pair. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * In the response to order by, order rows by this column. Must be a metric - * name from the request. - * - * Generated from protobuf field string metric_name = 1; - * @return string - */ - public function getMetricName() - { - return $this->metric_name; - } - - /** - * In the response to order by, order rows by this column. Must be a metric - * name from the request. - * - * Generated from protobuf field string metric_name = 1; - * @param string $var - * @return $this - */ - public function setMetricName($var) - { - GPBUtil::checkString($var, True); - $this->metric_name = $var; - - return $this; - } - - /** - * Used to select a dimension name and value pivot. If multiple pivot - * selections are given, the sort occurs on rows where all pivot selection - * dimension name and value pairs match the row's dimension name and value - * pair. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPivotSelections() - { - return $this->pivot_selections; - } - - /** - * Used to select a dimension name and value pivot. If multiple pivot - * selections are given, the sort occurs on rows where all pivot selection - * dimension name and value pairs match the row's dimension name and value - * pair. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection pivot_selections = 2; - * @param array<\Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPivotSelections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy\PivotOrderBy\PivotSelection::class); - $this->pivot_selections = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PivotOrderBy::class, \Google\Analytics\Data\V1beta\OrderBy_PivotOrderBy::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php deleted file mode 100644 index d50a7262d48..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/OrderBy/PivotOrderBy/PivotSelection.php +++ /dev/null @@ -1,117 +0,0 @@ -google.analytics.data.v1beta.OrderBy.PivotOrderBy.PivotSelection - */ -class PivotSelection extends \Google\Protobuf\Internal\Message -{ - /** - * Must be a dimension name from the request. - * - * Generated from protobuf field string dimension_name = 1; - */ - protected $dimension_name = ''; - /** - * Order by only when the named dimension is this value. - * - * Generated from protobuf field string dimension_value = 2; - */ - protected $dimension_value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dimension_name - * Must be a dimension name from the request. - * @type string $dimension_value - * Order by only when the named dimension is this value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Must be a dimension name from the request. - * - * Generated from protobuf field string dimension_name = 1; - * @return string - */ - public function getDimensionName() - { - return $this->dimension_name; - } - - /** - * Must be a dimension name from the request. - * - * Generated from protobuf field string dimension_name = 1; - * @param string $var - * @return $this - */ - public function setDimensionName($var) - { - GPBUtil::checkString($var, True); - $this->dimension_name = $var; - - return $this; - } - - /** - * Order by only when the named dimension is this value. - * - * Generated from protobuf field string dimension_value = 2; - * @return string - */ - public function getDimensionValue() - { - return $this->dimension_value; - } - - /** - * Order by only when the named dimension is this value. - * - * Generated from protobuf field string dimension_value = 2; - * @param string $var - * @return $this - */ - public function setDimensionValue($var) - { - GPBUtil::checkString($var, True); - $this->dimension_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PivotSelection::class, \Google\Analytics\Data\V1beta\OrderBy_PivotOrderBy_PivotSelection::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php deleted file mode 100644 index 1569a761e9b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Pivot.php +++ /dev/null @@ -1,255 +0,0 @@ -google.analytics.data.v1beta.Pivot - */ -class Pivot extends \Google\Protobuf\Internal\Message -{ - /** - * Dimension names for visible columns in the report response. Including - * "dateRange" produces a date range column; for each row in the response, - * dimension values in the date range column will indicate the corresponding - * date range from the request. - * - * Generated from protobuf field repeated string field_names = 1; - */ - private $field_names; - /** - * Specifies how dimensions are ordered in the pivot. In the first Pivot, the - * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent - * Pivots, the OrderBys determine only PivotDimensionHeader ordering. - * Dimensions specified in these OrderBys must be a subset of - * Pivot.field_names. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; - */ - private $order_bys; - /** - * The row count of the start row. The first row is counted as row 0. - * - * Generated from protobuf field int64 offset = 3; - */ - protected $offset = 0; - /** - * The number of unique combinations of dimension values to return in this - * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for - * single pivot requests. - * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` - * must not exceed 250,000. For example, a two pivot request with `limit: - * 1000` in each pivot will fail because the product is `1,000,000`. - * - * Generated from protobuf field int64 limit = 4; - */ - protected $limit = 0; - /** - * Aggregate the metrics by dimensions in this pivot using the specified - * metric_aggregations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; - */ - private $metric_aggregations; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $field_names - * Dimension names for visible columns in the report response. Including - * "dateRange" produces a date range column; for each row in the response, - * dimension values in the date range column will indicate the corresponding - * date range from the request. - * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys - * Specifies how dimensions are ordered in the pivot. In the first Pivot, the - * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent - * Pivots, the OrderBys determine only PivotDimensionHeader ordering. - * Dimensions specified in these OrderBys must be a subset of - * Pivot.field_names. - * @type int|string $offset - * The row count of the start row. The first row is counted as row 0. - * @type int|string $limit - * The number of unique combinations of dimension values to return in this - * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for - * single pivot requests. - * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` - * must not exceed 250,000. For example, a two pivot request with `limit: - * 1000` in each pivot will fail because the product is `1,000,000`. - * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations - * Aggregate the metrics by dimensions in this pivot using the specified - * metric_aggregations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Dimension names for visible columns in the report response. Including - * "dateRange" produces a date range column; for each row in the response, - * dimension values in the date range column will indicate the corresponding - * date range from the request. - * - * Generated from protobuf field repeated string field_names = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFieldNames() - { - return $this->field_names; - } - - /** - * Dimension names for visible columns in the report response. Including - * "dateRange" produces a date range column; for each row in the response, - * dimension values in the date range column will indicate the corresponding - * date range from the request. - * - * Generated from protobuf field repeated string field_names = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFieldNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->field_names = $arr; - - return $this; - } - - /** - * Specifies how dimensions are ordered in the pivot. In the first Pivot, the - * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent - * Pivots, the OrderBys determine only PivotDimensionHeader ordering. - * Dimensions specified in these OrderBys must be a subset of - * Pivot.field_names. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOrderBys() - { - return $this->order_bys; - } - - /** - * Specifies how dimensions are ordered in the pivot. In the first Pivot, the - * OrderBys determine Row and PivotDimensionHeader ordering; in subsequent - * Pivots, the OrderBys determine only PivotDimensionHeader ordering. - * Dimensions specified in these OrderBys must be a subset of - * Pivot.field_names. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 2; - * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOrderBys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); - $this->order_bys = $arr; - - return $this; - } - - /** - * The row count of the start row. The first row is counted as row 0. - * - * Generated from protobuf field int64 offset = 3; - * @return int|string - */ - public function getOffset() - { - return $this->offset; - } - - /** - * The row count of the start row. The first row is counted as row 0. - * - * Generated from protobuf field int64 offset = 3; - * @param int|string $var - * @return $this - */ - public function setOffset($var) - { - GPBUtil::checkInt64($var); - $this->offset = $var; - - return $this; - } - - /** - * The number of unique combinations of dimension values to return in this - * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for - * single pivot requests. - * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` - * must not exceed 250,000. For example, a two pivot request with `limit: - * 1000` in each pivot will fail because the product is `1,000,000`. - * - * Generated from protobuf field int64 limit = 4; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * The number of unique combinations of dimension values to return in this - * pivot. The `limit` parameter is required. A `limit` of 10,000 is common for - * single pivot requests. - * The product of the `limit` for each `pivot` in a `RunPivotReportRequest` - * must not exceed 250,000. For example, a two pivot request with `limit: - * 1000` in each pivot will fail because the product is `1,000,000`. - * - * Generated from protobuf field int64 limit = 4; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - - /** - * Aggregate the metrics by dimensions in this pivot using the specified - * metric_aggregations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricAggregations() - { - return $this->metric_aggregations; - } - - /** - * Aggregate the metrics by dimensions in this pivot using the specified - * metric_aggregations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricAggregations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); - $this->metric_aggregations = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php deleted file mode 100644 index a96c75982ac..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotDimensionHeader.php +++ /dev/null @@ -1,67 +0,0 @@ -google.analytics.data.v1beta.PivotDimensionHeader - */ -class PivotDimensionHeader extends \Google\Protobuf\Internal\Message -{ - /** - * Values of multiple dimensions in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - */ - private $dimension_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values - * Values of multiple dimensions in a pivot. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Values of multiple dimensions in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionValues() - { - return $this->dimension_values; - } - - /** - * Values of multiple dimensions in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionValue::class); - $this->dimension_values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php deleted file mode 100644 index e53d39b9c1f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PivotHeader.php +++ /dev/null @@ -1,113 +0,0 @@ -google.analytics.data.v1beta.PivotHeader - */ -class PivotHeader extends \Google\Protobuf\Internal\Message -{ - /** - * The size is the same as the cardinality of the corresponding dimension - * combinations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; - */ - private $pivot_dimension_headers; - /** - * The cardinality of the pivot. The total number of rows for this pivot's - * fields regardless of how the parameters `offset` and `limit` are specified - * in the request. - * - * Generated from protobuf field int32 row_count = 2; - */ - protected $row_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\PivotDimensionHeader>|\Google\Protobuf\Internal\RepeatedField $pivot_dimension_headers - * The size is the same as the cardinality of the corresponding dimension - * combinations. - * @type int $row_count - * The cardinality of the pivot. The total number of rows for this pivot's - * fields regardless of how the parameters `offset` and `limit` are specified - * in the request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The size is the same as the cardinality of the corresponding dimension - * combinations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPivotDimensionHeaders() - { - return $this->pivot_dimension_headers; - } - - /** - * The size is the same as the cardinality of the corresponding dimension - * combinations. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotDimensionHeader pivot_dimension_headers = 1; - * @param array<\Google\Analytics\Data\V1beta\PivotDimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPivotDimensionHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\PivotDimensionHeader::class); - $this->pivot_dimension_headers = $arr; - - return $this; - } - - /** - * The cardinality of the pivot. The total number of rows for this pivot's - * fields regardless of how the parameters `offset` and `limit` are specified - * in the request. - * - * Generated from protobuf field int32 row_count = 2; - * @return int - */ - public function getRowCount() - { - return $this->row_count; - } - - /** - * The cardinality of the pivot. The total number of rows for this pivot's - * fields regardless of how the parameters `offset` and `limit` are specified - * in the request. - * - * Generated from protobuf field int32 row_count = 2; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php deleted file mode 100644 index 689ca28e00d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/PropertyQuota.php +++ /dev/null @@ -1,363 +0,0 @@ -google.analytics.data.v1beta.PropertyQuota - */ -class PropertyQuota extends \Google\Protobuf\Internal\Message -{ - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; - */ - protected $tokens_per_day = null; - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; - */ - protected $tokens_per_hour = null; - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; - */ - protected $concurrent_requests = 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; - */ - protected $server_errors_per_project_per_hour = 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; - */ - protected $potentially_thresholded_requests_per_hour = null; - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; - */ - protected $tokens_per_project_per_hour = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_day - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_hour - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * @type \Google\Analytics\Data\V1beta\QuotaStatus $concurrent_requests - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * @type \Google\Analytics\Data\V1beta\QuotaStatus $server_errors_per_project_per_hour - * 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. - * @type \Google\Analytics\Data\V1beta\QuotaStatus $potentially_thresholded_requests_per_hour - * 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. - * @type \Google\Analytics\Data\V1beta\QuotaStatus $tokens_per_project_per_hour - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getTokensPerDay() - { - return $this->tokens_per_day; - } - - public function hasTokensPerDay() - { - return isset($this->tokens_per_day); - } - - public function clearTokensPerDay() - { - unset($this->tokens_per_day); - } - - /** - * Standard Analytics Properties can use up to 200,000 tokens per day; - * Analytics 360 Properties can use 2,000,000 tokens per day. Most requests - * consume fewer than 10 tokens. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_day = 1; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setTokensPerDay($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->tokens_per_day = $var; - - return $this; - } - - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getTokensPerHour() - { - return $this->tokens_per_hour; - } - - public function hasTokensPerHour() - { - return isset($this->tokens_per_hour); - } - - public function clearTokensPerHour() - { - unset($this->tokens_per_hour); - } - - /** - * Standard Analytics Properties can use up to 40,000 tokens per hour; - * Analytics 360 Properties can use 400,000 tokens per hour. An API request - * consumes a single number of tokens, and that number is deducted from all of - * the hourly, daily, and per project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_hour = 2; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setTokensPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->tokens_per_hour = $var; - - return $this; - } - - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getConcurrentRequests() - { - return $this->concurrent_requests; - } - - public function hasConcurrentRequests() - { - return isset($this->concurrent_requests); - } - - public function clearConcurrentRequests() - { - unset($this->concurrent_requests); - } - - /** - * Standard Analytics Properties can send up to 10 concurrent requests; - * Analytics 360 Properties can use up to 50 concurrent requests. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus concurrent_requests = 3; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setConcurrentRequests($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->concurrent_requests = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getServerErrorsPerProjectPerHour() - { - return $this->server_errors_per_project_per_hour; - } - - public function hasServerErrorsPerProjectPerHour() - { - return isset($this->server_errors_per_project_per_hour); - } - - public function clearServerErrorsPerProjectPerHour() - { - unset($this->server_errors_per_project_per_hour); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus server_errors_per_project_per_hour = 4; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setServerErrorsPerProjectPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->server_errors_per_project_per_hour = $var; - - 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getPotentiallyThresholdedRequestsPerHour() - { - return $this->potentially_thresholded_requests_per_hour; - } - - public function hasPotentiallyThresholdedRequestsPerHour() - { - return isset($this->potentially_thresholded_requests_per_hour); - } - - public function clearPotentiallyThresholdedRequestsPerHour() - { - unset($this->potentially_thresholded_requests_per_hour); - } - - /** - * 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. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus potentially_thresholded_requests_per_hour = 5; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setPotentiallyThresholdedRequestsPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->potentially_thresholded_requests_per_hour = $var; - - return $this; - } - - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; - * @return \Google\Analytics\Data\V1beta\QuotaStatus|null - */ - public function getTokensPerProjectPerHour() - { - return $this->tokens_per_project_per_hour; - } - - public function hasTokensPerProjectPerHour() - { - return isset($this->tokens_per_project_per_hour); - } - - public function clearTokensPerProjectPerHour() - { - unset($this->tokens_per_project_per_hour); - } - - /** - * Analytics Properties can use up to 35% of their tokens per project per - * hour. This amounts to standard Analytics Properties can use up to 14,000 - * tokens per project per hour, and Analytics 360 Properties can use 140,000 - * tokens per project per hour. An API request consumes a single number of - * tokens, and that number is deducted from all of the hourly, daily, and per - * project hourly quotas. - * - * Generated from protobuf field .google.analytics.data.v1beta.QuotaStatus tokens_per_project_per_hour = 6; - * @param \Google\Analytics\Data\V1beta\QuotaStatus $var - * @return $this - */ - public function setTokensPerProjectPerHour($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\QuotaStatus::class); - $this->tokens_per_project_per_hour = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php deleted file mode 100644 index 2c72532b7d9..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportRequest.php +++ /dev/null @@ -1,205 +0,0 @@ -google.analytics.data.v1beta.QueryAudienceExportRequest - */ -class QueryAudienceExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $name = ''; - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $offset = 0; - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $limit = 0; - - /** - * @param string $name Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * @return \Google\Analytics\Data\V1beta\QueryAudienceExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * @type int|string $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int|string $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getOffset() - { - return $this->offset; - } - - /** - * Optional. The row count of the start row. The first row is counted as row - * 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setOffset($var) - { - GPBUtil::checkInt64($var); - $this->offset = $var; - - return $this; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php deleted file mode 100644 index 71591a68897..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QueryAudienceExportResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.analytics.data.v1beta.QueryAudienceExportResponse - */ -class QueryAudienceExportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Configuration data about AudienceExport being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceExport correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; - */ - protected $audience_export = null; - /** - * Rows for each user in an audience export. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; - */ - private $audience_rows; - /** - * The total number of rows in the AudienceExport result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - */ - protected $row_count = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Analytics\Data\V1beta\AudienceExport $audience_export - * Configuration data about AudienceExport being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceExport correspond to the columns in the AudienceRows. - * @type array<\Google\Analytics\Data\V1beta\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $audience_rows - * Rows for each user in an audience export. The number of rows in this - * response will be less than or equal to request's page size. - * @type int $row_count - * The total number of rows in the AudienceExport result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Configuration data about AudienceExport being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceExport correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; - * @return \Google\Analytics\Data\V1beta\AudienceExport|null - */ - public function getAudienceExport() - { - return $this->audience_export; - } - - public function hasAudienceExport() - { - return isset($this->audience_export); - } - - public function clearAudienceExport() - { - unset($this->audience_export); - } - - /** - * Configuration data about AudienceExport being queried. Returned to help - * interpret the audience rows in this response. For example, the dimensions - * in this AudienceExport correspond to the columns in the AudienceRows. - * - * Generated from protobuf field optional .google.analytics.data.v1beta.AudienceExport audience_export = 1; - * @param \Google\Analytics\Data\V1beta\AudienceExport $var - * @return $this - */ - public function setAudienceExport($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\AudienceExport::class); - $this->audience_export = $var; - - return $this; - } - - /** - * Rows for each user in an audience export. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAudienceRows() - { - return $this->audience_rows; - } - - /** - * Rows for each user in an audience export. The number of rows in this - * response will be less than or equal to request's page size. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.AudienceRow audience_rows = 2; - * @param array<\Google\Analytics\Data\V1beta\AudienceRow>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAudienceRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\AudienceRow::class); - $this->audience_rows = $arr; - - return $this; - } - - /** - * The total number of rows in the AudienceExport result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @return int - */ - public function getRowCount() - { - return isset($this->row_count) ? $this->row_count : 0; - } - - public function hasRowCount() - { - return isset($this->row_count); - } - - public function clearRowCount() - { - unset($this->row_count); - } - - /** - * The total number of rows in the AudienceExport result. `rowCount` is - * independent of the number of rows returned in the response, the `limit` - * request parameter, and the `offset` request parameter. For example if a - * query returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field optional int32 row_count = 3; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php deleted file mode 100644 index 77a8b488f2e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/QuotaStatus.php +++ /dev/null @@ -1,121 +0,0 @@ -google.analytics.data.v1beta.QuotaStatus - */ -class QuotaStatus extends \Google\Protobuf\Internal\Message -{ - /** - * Quota consumed by this request. - * - * Generated from protobuf field optional int32 consumed = 1; - */ - protected $consumed = null; - /** - * Quota remaining after this request. - * - * Generated from protobuf field optional int32 remaining = 2; - */ - protected $remaining = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $consumed - * Quota consumed by this request. - * @type int $remaining - * Quota remaining after this request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * Quota consumed by this request. - * - * Generated from protobuf field optional int32 consumed = 1; - * @return int - */ - public function getConsumed() - { - return isset($this->consumed) ? $this->consumed : 0; - } - - public function hasConsumed() - { - return isset($this->consumed); - } - - public function clearConsumed() - { - unset($this->consumed); - } - - /** - * Quota consumed by this request. - * - * Generated from protobuf field optional int32 consumed = 1; - * @param int $var - * @return $this - */ - public function setConsumed($var) - { - GPBUtil::checkInt32($var); - $this->consumed = $var; - - return $this; - } - - /** - * Quota remaining after this request. - * - * Generated from protobuf field optional int32 remaining = 2; - * @return int - */ - public function getRemaining() - { - return isset($this->remaining) ? $this->remaining : 0; - } - - public function hasRemaining() - { - return isset($this->remaining); - } - - public function clearRemaining() - { - unset($this->remaining); - } - - /** - * Quota remaining after this request. - * - * Generated from protobuf field optional int32 remaining = 2; - * @param int $var - * @return $this - */ - public function setRemaining($var) - { - GPBUtil::checkInt32($var); - $this->remaining = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php deleted file mode 100644 index a2642b63961..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData.php +++ /dev/null @@ -1,457 +0,0 @@ -google.analytics.data.v1beta.ResponseMetaData - */ -class ResponseMetaData extends \Google\Protobuf\Internal\Message -{ - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - */ - protected $data_loss_from_other_row = false; - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - */ - protected $schema_restriction_response = null; - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - */ - protected $currency_code = null; - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - */ - protected $time_zone = null; - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - */ - protected $empty_reason = null; - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - */ - protected $subject_to_thresholding = null; - /** - * If this report results is - * [sampled](https://support.google.com/analytics/answer/13331292), this - * describes the percentage of events used in this 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; - */ - private $sampling_metadatas; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $data_loss_from_other_row - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * @type \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse $schema_restriction_response - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * @type string $currency_code - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * @type string $time_zone - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * @type string $empty_reason - * If empty reason is specified, the report is empty for this reason. - * @type bool $subject_to_thresholding - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630). - * @type array<\Google\Analytics\Data\V1beta\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $sampling_metadatas - * If this report results is - * [sampled](https://support.google.com/analytics/answer/13331292), this - * describes the percentage of events used in this 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. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - * @return bool - */ - public function getDataLossFromOtherRow() - { - return $this->data_loss_from_other_row; - } - - /** - * If true, indicates some buckets of dimension combinations are rolled into - * "(other)" row. This can happen for high cardinality reports. - * The metadata parameter dataLossFromOtherRow is populated based on the - * aggregated data table used in the report. The parameter will be accurately - * populated regardless of the filters and limits in the report. - * For example, the (other) row could be dropped from the report because the - * request contains a filter on sessionSource = google. This parameter will - * still be populated if data loss from other row was present in the input - * aggregate data used to generate this report. - * To learn more, see [About the (other) row and data - * sampling](https://support.google.com/analytics/answer/13208658#reports). - * - * Generated from protobuf field bool data_loss_from_other_row = 3; - * @param bool $var - * @return $this - */ - public function setDataLossFromOtherRow($var) - { - GPBUtil::checkBool($var); - $this->data_loss_from_other_row = $var; - - return $this; - } - - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - * @return \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse|null - */ - public function getSchemaRestrictionResponse() - { - return $this->schema_restriction_response; - } - - public function hasSchemaRestrictionResponse() - { - return isset($this->schema_restriction_response); - } - - public function clearSchemaRestrictionResponse() - { - unset($this->schema_restriction_response); - } - - /** - * Describes the schema restrictions actively enforced in creating this - * report. To learn more, see [Access and data-restriction - * management](https://support.google.com/analytics/answer/10851388). - * - * Generated from protobuf field optional .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse schema_restriction_response = 4; - * @param \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse $var - * @return $this - */ - public function setSchemaRestrictionResponse($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse::class); - $this->schema_restriction_response = $var; - - return $this; - } - - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - * @return string - */ - public function getCurrencyCode() - { - return isset($this->currency_code) ? $this->currency_code : ''; - } - - public function hasCurrencyCode() - { - return isset($this->currency_code); - } - - public function clearCurrencyCode() - { - unset($this->currency_code); - } - - /** - * The currency code used in this report. Intended to be used in formatting - * currency metrics like `purchaseRevenue` for visualization. If currency_code - * was specified in the request, this response parameter will echo the request - * parameter; otherwise, this response parameter is the property's current - * currency_code. - * Currency codes are string encodings of currency types from the ISO 4217 - * standard (https://en.wikipedia.org/wiki/ISO_4217); for example "USD", - * "EUR", "JPY". To learn more, see - * https://support.google.com/analytics/answer/9796179. - * - * Generated from protobuf field optional string currency_code = 5; - * @param string $var - * @return $this - */ - public function setCurrencyCode($var) - { - GPBUtil::checkString($var, True); - $this->currency_code = $var; - - return $this; - } - - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - * @return string - */ - public function getTimeZone() - { - return isset($this->time_zone) ? $this->time_zone : ''; - } - - public function hasTimeZone() - { - return isset($this->time_zone); - } - - public function clearTimeZone() - { - unset($this->time_zone); - } - - /** - * The property's current timezone. Intended to be used to interpret - * time-based dimensions like `hour` and `minute`. Formatted as strings from - * the IANA Time Zone database (https://www.iana.org/time-zones); for example - * "America/New_York" or "Asia/Tokyo". - * - * Generated from protobuf field optional string time_zone = 6; - * @param string $var - * @return $this - */ - public function setTimeZone($var) - { - GPBUtil::checkString($var, True); - $this->time_zone = $var; - - return $this; - } - - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - * @return string - */ - public function getEmptyReason() - { - return isset($this->empty_reason) ? $this->empty_reason : ''; - } - - public function hasEmptyReason() - { - return isset($this->empty_reason); - } - - public function clearEmptyReason() - { - unset($this->empty_reason); - } - - /** - * If empty reason is specified, the report is empty for this reason. - * - * Generated from protobuf field optional string empty_reason = 7; - * @param string $var - * @return $this - */ - public function setEmptyReason($var) - { - GPBUtil::checkString($var, True); - $this->empty_reason = $var; - - return $this; - } - - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - * @return bool - */ - public function getSubjectToThresholding() - { - return isset($this->subject_to_thresholding) ? $this->subject_to_thresholding : false; - } - - public function hasSubjectToThresholding() - { - return isset($this->subject_to_thresholding); - } - - public function clearSubjectToThresholding() - { - unset($this->subject_to_thresholding); - } - - /** - * If `subjectToThresholding` is true, this report is subject to thresholding - * and only returns data that meets the minimum aggregation thresholds. It is - * possible for a request to be subject to thresholding thresholding and no - * data is absent from the report, and this happens when all data is above the - * thresholds. To learn more, see [Data - * thresholds](https://support.google.com/analytics/answer/9383630). - * - * Generated from protobuf field optional bool subject_to_thresholding = 8; - * @param bool $var - * @return $this - */ - public function setSubjectToThresholding($var) - { - GPBUtil::checkBool($var); - $this->subject_to_thresholding = $var; - - return $this; - } - - /** - * If this report results is - * [sampled](https://support.google.com/analytics/answer/13331292), this - * describes the percentage of events used in this 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSamplingMetadatas() - { - return $this->sampling_metadatas; - } - - /** - * If this report results is - * [sampled](https://support.google.com/analytics/answer/13331292), this - * describes the percentage of events used in this 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. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.SamplingMetadata sampling_metadatas = 9; - * @param array<\Google\Analytics\Data\V1beta\SamplingMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSamplingMetadatas($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\SamplingMetadata::class); - $this->sampling_metadatas = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php deleted file mode 100644 index 38739908def..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse.php +++ /dev/null @@ -1,84 +0,0 @@ -google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse - */ -class SchemaRestrictionResponse extends \Google\Protobuf\Internal\Message -{ - /** - * All restrictions actively enforced in creating the report. For example, - * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. - * However, this active response restriction is only populated if the user's - * custom role disallows access to `REVENUE_DATA`. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; - */ - private $active_metric_restrictions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $active_metric_restrictions - * All restrictions actively enforced in creating the report. For example, - * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. - * However, this active response restriction is only populated if the user's - * custom role disallows access to `REVENUE_DATA`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * All restrictions actively enforced in creating the report. For example, - * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. - * However, this active response restriction is only populated if the user's - * custom role disallows access to `REVENUE_DATA`. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getActiveMetricRestrictions() - { - return $this->active_metric_restrictions; - } - - /** - * All restrictions actively enforced in creating the report. For example, - * `purchaseRevenue` always has the restriction type `REVENUE_DATA`. - * However, this active response restriction is only populated if the user's - * custom role disallows access to `REVENUE_DATA`. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction active_metric_restrictions = 1; - * @param array<\Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setActiveMetricRestrictions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\ResponseMetaData\SchemaRestrictionResponse\ActiveMetricRestriction::class); - $this->active_metric_restrictions = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SchemaRestrictionResponse::class, \Google\Analytics\Data\V1beta\ResponseMetaData_SchemaRestrictionResponse::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php deleted file mode 100644 index 246f6d81d0c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/ResponseMetaData/SchemaRestrictionResponse/ActiveMetricRestriction.php +++ /dev/null @@ -1,114 +0,0 @@ -google.analytics.data.v1beta.ResponseMetaData.SchemaRestrictionResponse.ActiveMetricRestriction - */ -class ActiveMetricRestriction extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the restricted metric. - * - * Generated from protobuf field optional string metric_name = 1; - */ - protected $metric_name = null; - /** - * The reason for this metric's restriction. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; - */ - private $restricted_metric_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $metric_name - * The name of the restricted metric. - * @type array|\Google\Protobuf\Internal\RepeatedField $restricted_metric_types - * The reason for this metric's restriction. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * The name of the restricted metric. - * - * Generated from protobuf field optional string metric_name = 1; - * @return string - */ - public function getMetricName() - { - return isset($this->metric_name) ? $this->metric_name : ''; - } - - public function hasMetricName() - { - return isset($this->metric_name); - } - - public function clearMetricName() - { - unset($this->metric_name); - } - - /** - * The name of the restricted metric. - * - * Generated from protobuf field optional string metric_name = 1; - * @param string $var - * @return $this - */ - public function setMetricName($var) - { - GPBUtil::checkString($var, True); - $this->metric_name = $var; - - return $this; - } - - /** - * The reason for this metric's restriction. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRestrictedMetricTypes() - { - return $this->restricted_metric_types; - } - - /** - * The reason for this metric's restriction. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.RestrictedMetricType restricted_metric_types = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRestrictedMetricTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\RestrictedMetricType::class); - $this->restricted_metric_types = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ActiveMetricRestriction::class, \Google\Analytics\Data\V1beta\ResponseMetaData_SchemaRestrictionResponse_ActiveMetricRestriction::class); - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php deleted file mode 100644 index 4d77bccc258..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RestrictedMetricType.php +++ /dev/null @@ -1,62 +0,0 @@ -google.analytics.data.v1beta.RestrictedMetricType - */ -class RestrictedMetricType -{ - /** - * Unspecified type. - * - * Generated from protobuf enum RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; - */ - const RESTRICTED_METRIC_TYPE_UNSPECIFIED = 0; - /** - * Cost metrics such as `adCost`. - * - * Generated from protobuf enum COST_DATA = 1; - */ - const COST_DATA = 1; - /** - * Revenue metrics such as `purchaseRevenue`. - * - * Generated from protobuf enum REVENUE_DATA = 2; - */ - const REVENUE_DATA = 2; - - private static $valueToName = [ - self::RESTRICTED_METRIC_TYPE_UNSPECIFIED => 'RESTRICTED_METRIC_TYPE_UNSPECIFIED', - self::COST_DATA => 'COST_DATA', - self::REVENUE_DATA => 'REVENUE_DATA', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php deleted file mode 100644 index fb28b01a352..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/Row.php +++ /dev/null @@ -1,138 +0,0 @@ -google.analytics.data.v1beta.Row - */ -class Row extends \Google\Protobuf\Internal\Message -{ - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - */ - private $dimension_values; - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; - */ - private $metric_values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $dimension_values - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * @type array<\Google\Analytics\Data\V1beta\MetricValue>|\Google\Protobuf\Internal\RepeatedField $metric_values - * List of requested visible metric values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionValues() - { - return $this->dimension_values; - } - - /** - * List of requested dimension values. In a PivotReport, dimension_values - * are only listed for dimensions included in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionValue dimension_values = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionValue::class); - $this->dimension_values = $arr; - - return $this; - } - - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricValues() - { - return $this->metric_values; - } - - /** - * List of requested visible metric values. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricValue metric_values = 2; - * @param array<\Google\Analytics\Data\V1beta\MetricValue>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricValue::class); - $this->metric_values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php deleted file mode 100644 index e08a64ae635..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportRequest.php +++ /dev/null @@ -1,553 +0,0 @@ -google.analytics.data.v1beta.RunPivotReportRequest - */ -class RunPivotReportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * 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 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * The dimensions requested. All defined dimensions must be used by one of the - * following: dimension_expression, dimension_filter, pivots, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - */ - private $dimensions; - /** - * The metrics requested, at least one metric needs to be specified. All - * defined metrics must be used by one of the following: metric_expression, - * metric_filter, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - */ - private $metrics; - /** - * The date range to retrieve event data for the report. If multiple date - * ranges are specified, event data from each date range is used in the - * report. A special dimension with field name "dateRange" can be included in - * a Pivot's field names; if included, the report compares between date - * ranges. In a cohort request, this `dateRanges` must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - */ - private $date_ranges; - /** - * Describes the visual format of the report's dimensions in columns or rows. - * The union of the fieldNames (dimension names) in all pivots must be a - * subset of dimension names defined in Dimensions. No two pivots can share a - * dimension. A dimension is only visible if it appears in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; - */ - private $pivots; - /** - * The filter clause of dimensions. Dimensions must be requested to be used in - * this filter. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; - */ - protected $dimension_filter = null; - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Metrics must be requested to be used in this filter. - * Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; - */ - protected $metric_filter = null; - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 8; - */ - protected $currency_code = ''; - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; - */ - protected $cohort_spec = null; - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 10; - */ - protected $keep_empty_rows = false; - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 11; - */ - protected $return_property_quota = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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 - * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * The dimensions requested. All defined dimensions must be used by one of the - * following: dimension_expression, dimension_filter, pivots, order_bys. - * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metrics requested, at least one metric needs to be specified. All - * defined metrics must be used by one of the following: metric_expression, - * metric_filter, order_bys. - * @type array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges - * The date range to retrieve event data for the report. If multiple date - * ranges are specified, event data from each date range is used in the - * report. A special dimension with field name "dateRange" can be included in - * a Pivot's field names; if included, the report compares between date - * ranges. In a cohort request, this `dateRanges` must be unspecified. - * @type array<\Google\Analytics\Data\V1beta\Pivot>|\Google\Protobuf\Internal\RepeatedField $pivots - * Describes the visual format of the report's dimensions in columns or rows. - * The union of the fieldNames (dimension names) in all pivots must be a - * subset of dimension names defined in Dimensions. No two pivots can share a - * dimension. A dimension is only visible if it appears in a pivot. - * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter - * The filter clause of dimensions. Dimensions must be requested to be used in - * this filter. Metrics cannot be used in this filter. - * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Metrics must be requested to be used in this filter. - * Dimensions cannot be used in this filter. - * @type string $currency_code - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * @type \Google\Analytics\Data\V1beta\CohortSpec $cohort_spec - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * @type bool $keep_empty_rows - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * @type bool $return_property_quota - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->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 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * The dimensions requested. All defined dimensions must be used by one of the - * following: dimension_expression, dimension_filter, pivots, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * The dimensions requested. All defined dimensions must be used by one of the - * following: dimension_expression, dimension_filter, pivots, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * The metrics requested, at least one metric needs to be specified. All - * defined metrics must be used by one of the following: metric_expression, - * metric_filter, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metrics requested, at least one metric needs to be specified. All - * defined metrics must be used by one of the following: metric_expression, - * metric_filter, order_bys. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); - $this->metrics = $arr; - - return $this; - } - - /** - * The date range to retrieve event data for the report. If multiple date - * ranges are specified, event data from each date range is used in the - * report. A special dimension with field name "dateRange" can be included in - * a Pivot's field names; if included, the report compares between date - * ranges. In a cohort request, this `dateRanges` must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDateRanges() - { - return $this->date_ranges; - } - - /** - * The date range to retrieve event data for the report. If multiple date - * ranges are specified, event data from each date range is used in the - * report. A special dimension with field name "dateRange" can be included in - * a Pivot's field names; if included, the report compares between date - * ranges. In a cohort request, this `dateRanges` must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - * @param array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDateRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DateRange::class); - $this->date_ranges = $arr; - - return $this; - } - - /** - * Describes the visual format of the report's dimensions in columns or rows. - * The union of the fieldNames (dimension names) in all pivots must be a - * subset of dimension names defined in Dimensions. No two pivots can share a - * dimension. A dimension is only visible if it appears in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPivots() - { - return $this->pivots; - } - - /** - * Describes the visual format of the report's dimensions in columns or rows. - * The union of the fieldNames (dimension names) in all pivots must be a - * subset of dimension names defined in Dimensions. No two pivots can share a - * dimension. A dimension is only visible if it appears in a pivot. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Pivot pivots = 5; - * @param array<\Google\Analytics\Data\V1beta\Pivot>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPivots($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Pivot::class); - $this->pivots = $arr; - - return $this; - } - - /** - * The filter clause of dimensions. Dimensions must be requested to be used in - * this filter. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getDimensionFilter() - { - return $this->dimension_filter; - } - - public function hasDimensionFilter() - { - return isset($this->dimension_filter); - } - - public function clearDimensionFilter() - { - unset($this->dimension_filter); - } - - /** - * The filter clause of dimensions. Dimensions must be requested to be used in - * this filter. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 6; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setDimensionFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->dimension_filter = $var; - - return $this; - } - - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Metrics must be requested to be used in this filter. - * Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getMetricFilter() - { - return $this->metric_filter; - } - - public function hasMetricFilter() - { - return isset($this->metric_filter); - } - - public function clearMetricFilter() - { - unset($this->metric_filter); - } - - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Metrics must be requested to be used in this filter. - * Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 7; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setMetricFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->metric_filter = $var; - - return $this; - } - - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 8; - * @return string - */ - public function getCurrencyCode() - { - return $this->currency_code; - } - - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 8; - * @param string $var - * @return $this - */ - public function setCurrencyCode($var) - { - GPBUtil::checkString($var, True); - $this->currency_code = $var; - - return $this; - } - - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; - * @return \Google\Analytics\Data\V1beta\CohortSpec|null - */ - public function getCohortSpec() - { - return $this->cohort_spec; - } - - public function hasCohortSpec() - { - return isset($this->cohort_spec); - } - - public function clearCohortSpec() - { - unset($this->cohort_spec); - } - - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 9; - * @param \Google\Analytics\Data\V1beta\CohortSpec $var - * @return $this - */ - public function setCohortSpec($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortSpec::class); - $this->cohort_spec = $var; - - return $this; - } - - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 10; - * @return bool - */ - public function getKeepEmptyRows() - { - return $this->keep_empty_rows; - } - - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 10; - * @param bool $var - * @return $this - */ - public function setKeepEmptyRows($var) - { - GPBUtil::checkBool($var); - $this->keep_empty_rows = $var; - - return $this; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 11; - * @return bool - */ - public function getReturnPropertyQuota() - { - return $this->return_property_quota; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 11; - * @param bool $var - * @return $this - */ - public function setReturnPropertyQuota($var) - { - GPBUtil::checkBool($var); - $this->return_property_quota = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php deleted file mode 100644 index 959e315a49f..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunPivotReportResponse.php +++ /dev/null @@ -1,481 +0,0 @@ -google.analytics.data.v1beta.RunPivotReportResponse - */ -class RunPivotReportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Summarizes the columns and rows created by a pivot. Each pivot in the - * request produces one header in the response. If we have a request like - * this: - * "pivots": [{ - * "fieldNames": ["country", - * "city"] - * }, - * { - * "fieldNames": "eventName" - * }] - * We will have the following `pivotHeaders` in the response: - * "pivotHeaders" : [{ - * "dimensionHeaders": [{ - * "dimensionValues": [ - * { "value": "United Kingdom" }, - * { "value": "London" } - * ] - * }, - * { - * "dimensionValues": [ - * { "value": "Japan" }, - * { "value": "Osaka" } - * ] - * }] - * }, - * { - * "dimensionHeaders": [{ - * "dimensionValues": [{ "value": "session_start" }] - * }, - * { - * "dimensionValues": [{ "value": "scroll" }] - * }] - * }] - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; - */ - private $pivot_headers; - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; - */ - private $dimension_headers; - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; - */ - private $metric_headers; - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; - */ - private $rows; - /** - * Aggregation of metric values. Can be totals, minimums, or maximums. The - * returned aggregations are controlled by the metric_aggregations in the - * pivot. The type of aggregation returned in each row is shown by the - * dimension_values which are set to "RESERVED_". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; - */ - private $aggregates; - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; - */ - protected $metadata = null; - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; - */ - protected $property_quota = null; - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runPivotReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 8; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\PivotHeader>|\Google\Protobuf\Internal\RepeatedField $pivot_headers - * Summarizes the columns and rows created by a pivot. Each pivot in the - * request produces one header in the response. If we have a request like - * this: - * "pivots": [{ - * "fieldNames": ["country", - * "city"] - * }, - * { - * "fieldNames": "eventName" - * }] - * We will have the following `pivotHeaders` in the response: - * "pivotHeaders" : [{ - * "dimensionHeaders": [{ - * "dimensionValues": [ - * { "value": "United Kingdom" }, - * { "value": "London" } - * ] - * }, - * { - * "dimensionValues": [ - * { "value": "Japan" }, - * { "value": "Osaka" } - * ] - * }] - * }, - * { - * "dimensionHeaders": [{ - * "dimensionValues": [{ "value": "session_start" }] - * }, - * { - * "dimensionValues": [{ "value": "scroll" }] - * }] - * }] - * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows - * Rows of dimension value combinations and metric values in the report. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $aggregates - * Aggregation of metric values. Can be totals, minimums, or maximums. The - * returned aggregations are controlled by the metric_aggregations in the - * pivot. The type of aggregation returned in each row is shown by the - * dimension_values which are set to "RESERVED_". - * @type \Google\Analytics\Data\V1beta\ResponseMetaData $metadata - * Metadata for the report. - * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota - * This Analytics Property's quota state including this request. - * @type string $kind - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runPivotReport". Useful to distinguish between - * response types in JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Summarizes the columns and rows created by a pivot. Each pivot in the - * request produces one header in the response. If we have a request like - * this: - * "pivots": [{ - * "fieldNames": ["country", - * "city"] - * }, - * { - * "fieldNames": "eventName" - * }] - * We will have the following `pivotHeaders` in the response: - * "pivotHeaders" : [{ - * "dimensionHeaders": [{ - * "dimensionValues": [ - * { "value": "United Kingdom" }, - * { "value": "London" } - * ] - * }, - * { - * "dimensionValues": [ - * { "value": "Japan" }, - * { "value": "Osaka" } - * ] - * }] - * }, - * { - * "dimensionHeaders": [{ - * "dimensionValues": [{ "value": "session_start" }] - * }, - * { - * "dimensionValues": [{ "value": "scroll" }] - * }] - * }] - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPivotHeaders() - { - return $this->pivot_headers; - } - - /** - * Summarizes the columns and rows created by a pivot. Each pivot in the - * request produces one header in the response. If we have a request like - * this: - * "pivots": [{ - * "fieldNames": ["country", - * "city"] - * }, - * { - * "fieldNames": "eventName" - * }] - * We will have the following `pivotHeaders` in the response: - * "pivotHeaders" : [{ - * "dimensionHeaders": [{ - * "dimensionValues": [ - * { "value": "United Kingdom" }, - * { "value": "London" } - * ] - * }, - * { - * "dimensionValues": [ - * { "value": "Japan" }, - * { "value": "Osaka" } - * ] - * }] - * }, - * { - * "dimensionHeaders": [{ - * "dimensionValues": [{ "value": "session_start" }] - * }, - * { - * "dimensionValues": [{ "value": "scroll" }] - * }] - * }] - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.PivotHeader pivot_headers = 1; - * @param array<\Google\Analytics\Data\V1beta\PivotHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPivotHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\PivotHeader::class); - $this->pivot_headers = $arr; - - return $this; - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionHeaders() - { - return $this->dimension_headers; - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 2; - * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); - $this->dimension_headers = $arr; - - return $this; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricHeaders() - { - return $this->metric_headers; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 3; - * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); - $this->metric_headers = $arr; - - return $this; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRows() - { - return $this->rows; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 4; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->rows = $arr; - - return $this; - } - - /** - * Aggregation of metric values. Can be totals, minimums, or maximums. The - * returned aggregations are controlled by the metric_aggregations in the - * pivot. The type of aggregation returned in each row is shown by the - * dimension_values which are set to "RESERVED_". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAggregates() - { - return $this->aggregates; - } - - /** - * Aggregation of metric values. Can be totals, minimums, or maximums. The - * returned aggregations are controlled by the metric_aggregations in the - * pivot. The type of aggregation returned in each row is shown by the - * dimension_values which are set to "RESERVED_". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row aggregates = 5; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAggregates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->aggregates = $arr; - - return $this; - } - - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; - * @return \Google\Analytics\Data\V1beta\ResponseMetaData|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 6; - * @param \Google\Analytics\Data\V1beta\ResponseMetaData $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData::class); - $this->metadata = $var; - - return $this; - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; - * @return \Google\Analytics\Data\V1beta\PropertyQuota|null - */ - public function getPropertyQuota() - { - return $this->property_quota; - } - - public function hasPropertyQuota() - { - return isset($this->property_quota); - } - - public function clearPropertyQuota() - { - unset($this->property_quota); - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 7; - * @param \Google\Analytics\Data\V1beta\PropertyQuota $var - * @return $this - */ - public function setPropertyQuota($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); - $this->property_quota = $var; - - return $this; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runPivotReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 8; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runPivotReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 8; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php deleted file mode 100644 index 9d96cefe0a9..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportRequest.php +++ /dev/null @@ -1,465 +0,0 @@ -google.analytics.data.v1beta.RunRealtimeReportRequest - */ -class RunRealtimeReportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * 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). - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - */ - private $dimensions; - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - */ - private $metrics; - /** - * The filter clause of dimensions. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - */ - protected $dimension_filter = null; - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - */ - protected $metric_filter = null; - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * - * Generated from protobuf field int64 limit = 6; - */ - protected $limit = 0; - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; - */ - private $metric_aggregations; - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; - */ - private $order_bys; - /** - * Toggles whether to return the current state of this Analytics Property's - * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 9; - */ - protected $return_property_quota = false; - /** - * The minute ranges of event data to read. If unspecified, one minute range - * for the last 30 minutes will be used. If multiple minute ranges are - * requested, each response row will contain a zero based minute range index. - * If two minute ranges overlap, the event data for the overlapping minutes is - * included in the response rows for both minute ranges. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; - */ - private $minute_ranges; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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). - * Example: properties/1234 - * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * The dimensions requested and displayed. - * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metrics requested and displayed. - * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter - * The filter clause of dimensions. Metrics cannot be used in this filter. - * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Dimensions cannot be used in this filter. - * @type int|string $limit - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys - * Specifies how rows are ordered in the response. - * @type bool $return_property_quota - * Toggles whether to return the current state of this Analytics Property's - * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * @type array<\Google\Analytics\Data\V1beta\MinuteRange>|\Google\Protobuf\Internal\RepeatedField $minute_ranges - * The minute ranges of event data to read. If unspecified, one minute range - * for the last 30 minutes will be used. If multiple minute ranges are - * requested, each response row will contain a zero based minute range index. - * If two minute ranges overlap, the event data for the overlapping minutes is - * included in the response rows for both minute ranges. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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). - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->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). - * Example: properties/1234 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); - $this->metrics = $arr; - - return $this; - } - - /** - * The filter clause of dimensions. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getDimensionFilter() - { - return $this->dimension_filter; - } - - public function hasDimensionFilter() - { - return isset($this->dimension_filter); - } - - public function clearDimensionFilter() - { - unset($this->dimension_filter); - } - - /** - * The filter clause of dimensions. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 4; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setDimensionFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->dimension_filter = $var; - - return $this; - } - - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getMetricFilter() - { - return $this->metric_filter; - } - - public function hasMetricFilter() - { - return isset($this->metric_filter); - } - - public function clearMetricFilter() - { - unset($this->metric_filter); - } - - /** - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 5; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setMetricFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->metric_filter = $var; - - return $this; - } - - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * - * Generated from protobuf field int64 limit = 6; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * - * Generated from protobuf field int64 limit = 6; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricAggregations() - { - return $this->metric_aggregations; - } - - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 7; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricAggregations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); - $this->metric_aggregations = $arr; - - return $this; - } - - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOrderBys() - { - return $this->order_bys; - } - - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 8; - * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOrderBys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); - $this->order_bys = $arr; - - return $this; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 9; - * @return bool - */ - public function getReturnPropertyQuota() - { - return $this->return_property_quota; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 9; - * @param bool $var - * @return $this - */ - public function setReturnPropertyQuota($var) - { - GPBUtil::checkBool($var); - $this->return_property_quota = $var; - - return $this; - } - - /** - * The minute ranges of event data to read. If unspecified, one minute range - * for the last 30 minutes will be used. If multiple minute ranges are - * requested, each response row will contain a zero based minute range index. - * If two minute ranges overlap, the event data for the overlapping minutes is - * included in the response rows for both minute ranges. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMinuteRanges() - { - return $this->minute_ranges; - } - - /** - * The minute ranges of event data to read. If unspecified, one minute range - * for the last 30 minutes will be used. If multiple minute ranges are - * requested, each response row will contain a zero based minute range index. - * If two minute ranges overlap, the event data for the overlapping minutes is - * included in the response rows for both minute ranges. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MinuteRange minute_ranges = 10; - * @param array<\Google\Analytics\Data\V1beta\MinuteRange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMinuteRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MinuteRange::class); - $this->minute_ranges = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php deleted file mode 100644 index 4ff50b9d77b..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunRealtimeReportResponse.php +++ /dev/null @@ -1,381 +0,0 @@ -google.analytics.data.v1beta.RunRealtimeReportResponse - */ -class RunRealtimeReportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - */ - private $dimension_headers; - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - */ - private $metric_headers; - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - */ - private $rows; - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - */ - private $totals; - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - */ - private $maximums; - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - */ - private $minimums; - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response and the `limit` request - * parameter. For example if a query returns 175 rows and includes `limit` - * of 50 in the API request, the response will contain `rowCount` of 175 but - * only 50 rows. - * - * Generated from protobuf field int32 row_count = 7; - */ - protected $row_count = 0; - /** - * This Analytics Property's Realtime quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; - */ - protected $property_quota = null; - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runRealtimeReport". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 9; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows - * Rows of dimension value combinations and metric values in the report. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $totals - * If requested, the totaled values of metrics. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $maximums - * If requested, the maximum values of metrics. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $minimums - * If requested, the minimum values of metrics. - * @type int $row_count - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response and the `limit` request - * parameter. For example if a query returns 175 rows and includes `limit` - * of 50 in the API request, the response will contain `rowCount` of 175 but - * only 50 rows. - * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota - * This Analytics Property's Realtime quota state including this request. - * @type string $kind - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runRealtimeReport". Useful to distinguish - * between response types in JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionHeaders() - { - return $this->dimension_headers; - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); - $this->dimension_headers = $arr; - - return $this; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricHeaders() - { - return $this->metric_headers; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); - $this->metric_headers = $arr; - - return $this; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRows() - { - return $this->rows; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->rows = $arr; - - return $this; - } - - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTotals() - { - return $this->totals; - } - - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTotals($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->totals = $arr; - - return $this; - } - - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaximums() - { - return $this->maximums; - } - - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaximums($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->maximums = $arr; - - return $this; - } - - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMinimums() - { - return $this->minimums; - } - - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMinimums($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->minimums = $arr; - - return $this; - } - - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response and the `limit` request - * parameter. For example if a query returns 175 rows and includes `limit` - * of 50 in the API request, the response will contain `rowCount` of 175 but - * only 50 rows. - * - * Generated from protobuf field int32 row_count = 7; - * @return int - */ - public function getRowCount() - { - return $this->row_count; - } - - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response and the `limit` request - * parameter. For example if a query returns 175 rows and includes `limit` - * of 50 in the API request, the response will contain `rowCount` of 175 but - * only 50 rows. - * - * Generated from protobuf field int32 row_count = 7; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - - /** - * This Analytics Property's Realtime quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; - * @return \Google\Analytics\Data\V1beta\PropertyQuota|null - */ - public function getPropertyQuota() - { - return $this->property_quota; - } - - public function hasPropertyQuota() - { - return isset($this->property_quota); - } - - public function clearPropertyQuota() - { - unset($this->property_quota); - } - - /** - * This Analytics Property's Realtime quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 8; - * @param \Google\Analytics\Data\V1beta\PropertyQuota $var - * @return $this - */ - public function setPropertyQuota($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); - $this->property_quota = $var; - - return $this; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runRealtimeReport". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 9; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runRealtimeReport". Useful to distinguish - * between response types in JSON. - * - * Generated from protobuf field string kind = 9; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php deleted file mode 100644 index 6f0d9ba7a92..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportRequest.php +++ /dev/null @@ -1,699 +0,0 @@ -google.analytics.data.v1beta.RunReportRequest - */ -class RunReportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * 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 - * - * Generated from protobuf field string property = 1; - */ - protected $property = ''; - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - */ - private $dimensions; - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - */ - private $metrics; - /** - * 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. In a cohort request, this `dateRanges` - * must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - */ - private $date_ranges; - /** - * Dimension filters let you ask for only specific dimension values in - * the report. To learn more, see [Fundamentals of Dimension - * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) - * for examples. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; - */ - protected $dimension_filter = null; - /** - * The filter clause of metrics. Applied after aggregating the report's rows, - * similar to SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; - */ - protected $metric_filter = null; - /** - * The row count of the start row. The first row is counted as row 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 7; - */ - protected $offset = 0; - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 8; - */ - protected $limit = 0; - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; - */ - private $metric_aggregations; - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; - */ - private $order_bys; - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 11; - */ - protected $currency_code = ''; - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; - */ - protected $cohort_spec = null; - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 13; - */ - protected $keep_empty_rows = false; - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 14; - */ - protected $return_property_quota = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $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 - * @type array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $dimensions - * The dimensions requested and displayed. - * @type array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $metrics - * The metrics requested and displayed. - * @type array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $date_ranges - * 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. In a cohort request, this `dateRanges` - * must be unspecified. - * @type \Google\Analytics\Data\V1beta\FilterExpression $dimension_filter - * Dimension filters let you ask for only specific dimension values in - * the report. To learn more, see [Fundamentals of Dimension - * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) - * for examples. Metrics cannot be used in this filter. - * @type \Google\Analytics\Data\V1beta\FilterExpression $metric_filter - * The filter clause of metrics. Applied after aggregating the report's rows, - * similar to SQL having-clause. Dimensions cannot be used in this filter. - * @type int|string $offset - * The row count of the start row. The first row is counted as row 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int|string $limit - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type array|\Google\Protobuf\Internal\RepeatedField $metric_aggregations - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * @type array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $order_bys - * Specifies how rows are ordered in the response. - * @type string $currency_code - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * @type \Google\Analytics\Data\V1beta\CohortSpec $cohort_spec - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * @type bool $keep_empty_rows - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * @type bool $return_property_quota - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * 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 - * - * Generated from protobuf field string property = 1; - * @return string - */ - public function getProperty() - { - return $this->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 - * - * Generated from protobuf field string property = 1; - * @param string $var - * @return $this - */ - public function setProperty($var) - { - GPBUtil::checkString($var, True); - $this->property = $var; - - return $this; - } - - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * The dimensions requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Dimension dimensions = 2; - * @param array<\Google\Analytics\Data\V1beta\Dimension>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Dimension::class); - $this->dimensions = $arr; - - return $this; - } - - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetrics() - { - return $this->metrics; - } - - /** - * The metrics requested and displayed. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Metric metrics = 3; - * @param array<\Google\Analytics\Data\V1beta\Metric>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetrics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Metric::class); - $this->metrics = $arr; - - 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. In a cohort request, this `dateRanges` - * must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDateRanges() - { - return $this->date_ranges; - } - - /** - * 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. In a cohort request, this `dateRanges` - * must be unspecified. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DateRange date_ranges = 4; - * @param array<\Google\Analytics\Data\V1beta\DateRange>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDateRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DateRange::class); - $this->date_ranges = $arr; - - return $this; - } - - /** - * Dimension filters let you ask for only specific dimension values in - * the report. To learn more, see [Fundamentals of Dimension - * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) - * for examples. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getDimensionFilter() - { - return $this->dimension_filter; - } - - public function hasDimensionFilter() - { - return isset($this->dimension_filter); - } - - public function clearDimensionFilter() - { - unset($this->dimension_filter); - } - - /** - * Dimension filters let you ask for only specific dimension values in - * the report. To learn more, see [Fundamentals of Dimension - * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) - * for examples. Metrics cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression dimension_filter = 5; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setDimensionFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->dimension_filter = $var; - - return $this; - } - - /** - * The filter clause of metrics. Applied after aggregating the report's rows, - * similar to SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; - * @return \Google\Analytics\Data\V1beta\FilterExpression|null - */ - public function getMetricFilter() - { - return $this->metric_filter; - } - - public function hasMetricFilter() - { - return isset($this->metric_filter); - } - - public function clearMetricFilter() - { - unset($this->metric_filter); - } - - /** - * The filter clause of metrics. Applied after aggregating the report's rows, - * similar to SQL having-clause. Dimensions cannot be used in this filter. - * - * Generated from protobuf field .google.analytics.data.v1beta.FilterExpression metric_filter = 6; - * @param \Google\Analytics\Data\V1beta\FilterExpression $var - * @return $this - */ - public function setMetricFilter($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\FilterExpression::class); - $this->metric_filter = $var; - - return $this; - } - - /** - * The row count of the start row. The first row is counted as row 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 7; - * @return int|string - */ - public function getOffset() - { - return $this->offset; - } - - /** - * The row count of the start row. The first row is counted as row 0. - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 offset = 7; - * @param int|string $var - * @return $this - */ - public function setOffset($var) - { - GPBUtil::checkInt64($var); - $this->offset = $var; - - return $this; - } - - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 8; - * @return int|string - */ - public function getLimit() - { - return $this->limit; - } - - /** - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int64 limit = 8; - * @param int|string $var - * @return $this - */ - public function setLimit($var) - { - GPBUtil::checkInt64($var); - $this->limit = $var; - - return $this; - } - - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricAggregations() - { - return $this->metric_aggregations; - } - - /** - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricAggregation metric_aggregations = 9; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricAggregations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Analytics\Data\V1beta\MetricAggregation::class); - $this->metric_aggregations = $arr; - - return $this; - } - - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOrderBys() - { - return $this->order_bys; - } - - /** - * Specifies how rows are ordered in the response. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.OrderBy order_bys = 10; - * @param array<\Google\Analytics\Data\V1beta\OrderBy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOrderBys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\OrderBy::class); - $this->order_bys = $arr; - - return $this; - } - - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 11; - * @return string - */ - public function getCurrencyCode() - { - return $this->currency_code; - } - - /** - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * - * Generated from protobuf field string currency_code = 11; - * @param string $var - * @return $this - */ - public function setCurrencyCode($var) - { - GPBUtil::checkString($var, True); - $this->currency_code = $var; - - return $this; - } - - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; - * @return \Google\Analytics\Data\V1beta\CohortSpec|null - */ - public function getCohortSpec() - { - return $this->cohort_spec; - } - - public function hasCohortSpec() - { - return isset($this->cohort_spec); - } - - public function clearCohortSpec() - { - unset($this->cohort_spec); - } - - /** - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * - * Generated from protobuf field .google.analytics.data.v1beta.CohortSpec cohort_spec = 12; - * @param \Google\Analytics\Data\V1beta\CohortSpec $var - * @return $this - */ - public function setCohortSpec($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\CohortSpec::class); - $this->cohort_spec = $var; - - return $this; - } - - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 13; - * @return bool - */ - public function getKeepEmptyRows() - { - return $this->keep_empty_rows; - } - - /** - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * - * Generated from protobuf field bool keep_empty_rows = 13; - * @param bool $var - * @return $this - */ - public function setKeepEmptyRows($var) - { - GPBUtil::checkBool($var); - $this->keep_empty_rows = $var; - - return $this; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 14; - * @return bool - */ - public function getReturnPropertyQuota() - { - return $this->return_property_quota; - } - - /** - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * - * Generated from protobuf field bool return_property_quota = 14; - * @param bool $var - * @return $this - */ - public function setReturnPropertyQuota($var) - { - GPBUtil::checkBool($var); - $this->return_property_quota = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php deleted file mode 100644 index 6825d24eb51..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/RunReportResponse.php +++ /dev/null @@ -1,433 +0,0 @@ -google.analytics.data.v1beta.RunReportResponse - */ -class RunReportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - */ - private $dimension_headers; - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - */ - private $metric_headers; - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - */ - private $rows; - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - */ - private $totals; - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - */ - private $maximums; - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - */ - private $minimums; - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response, the `limit` request - * parameter, and the `offset` request parameter. For example if a query - * returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int32 row_count = 7; - */ - protected $row_count = 0; - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; - */ - protected $metadata = null; - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; - */ - protected $property_quota = null; - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 10; - */ - protected $kind = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $dimension_headers - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * @type array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $metric_headers - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $rows - * Rows of dimension value combinations and metric values in the report. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $totals - * If requested, the totaled values of metrics. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $maximums - * If requested, the maximum values of metrics. - * @type array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $minimums - * If requested, the minimum values of metrics. - * @type int $row_count - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response, the `limit` request - * parameter, and the `offset` request parameter. For example if a query - * returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type \Google\Analytics\Data\V1beta\ResponseMetaData $metadata - * Metadata for the report. - * @type \Google\Analytics\Data\V1beta\PropertyQuota $property_quota - * This Analytics Property's quota state including this request. - * @type string $kind - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runReport". Useful to distinguish between - * response types in JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\AnalyticsDataApi::initOnce(); - parent::__construct($data); - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDimensionHeaders() - { - return $this->dimension_headers; - } - - /** - * Describes dimension columns. The number of DimensionHeaders and ordering of - * DimensionHeaders matches the dimensions present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.DimensionHeader dimension_headers = 1; - * @param array<\Google\Analytics\Data\V1beta\DimensionHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDimensionHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\DimensionHeader::class); - $this->dimension_headers = $arr; - - return $this; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMetricHeaders() - { - return $this->metric_headers; - } - - /** - * Describes metric columns. The number of MetricHeaders and ordering of - * MetricHeaders matches the metrics present in rows. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.MetricHeader metric_headers = 2; - * @param array<\Google\Analytics\Data\V1beta\MetricHeader>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMetricHeaders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\MetricHeader::class); - $this->metric_headers = $arr; - - return $this; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRows() - { - return $this->rows; - } - - /** - * Rows of dimension value combinations and metric values in the report. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row rows = 3; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRows($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->rows = $arr; - - return $this; - } - - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTotals() - { - return $this->totals; - } - - /** - * If requested, the totaled values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row totals = 4; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTotals($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->totals = $arr; - - return $this; - } - - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMaximums() - { - return $this->maximums; - } - - /** - * If requested, the maximum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row maximums = 5; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMaximums($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->maximums = $arr; - - return $this; - } - - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMinimums() - { - return $this->minimums; - } - - /** - * If requested, the minimum values of metrics. - * - * Generated from protobuf field repeated .google.analytics.data.v1beta.Row minimums = 6; - * @param array<\Google\Analytics\Data\V1beta\Row>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMinimums($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Analytics\Data\V1beta\Row::class); - $this->minimums = $arr; - - return $this; - } - - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response, the `limit` request - * parameter, and the `offset` request parameter. For example if a query - * returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int32 row_count = 7; - * @return int - */ - public function getRowCount() - { - return $this->row_count; - } - - /** - * The total number of rows in the query result. `rowCount` is independent of - * the number of rows returned in the response, the `limit` request - * parameter, and the `offset` request parameter. For example if a query - * returns 175 rows and includes `limit` of 50 in the API request, the - * response will contain `rowCount` of 175 but only 50 rows. - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * - * Generated from protobuf field int32 row_count = 7; - * @param int $var - * @return $this - */ - public function setRowCount($var) - { - GPBUtil::checkInt32($var); - $this->row_count = $var; - - return $this; - } - - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; - * @return \Google\Analytics\Data\V1beta\ResponseMetaData|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata for the report. - * - * Generated from protobuf field .google.analytics.data.v1beta.ResponseMetaData metadata = 8; - * @param \Google\Analytics\Data\V1beta\ResponseMetaData $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\ResponseMetaData::class); - $this->metadata = $var; - - return $this; - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; - * @return \Google\Analytics\Data\V1beta\PropertyQuota|null - */ - public function getPropertyQuota() - { - return $this->property_quota; - } - - public function hasPropertyQuota() - { - return isset($this->property_quota); - } - - public function clearPropertyQuota() - { - unset($this->property_quota); - } - - /** - * This Analytics Property's quota state including this request. - * - * Generated from protobuf field .google.analytics.data.v1beta.PropertyQuota property_quota = 9; - * @param \Google\Analytics\Data\V1beta\PropertyQuota $var - * @return $this - */ - public function setPropertyQuota($var) - { - GPBUtil::checkMessage($var, \Google\Analytics\Data\V1beta\PropertyQuota::class); - $this->property_quota = $var; - - return $this; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 10; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Identifies what kind of resource this message is. This `kind` is always the - * fixed string "analyticsData#runReport". Useful to distinguish between - * response types in JSON. - * - * Generated from protobuf field string kind = 10; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php b/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php deleted file mode 100644 index c85383ee02e..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/proto/src/Google/Analytics/Data/V1beta/SamplingMetadata.php +++ /dev/null @@ -1,133 +0,0 @@ -google.analytics.data.v1beta.SamplingMetadata - */ -class SamplingMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * 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 report. - * - * Generated from protobuf field int64 samples_read_count = 1; - */ - protected $samples_read_count = 0; - /** - * The total number of events present in this property's data that could - * have been analyzed in this 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 - * report, compute `samplesReadCount/samplingSpaceSize`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - */ - protected $sampling_space_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $samples_read_count - * 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 report. - * @type int|string $sampling_space_size - * The total number of events present in this property's data that could - * have been analyzed in this 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 - * report, compute `samplesReadCount/samplingSpaceSize`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Analytics\Data\V1Beta\Data::initOnce(); - parent::__construct($data); - } - - /** - * 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 report. - * - * Generated from protobuf field int64 samples_read_count = 1; - * @return int|string - */ - public function getSamplesReadCount() - { - return $this->samples_read_count; - } - - /** - * 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 report. - * - * Generated from protobuf field int64 samples_read_count = 1; - * @param int|string $var - * @return $this - */ - public function setSamplesReadCount($var) - { - GPBUtil::checkInt64($var); - $this->samples_read_count = $var; - - return $this; - } - - /** - * The total number of events present in this property's data that could - * have been analyzed in this 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 - * report, compute `samplesReadCount/samplingSpaceSize`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - * @return int|string - */ - public function getSamplingSpaceSize() - { - return $this->sampling_space_size; - } - - /** - * The total number of events present in this property's data that could - * have been analyzed in this 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 - * report, compute `samplesReadCount/samplingSpaceSize`. - * - * Generated from protobuf field int64 sampling_space_size = 2; - * @param int|string $var - * @return $this - */ - public function setSamplingSpaceSize($var) - { - GPBUtil::checkInt64($var); - $this->sampling_space_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php deleted file mode 100644 index 7c893afaa92..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php +++ /dev/null @@ -1,58 +0,0 @@ -batchRunPivotReports($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_BatchRunPivotReports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php deleted file mode 100644 index bf9615abcee..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php +++ /dev/null @@ -1,58 +0,0 @@ -batchRunReports($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_BatchRunReports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php deleted file mode 100644 index ae432f155d1..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php +++ /dev/null @@ -1,66 +0,0 @@ -checkCompatibility($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_CheckCompatibility_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php deleted file mode 100644 index 820fcfed54a..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php +++ /dev/null @@ -1,122 +0,0 @@ -setAudience($audienceExportAudience) - ->setDimensions($audienceExportDimensions); - $request = (new CreateAudienceExportRequest()) - ->setParent($formattedParent) - ->setAudienceExport($audienceExport); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $betaAnalyticsDataClient->createAudienceExport($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var AudienceExport $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = BetaAnalyticsDataClient::propertyName('[PROPERTY]'); - $audienceExportAudience = '[AUDIENCE]'; - - create_audience_export_sample($formattedParent, $audienceExportAudience); -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_CreateAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php deleted file mode 100644 index 24bff6ab36c..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var AudienceExport $response */ - $response = $betaAnalyticsDataClient->getAudienceExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = BetaAnalyticsDataClient::audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - - get_audience_export_sample($formattedName); -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_GetAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php deleted file mode 100644 index b5680a0483d..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/get_metadata.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Metadata $response */ - $response = $betaAnalyticsDataClient->getMetadata($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = BetaAnalyticsDataClient::metadataName('[PROPERTY]'); - - get_metadata_sample($formattedName); -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_GetMetadata_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php deleted file mode 100644 index 53031ca6a20..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php +++ /dev/null @@ -1,91 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $betaAnalyticsDataClient->listAudienceExports($request); - - /** @var AudienceExport $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = BetaAnalyticsDataClient::propertyName('[PROPERTY]'); - - list_audience_exports_sample($formattedParent); -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_ListAudienceExports_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php deleted file mode 100644 index 013f2bbb524..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php +++ /dev/null @@ -1,89 +0,0 @@ -setName($name); - - // Call the API and handle any network failures. - try { - /** @var QueryAudienceExportResponse $response */ - $response = $betaAnalyticsDataClient->queryAudienceExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $name = '[NAME]'; - - query_audience_export_sample($name); -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_QueryAudienceExport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php deleted file mode 100644 index 796aef3d116..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php +++ /dev/null @@ -1,61 +0,0 @@ -runPivotReport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunPivotReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php deleted file mode 100644 index 4c1d9e225cd..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php +++ /dev/null @@ -1,65 +0,0 @@ -runRealtimeReport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunRealtimeReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php b/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php deleted file mode 100644 index b4c1d2fea06..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/samples/V1beta/BetaAnalyticsDataClient/run_report.php +++ /dev/null @@ -1,67 +0,0 @@ -runReport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END analyticsdata_v1beta_generated_BetaAnalyticsData_RunReport_sync] diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php deleted file mode 100644 index 5d708159cb0..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/BetaAnalyticsDataClient.php +++ /dev/null @@ -1,36 +0,0 @@ - self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/beta_analytics_data_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/beta_analytics_data_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/beta_analytics_data_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/beta_analytics_data_rest_client_config.php', - ], - ], - ]; - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - * - * @experimental - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - * - * @experimental - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * audience_export resource. - * - * @param string $property - * @param string $audienceExport - * - * @return string The formatted audience_export resource. - * - * @experimental - */ - public static function audienceExportName(string $property, string $audienceExport): string - { - return self::getPathTemplate('audienceExport')->render([ - 'property' => $property, - 'audience_export' => $audienceExport, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a metadata - * resource. - * - * @param string $property - * - * @return string The formatted metadata resource. - * - * @experimental - */ - public static function metadataName(string $property): string - { - return self::getPathTemplate('metadata')->render([ - 'property' => $property, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a property - * resource. - * - * @param string $property - * - * @return string The formatted property resource. - * - * @experimental - */ - public static function propertyName(string $property): string - { - return self::getPathTemplate('property')->render([ - 'property' => $property, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - audienceExport: properties/{property}/audienceExports/{audience_export} - * - metadata: properties/{property}/metadata - * - property: properties/{property} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName(string $formattedName, string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticsdata.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Returns multiple pivot reports in a batch. All reports must be for the same - * GA4 Property. - * - * The async variant is {@see BetaAnalyticsDataClient::batchRunPivotReportsAsync()} - * . - * - * @example samples/V1beta/BetaAnalyticsDataClient/batch_run_pivot_reports.php - * - * @param BatchRunPivotReportsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BatchRunPivotReportsResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function batchRunPivotReports(BatchRunPivotReportsRequest $request, array $callOptions = []): BatchRunPivotReportsResponse - { - return $this->startApiCall('BatchRunPivotReports', $request, $callOptions)->wait(); - } - - /** - * Returns multiple reports in a batch. All reports must be for the same - * GA4 Property. - * - * The async variant is {@see BetaAnalyticsDataClient::batchRunReportsAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/batch_run_reports.php - * - * @param BatchRunReportsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BatchRunReportsResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function batchRunReports(BatchRunReportsRequest $request, array $callOptions = []): BatchRunReportsResponse - { - return $this->startApiCall('BatchRunReports', $request, $callOptions)->wait(); - } - - /** - * This compatibility method lists dimensions and metrics that can be added to - * a report request and maintain compatibility. This method fails if the - * request's dimensions and metrics are incompatible. - * - * In Google Analytics, reports fail if they request incompatible dimensions - * and/or metrics; in that case, you will need to remove dimensions and/or - * metrics from the incompatible report until the report is compatible. - * - * The Realtime and Core reports have different compatibility rules. This - * method checks compatibility for Core reports. - * - * The async variant is {@see BetaAnalyticsDataClient::checkCompatibilityAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/check_compatibility.php - * - * @param CheckCompatibilityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return CheckCompatibilityResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function checkCompatibility(CheckCompatibilityRequest $request, array $callOptions = []): CheckCompatibilityResponse - { - return $this->startApiCall('CheckCompatibility', $request, $callOptions)->wait(); - } - - /** - * Creates an audience export for later retrieval. This method quickly returns - * the audience export's resource name and initiates a long running - * asynchronous request to form an audience export. To export the users in an - * audience export, first create the audience export through this method and - * then send the audience resource name to the `QueryAudienceExport` method. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * An audience export is a snapshot of the users currently in the audience at - * the time of audience export creation. Creating audience exports for one - * audience on different days will return different results as users enter and - * exit the audience. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. Audience exports - * contain the users in each audience. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see BetaAnalyticsDataClient::createAudienceExportAsync()} - * . - * - * @example samples/V1beta/BetaAnalyticsDataClient/create_audience_export.php - * - * @param CreateAudienceExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function createAudienceExport(CreateAudienceExportRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateAudienceExport', $request, $callOptions)->wait(); - } - - /** - * Gets configuration metadata about a specific audience export. This method - * can be used to understand an audience export after it has been created. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see BetaAnalyticsDataClient::getAudienceExportAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/get_audience_export.php - * - * @param GetAudienceExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return AudienceExport - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function getAudienceExport(GetAudienceExportRequest $request, array $callOptions = []): AudienceExport - { - return $this->startApiCall('GetAudienceExport', $request, $callOptions)->wait(); - } - - /** - * Returns metadata for dimensions and metrics available in reporting methods. - * Used to explore the dimensions and metrics. In this method, a Google - * Analytics GA4 Property Identifier is specified in the request, and - * the metadata response includes Custom dimensions and metrics as well as - * Universal metadata. - * - * For example if a custom metric with parameter name `levels_unlocked` is - * registered to a property, the Metadata response will contain - * `customEvent:levels_unlocked`. Universal metadata are dimensions and - * metrics applicable to any property such as `country` and `totalUsers`. - * - * The async variant is {@see BetaAnalyticsDataClient::getMetadataAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/get_metadata.php - * - * @param GetMetadataRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Metadata - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function getMetadata(GetMetadataRequest $request, array $callOptions = []): Metadata - { - return $this->startApiCall('GetMetadata', $request, $callOptions)->wait(); - } - - /** - * Lists all audience exports for a property. This method can be used for you - * to find and reuse existing audience exports rather than creating - * unnecessary new audience exports. The same audience can have multiple - * audience exports that represent the export of users that were in an - * audience on different days. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see BetaAnalyticsDataClient::listAudienceExportsAsync()} - * . - * - * @example samples/V1beta/BetaAnalyticsDataClient/list_audience_exports.php - * - * @param ListAudienceExportsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function listAudienceExports(ListAudienceExportsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListAudienceExports', $request, $callOptions); - } - - /** - * Retrieves an audience export of users. After creating an audience, the - * users are not immediately available for exporting. First, a request to - * `CreateAudienceExport` is necessary to create an audience export of users, - * and then second, this method is used to retrieve the users in the audience - * export. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * The async variant is {@see BetaAnalyticsDataClient::queryAudienceExportAsync()} - * . - * - * @example samples/V1beta/BetaAnalyticsDataClient/query_audience_export.php - * - * @param QueryAudienceExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return QueryAudienceExportResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function queryAudienceExport(QueryAudienceExportRequest $request, array $callOptions = []): QueryAudienceExportResponse - { - return $this->startApiCall('QueryAudienceExport', $request, $callOptions)->wait(); - } - - /** - * Returns a customized pivot report of your Google Analytics event data. - * Pivot reports are more advanced and expressive formats than regular - * reports. In a pivot report, dimensions are only visible if they are - * included in a pivot. Multiple pivots can be specified to further dissect - * your data. - * - * The async variant is {@see BetaAnalyticsDataClient::runPivotReportAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/run_pivot_report.php - * - * @param RunPivotReportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RunPivotReportResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function runPivotReport(RunPivotReportRequest $request, array $callOptions = []): RunPivotReportResponse - { - return $this->startApiCall('RunPivotReport', $request, $callOptions)->wait(); - } - - /** - * Returns a customized report of realtime event data for your property. - * Events appear in realtime reports seconds after they have been sent to - * the Google Analytics. Realtime reports show events and usage data for the - * periods of time ranging from the present moment to 30 minutes ago (up to - * 60 minutes for Google Analytics 360 properties). - * - * For a guide to constructing realtime requests & understanding responses, - * see [Creating a Realtime - * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-basics). - * - * The async variant is {@see BetaAnalyticsDataClient::runRealtimeReportAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/run_realtime_report.php - * - * @param RunRealtimeReportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RunRealtimeReportResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function runRealtimeReport(RunRealtimeReportRequest $request, array $callOptions = []): RunRealtimeReportResponse - { - return $this->startApiCall('RunRealtimeReport', $request, $callOptions)->wait(); - } - - /** - * Returns a customized report of your Google Analytics event data. Reports - * contain statistics derived from data collected by the Google Analytics - * tracking code. The data returned from the API is as a table with columns - * for the requested dimensions and metrics. Metrics are individual - * measurements of user activity on your property, such as active users or - * event count. Dimensions break down metrics across some common criteria, - * such as country or event name. - * - * For a guide to constructing requests & understanding responses, see - * [Creating a - * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/basics). - * - * The async variant is {@see BetaAnalyticsDataClient::runReportAsync()} . - * - * @example samples/V1beta/BetaAnalyticsDataClient/run_report.php - * - * @param RunReportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return RunReportResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @experimental - */ - public function runReport(RunReportRequest $request, array $callOptions = []): RunReportResponse - { - return $this->startApiCall('RunReport', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php deleted file mode 100644 index 9549cc52397..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/Gapic/BetaAnalyticsDataGapicClient.php +++ /dev/null @@ -1,1431 +0,0 @@ -batchRunPivotReports(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * 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 parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @experimental - * - * @deprecated Please use the new service client {@see \Google\Analytics\Data\V1beta\Client\BetaAnalyticsDataClient}. - */ -class BetaAnalyticsDataGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.analytics.data.v1beta.BetaAnalyticsData'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'analyticsdata.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'analyticsdata.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/analytics', - 'https://www.googleapis.com/auth/analytics.readonly', - ]; - - private static $audienceExportNameTemplate; - - private static $metadataNameTemplate; - - private static $propertyNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/beta_analytics_data_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/beta_analytics_data_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/beta_analytics_data_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/beta_analytics_data_rest_client_config.php', - ], - ], - ]; - } - - private static function getAudienceExportNameTemplate() - { - if (self::$audienceExportNameTemplate == null) { - self::$audienceExportNameTemplate = new PathTemplate('properties/{property}/audienceExports/{audience_export}'); - } - - return self::$audienceExportNameTemplate; - } - - private static function getMetadataNameTemplate() - { - if (self::$metadataNameTemplate == null) { - self::$metadataNameTemplate = new PathTemplate('properties/{property}/metadata'); - } - - return self::$metadataNameTemplate; - } - - private static function getPropertyNameTemplate() - { - if (self::$propertyNameTemplate == null) { - self::$propertyNameTemplate = new PathTemplate('properties/{property}'); - } - - return self::$propertyNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'audienceExport' => self::getAudienceExportNameTemplate(), - 'metadata' => self::getMetadataNameTemplate(), - 'property' => self::getPropertyNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * audience_export resource. - * - * @param string $property - * @param string $audienceExport - * - * @return string The formatted audience_export resource. - * - * @experimental - */ - public static function audienceExportName($property, $audienceExport) - { - return self::getAudienceExportNameTemplate()->render([ - 'property' => $property, - 'audience_export' => $audienceExport, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a metadata - * resource. - * - * @param string $property - * - * @return string The formatted metadata resource. - * - * @experimental - */ - public static function metadataName($property) - { - return self::getMetadataNameTemplate()->render([ - 'property' => $property, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a property - * resource. - * - * @param string $property - * - * @return string The formatted property resource. - * - * @experimental - */ - public static function propertyName($property) - { - return self::getPropertyNameTemplate()->render([ - 'property' => $property, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - audienceExport: properties/{property}/audienceExports/{audience_export} - * - metadata: properties/{property}/metadata - * - property: properties/{property} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - * - * @experimental - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - * - * @experimental - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'analyticsdata.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Returns multiple pivot reports in a batch. All reports must be for the same - * GA4 Property. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->batchRunPivotReports(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $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). - * This property must be specified for the batch. The property within - * RunPivotReportRequest may either be unspecified or consistent with this - * property. - * - * Example: properties/1234 - * @type RunPivotReportRequest[] $requests - * Individual requests. Each request has a separate pivot report response. - * Each batch request is allowed up to 5 requests. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\BatchRunPivotReportsResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function batchRunPivotReports(array $optionalArgs = []) - { - $request = new BatchRunPivotReportsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['requests'])) { - $request->setRequests($optionalArgs['requests']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('BatchRunPivotReports', BatchRunPivotReportsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns multiple reports in a batch. All reports must be for the same - * GA4 Property. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->batchRunReports(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $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). - * This property must be specified for the batch. The property within - * RunReportRequest may either be unspecified or consistent with this - * property. - * - * Example: properties/1234 - * @type RunReportRequest[] $requests - * Individual requests. Each request has a separate report response. Each - * batch request is allowed up to 5 requests. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\BatchRunReportsResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function batchRunReports(array $optionalArgs = []) - { - $request = new BatchRunReportsRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['requests'])) { - $request->setRequests($optionalArgs['requests']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('BatchRunReports', BatchRunReportsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * This compatibility method lists dimensions and metrics that can be added to - * a report request and maintain compatibility. This method fails if the - * request's dimensions and metrics are incompatible. - * - * In Google Analytics, reports fail if they request incompatible dimensions - * and/or metrics; in that case, you will need to remove dimensions and/or - * metrics from the incompatible report until the report is compatible. - * - * The Realtime and Core reports have different compatibility rules. This - * method checks compatibility for Core reports. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->checkCompatibility(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $property - * A Google Analytics GA4 property identifier whose events are tracked. To - * learn more, see [where to find your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * `property` should be the same value as in your `runReport` request. - * - * Example: properties/1234 - * @type Dimension[] $dimensions - * The dimensions in this report. `dimensions` should be the same value as in - * your `runReport` request. - * @type Metric[] $metrics - * The metrics in this report. `metrics` should be the same value as in your - * `runReport` request. - * @type FilterExpression $dimensionFilter - * The filter clause of dimensions. `dimensionFilter` should be the same value - * as in your `runReport` request. - * @type FilterExpression $metricFilter - * The filter clause of metrics. `metricFilter` should be the same value as in - * your `runReport` request - * @type int $compatibilityFilter - * Filters the dimensions and metrics in the response to just this - * compatibility. Commonly used as `”compatibilityFilter”: “COMPATIBLE”` - * to only return compatible dimensions & metrics. - * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\Compatibility} - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\CheckCompatibilityResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function checkCompatibility(array $optionalArgs = []) - { - $request = new CheckCompatibilityRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['dimensions'])) { - $request->setDimensions($optionalArgs['dimensions']); - } - - if (isset($optionalArgs['metrics'])) { - $request->setMetrics($optionalArgs['metrics']); - } - - if (isset($optionalArgs['dimensionFilter'])) { - $request->setDimensionFilter($optionalArgs['dimensionFilter']); - } - - if (isset($optionalArgs['metricFilter'])) { - $request->setMetricFilter($optionalArgs['metricFilter']); - } - - if (isset($optionalArgs['compatibilityFilter'])) { - $request->setCompatibilityFilter($optionalArgs['compatibilityFilter']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CheckCompatibility', CheckCompatibilityResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates an audience export for later retrieval. This method quickly returns - * the audience export's resource name and initiates a long running - * asynchronous request to form an audience export. To export the users in an - * audience export, first create the audience export through this method and - * then send the audience resource name to the `QueryAudienceExport` method. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * An audience export is a snapshot of the users currently in the audience at - * the time of audience export creation. Creating audience exports for one - * audience on different days will return different results as users enter and - * exit the audience. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. Audience exports - * contain the users in each audience. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $formattedParent = $betaAnalyticsDataClient->propertyName('[PROPERTY]'); - * $audienceExport = new AudienceExport(); - * $operationResponse = $betaAnalyticsDataClient->createAudienceExport($formattedParent, $audienceExport); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $betaAnalyticsDataClient->createAudienceExport($formattedParent, $audienceExport); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $betaAnalyticsDataClient->resumeOperation($operationName, 'createAudienceExport'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent resource where this audience export will be created. - * Format: `properties/{property}` - * @param AudienceExport $audienceExport Required. The audience export to create. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createAudienceExport($parent, $audienceExport, array $optionalArgs = []) - { - $request = new CreateAudienceExportRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setAudienceExport($audienceExport); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('CreateAudienceExport', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Gets configuration metadata about a specific audience export. This method - * can be used to understand an audience export after it has been created. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $formattedName = $betaAnalyticsDataClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - * $response = $betaAnalyticsDataClient->getAudienceExport($formattedName); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The audience export resource name. - * Format: `properties/{property}/audienceExports/{audience_export}` - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\AudienceExport - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getAudienceExport($name, array $optionalArgs = []) - { - $request = new GetAudienceExportRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetAudienceExport', AudienceExport::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns metadata for dimensions and metrics available in reporting methods. - * Used to explore the dimensions and metrics. In this method, a Google - * Analytics GA4 Property Identifier is specified in the request, and - * the metadata response includes Custom dimensions and metrics as well as - * Universal metadata. - * - * For example if a custom metric with parameter name `levels_unlocked` is - * registered to a property, the Metadata response will contain - * `customEvent:levels_unlocked`. Universal metadata are dimensions and - * metrics applicable to any property such as `country` and `totalUsers`. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $formattedName = $betaAnalyticsDataClient->metadataName('[PROPERTY]'); - * $response = $betaAnalyticsDataClient->getMetadata($formattedName); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The resource name of the metadata to retrieve. This name field is - * specified in the URL path and not URL parameters. Property is a numeric - * Google Analytics GA4 Property identifier. To learn more, see [where to find - * your Property - * ID](https://developers.google.com/analytics/devguides/reporting/data/v1/property-id). - * - * Example: properties/1234/metadata - * - * 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. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\Metadata - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getMetadata($name, array $optionalArgs = []) - { - $request = new GetMetadataRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetMetadata', Metadata::class, $optionalArgs, $request)->wait(); - } - - /** - * Lists all audience exports for a property. This method can be used for you - * to find and reuse existing audience exports rather than creating - * unnecessary new audience exports. The same audience can have multiple - * audience exports that represent the export of users that were in an - * audience on different days. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $formattedParent = $betaAnalyticsDataClient->propertyName('[PROPERTY]'); - * // Iterate over pages of elements - * $pagedResponse = $betaAnalyticsDataClient->listAudienceExports($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $betaAnalyticsDataClient->listAudienceExports($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $parent Required. All audience exports for this property will be listed in the - * response. Format: `properties/{property}` - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listAudienceExports($parent, array $optionalArgs = []) - { - $request = new ListAudienceExportsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAudienceExports', $optionalArgs, ListAudienceExportsResponse::class, $request); - } - - /** - * Retrieves an audience export of users. After creating an audience, the - * users are not immediately available for exporting. First, a request to - * `CreateAudienceExport` is necessary to create an audience export of users, - * and then second, this method is used to retrieve the users in the audience - * export. - * - * See [Creating an Audience - * Export](https://developers.google.com/analytics/devguides/reporting/data/v1/audience-list-basics) - * for an introduction to Audience Exports with examples. - * - * Audiences in Google Analytics 4 allow you to segment your users in the ways - * that are important to your business. To learn more, see - * https://support.google.com/analytics/answer/9267572. - * - * Audience Export APIs have some methods at alpha and other methods at beta - * stability. The intention is to advance methods to beta stability after some - * feedback and adoption. To give your feedback on this API, complete the - * [Google Analytics Audience Export API - * Feedback](https://forms.gle/EeA5u5LW6PEggtCEA) form. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $name = 'name'; - * $response = $betaAnalyticsDataClient->queryAudienceExport($name); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the audience export to retrieve users from. - * Format: `properties/{property}/audienceExports/{audience_export}` - * @param array $optionalArgs { - * Optional. - * - * @type int $offset - * Optional. The row count of the start row. The first row is counted as row - * 0. - * - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int $limit - * Optional. The number of rows to return. If unspecified, 10,000 rows are - * returned. The API returns a maximum of 250,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`. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\QueryAudienceExportResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function queryAudienceExport($name, array $optionalArgs = []) - { - $request = new QueryAudienceExportRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - if (isset($optionalArgs['offset'])) { - $request->setOffset($optionalArgs['offset']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('QueryAudienceExport', QueryAudienceExportResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a customized pivot report of your Google Analytics event data. - * Pivot reports are more advanced and expressive formats than regular - * reports. In a pivot report, dimensions are only visible if they are - * included in a pivot. Multiple pivots can be specified to further dissect - * your data. - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->runPivotReport(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $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 - * @type Dimension[] $dimensions - * The dimensions requested. All defined dimensions must be used by one of the - * following: dimension_expression, dimension_filter, pivots, order_bys. - * @type Metric[] $metrics - * The metrics requested, at least one metric needs to be specified. All - * defined metrics must be used by one of the following: metric_expression, - * metric_filter, order_bys. - * @type DateRange[] $dateRanges - * The date range to retrieve event data for the report. If multiple date - * ranges are specified, event data from each date range is used in the - * report. A special dimension with field name "dateRange" can be included in - * a Pivot's field names; if included, the report compares between date - * ranges. In a cohort request, this `dateRanges` must be unspecified. - * @type Pivot[] $pivots - * Describes the visual format of the report's dimensions in columns or rows. - * The union of the fieldNames (dimension names) in all pivots must be a - * subset of dimension names defined in Dimensions. No two pivots can share a - * dimension. A dimension is only visible if it appears in a pivot. - * @type FilterExpression $dimensionFilter - * The filter clause of dimensions. Dimensions must be requested to be used in - * this filter. Metrics cannot be used in this filter. - * @type FilterExpression $metricFilter - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Metrics must be requested to be used in this filter. - * Dimensions cannot be used in this filter. - * @type string $currencyCode - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * @type CohortSpec $cohortSpec - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * @type bool $keepEmptyRows - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * @type bool $returnPropertyQuota - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\RunPivotReportResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function runPivotReport(array $optionalArgs = []) - { - $request = new RunPivotReportRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['dimensions'])) { - $request->setDimensions($optionalArgs['dimensions']); - } - - if (isset($optionalArgs['metrics'])) { - $request->setMetrics($optionalArgs['metrics']); - } - - if (isset($optionalArgs['dateRanges'])) { - $request->setDateRanges($optionalArgs['dateRanges']); - } - - if (isset($optionalArgs['pivots'])) { - $request->setPivots($optionalArgs['pivots']); - } - - if (isset($optionalArgs['dimensionFilter'])) { - $request->setDimensionFilter($optionalArgs['dimensionFilter']); - } - - if (isset($optionalArgs['metricFilter'])) { - $request->setMetricFilter($optionalArgs['metricFilter']); - } - - if (isset($optionalArgs['currencyCode'])) { - $request->setCurrencyCode($optionalArgs['currencyCode']); - } - - if (isset($optionalArgs['cohortSpec'])) { - $request->setCohortSpec($optionalArgs['cohortSpec']); - } - - if (isset($optionalArgs['keepEmptyRows'])) { - $request->setKeepEmptyRows($optionalArgs['keepEmptyRows']); - } - - if (isset($optionalArgs['returnPropertyQuota'])) { - $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RunPivotReport', RunPivotReportResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a customized report of realtime event data for your property. - * Events appear in realtime reports seconds after they have been sent to - * the Google Analytics. Realtime reports show events and usage data for the - * periods of time ranging from the present moment to 30 minutes ago (up to - * 60 minutes for Google Analytics 360 properties). - * - * For a guide to constructing realtime requests & understanding responses, - * see [Creating a Realtime - * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/realtime-basics). - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->runRealtimeReport(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $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). - * - * Example: properties/1234 - * @type Dimension[] $dimensions - * The dimensions requested and displayed. - * @type Metric[] $metrics - * The metrics requested and displayed. - * @type FilterExpression $dimensionFilter - * The filter clause of dimensions. Metrics cannot be used in this filter. - * @type FilterExpression $metricFilter - * The filter clause of metrics. Applied at post aggregation phase, similar to - * SQL having-clause. Dimensions cannot be used in this filter. - * @type int $limit - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * @type int[] $metricAggregations - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\MetricAggregation} - * @type OrderBy[] $orderBys - * Specifies how rows are ordered in the response. - * @type bool $returnPropertyQuota - * Toggles whether to return the current state of this Analytics Property's - * Realtime quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * @type MinuteRange[] $minuteRanges - * The minute ranges of event data to read. If unspecified, one minute range - * for the last 30 minutes will be used. If multiple minute ranges are - * requested, each response row will contain a zero based minute range index. - * If two minute ranges overlap, the event data for the overlapping minutes is - * included in the response rows for both minute ranges. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\RunRealtimeReportResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function runRealtimeReport(array $optionalArgs = []) - { - $request = new RunRealtimeReportRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['dimensions'])) { - $request->setDimensions($optionalArgs['dimensions']); - } - - if (isset($optionalArgs['metrics'])) { - $request->setMetrics($optionalArgs['metrics']); - } - - if (isset($optionalArgs['dimensionFilter'])) { - $request->setDimensionFilter($optionalArgs['dimensionFilter']); - } - - if (isset($optionalArgs['metricFilter'])) { - $request->setMetricFilter($optionalArgs['metricFilter']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - if (isset($optionalArgs['metricAggregations'])) { - $request->setMetricAggregations($optionalArgs['metricAggregations']); - } - - if (isset($optionalArgs['orderBys'])) { - $request->setOrderBys($optionalArgs['orderBys']); - } - - if (isset($optionalArgs['returnPropertyQuota'])) { - $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); - } - - if (isset($optionalArgs['minuteRanges'])) { - $request->setMinuteRanges($optionalArgs['minuteRanges']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RunRealtimeReport', RunRealtimeReportResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns a customized report of your Google Analytics event data. Reports - * contain statistics derived from data collected by the Google Analytics - * tracking code. The data returned from the API is as a table with columns - * for the requested dimensions and metrics. Metrics are individual - * measurements of user activity on your property, such as active users or - * event count. Dimensions break down metrics across some common criteria, - * such as country or event name. - * - * For a guide to constructing requests & understanding responses, see - * [Creating a - * Report](https://developers.google.com/analytics/devguides/reporting/data/v1/basics). - * - * Sample code: - * ``` - * $betaAnalyticsDataClient = new BetaAnalyticsDataClient(); - * try { - * $response = $betaAnalyticsDataClient->runReport(); - * } finally { - * $betaAnalyticsDataClient->close(); - * } - * ``` - * - * @param array $optionalArgs { - * Optional. - * - * @type string $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 - * @type Dimension[] $dimensions - * The dimensions requested and displayed. - * @type Metric[] $metrics - * The metrics requested and displayed. - * @type DateRange[] $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. In a cohort request, this `dateRanges` - * must be unspecified. - * @type FilterExpression $dimensionFilter - * Dimension filters let you ask for only specific dimension values in - * the report. To learn more, see [Fundamentals of Dimension - * Filters](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#dimension_filters) - * for examples. Metrics cannot be used in this filter. - * @type FilterExpression $metricFilter - * The filter clause of metrics. Applied after aggregating the report's rows, - * similar to SQL having-clause. Dimensions cannot be used in this filter. - * @type int $offset - * The row count of the start row. The first row is counted as row 0. - * - * When paging, the first request does not specify offset; or equivalently, - * sets offset to 0; the first request returns the first `limit` of rows. The - * second request sets offset to the `limit` of the first request; the second - * request returns the second `limit` of rows. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int $limit - * The number of rows to return. If unspecified, 10,000 rows are returned. The - * API returns a maximum of 250,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`. For instance, there are - * fewer than 300 possible values for the dimension `country`, so when - * reporting on only `country`, you can't get more than 300 rows, even if you - * set `limit` to a higher value. - * - * To learn more about this pagination parameter, see - * [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination). - * @type int[] $metricAggregations - * Aggregation of metrics. Aggregated metric values will be shown in rows - * where the dimension_values are set to "RESERVED_(MetricAggregation)". - * For allowed values, use constants defined on {@see \Google\Analytics\Data\V1beta\MetricAggregation} - * @type OrderBy[] $orderBys - * Specifies how rows are ordered in the response. - * @type string $currencyCode - * A currency code in ISO4217 format, such as "AED", "USD", "JPY". - * If the field is empty, the report uses the property's default currency. - * @type CohortSpec $cohortSpec - * Cohort group associated with this request. If there is a cohort group - * in the request the 'cohort' dimension must be present. - * @type bool $keepEmptyRows - * If false or unspecified, each row with all metrics equal to 0 will not be - * returned. If true, these rows will be returned if they are not separately - * removed by a filter. - * - * Regardless of this `keep_empty_rows` setting, only data recorded by the - * Google Analytics (GA4) property can be displayed in a report. - * - * For example if a property never logs a `purchase` event, then a query for - * the `eventName` dimension and `eventCount` metric will not have a row - * eventName: "purchase" and eventCount: 0. - * @type bool $returnPropertyQuota - * Toggles whether to return the current state of this Analytics Property's - * quota. Quota is returned in [PropertyQuota](#PropertyQuota). - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Analytics\Data\V1beta\RunReportResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function runReport(array $optionalArgs = []) - { - $request = new RunReportRequest(); - $requestParamHeaders = []; - if (isset($optionalArgs['property'])) { - $request->setProperty($optionalArgs['property']); - $requestParamHeaders['property'] = $optionalArgs['property']; - } - - if (isset($optionalArgs['dimensions'])) { - $request->setDimensions($optionalArgs['dimensions']); - } - - if (isset($optionalArgs['metrics'])) { - $request->setMetrics($optionalArgs['metrics']); - } - - if (isset($optionalArgs['dateRanges'])) { - $request->setDateRanges($optionalArgs['dateRanges']); - } - - if (isset($optionalArgs['dimensionFilter'])) { - $request->setDimensionFilter($optionalArgs['dimensionFilter']); - } - - if (isset($optionalArgs['metricFilter'])) { - $request->setMetricFilter($optionalArgs['metricFilter']); - } - - if (isset($optionalArgs['offset'])) { - $request->setOffset($optionalArgs['offset']); - } - - if (isset($optionalArgs['limit'])) { - $request->setLimit($optionalArgs['limit']); - } - - if (isset($optionalArgs['metricAggregations'])) { - $request->setMetricAggregations($optionalArgs['metricAggregations']); - } - - if (isset($optionalArgs['orderBys'])) { - $request->setOrderBys($optionalArgs['orderBys']); - } - - if (isset($optionalArgs['currencyCode'])) { - $request->setCurrencyCode($optionalArgs['currencyCode']); - } - - if (isset($optionalArgs['cohortSpec'])) { - $request->setCohortSpec($optionalArgs['cohortSpec']); - } - - if (isset($optionalArgs['keepEmptyRows'])) { - $request->setKeepEmptyRows($optionalArgs['keepEmptyRows']); - } - - if (isset($optionalArgs['returnPropertyQuota'])) { - $request->setReturnPropertyQuota($optionalArgs['returnPropertyQuota']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('RunReport', RunReportResponse::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json deleted file mode 100644 index 335b5f181e5..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/gapic_metadata.json +++ /dev/null @@ -1,73 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.analytics.data.v1beta", - "libraryPackage": "Google\\Analytics\\Data\\V1beta", - "services": { - "BetaAnalyticsData": { - "clients": { - "grpc": { - "libraryClient": "BetaAnalyticsDataGapicClient", - "rpcs": { - "BatchRunPivotReports": { - "methods": [ - "batchRunPivotReports" - ] - }, - "BatchRunReports": { - "methods": [ - "batchRunReports" - ] - }, - "CheckCompatibility": { - "methods": [ - "checkCompatibility" - ] - }, - "CreateAudienceExport": { - "methods": [ - "createAudienceExport" - ] - }, - "GetAudienceExport": { - "methods": [ - "getAudienceExport" - ] - }, - "GetMetadata": { - "methods": [ - "getMetadata" - ] - }, - "ListAudienceExports": { - "methods": [ - "listAudienceExports" - ] - }, - "QueryAudienceExport": { - "methods": [ - "queryAudienceExport" - ] - }, - "RunPivotReport": { - "methods": [ - "runPivotReport" - ] - }, - "RunRealtimeReport": { - "methods": [ - "runRealtimeReport" - ] - }, - "RunReport": { - "methods": [ - "runReport" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json deleted file mode 100644 index b0f3237c5d3..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_client_config.json +++ /dev/null @@ -1,99 +0,0 @@ -{ - "interfaces": { - "google.analytics.data.v1beta.BetaAnalyticsData": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNKNOWN" - ], - "no_retry_1_codes": [] - }, - "retry_params": { - "no_retry_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 0, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 0, - "total_timeout_millis": 0 - }, - "retry_policy_1_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - }, - "no_retry_1_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 60000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 60000, - "total_timeout_millis": 60000 - } - }, - "methods": { - "BatchRunPivotReports": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "BatchRunReports": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CheckCompatibility": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateAudienceExport": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetAudienceExport": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetMetadata": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListAudienceExports": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "QueryAudienceExport": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RunPivotReport": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "RunRealtimeReport": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "RunReport": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php deleted file mode 100644 index d98545e8578..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_descriptor_config.php +++ /dev/null @@ -1,180 +0,0 @@ - [ - 'google.analytics.data.v1beta.BetaAnalyticsData' => [ - 'CreateAudienceExport' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Analytics\Data\V1beta\AudienceExport', - 'metadataReturnType' => '\Google\Analytics\Data\V1beta\AudienceExportMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'BatchRunPivotReports' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\BatchRunPivotReportsResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'BatchRunReports' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\BatchRunReportsResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'CheckCompatibility' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\CheckCompatibilityResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'GetAudienceExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\AudienceExport', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetMetadata' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\Metadata', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListAudienceExports' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAudienceExports', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\ListAudienceExportsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'QueryAudienceExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\QueryAudienceExportResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RunPivotReport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\RunPivotReportResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'RunRealtimeReport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\RunRealtimeReportResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'RunReport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Analytics\Data\V1beta\RunReportResponse', - 'headerParams' => [ - [ - 'keyName' => 'property', - 'fieldAccessors' => [ - 'getProperty', - ], - ], - ], - ], - 'templateMap' => [ - 'audienceExport' => 'properties/{property}/audienceExports/{audience_export}', - 'metadata' => 'properties/{property}/metadata', - 'property' => 'properties/{property}', - ], - ], - ], -]; diff --git a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php b/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php deleted file mode 100644 index d4183f113c4..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/src/V1beta/resources/beta_analytics_data_rest_client_config.php +++ /dev/null @@ -1,158 +0,0 @@ - [ - 'google.analytics.data.v1beta.BetaAnalyticsData' => [ - 'BatchRunPivotReports' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:batchRunPivotReports', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'BatchRunReports' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:batchRunReports', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'CheckCompatibility' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:checkCompatibility', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'CreateAudienceExport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{parent=properties/*}/audienceExports', - 'body' => 'audience_export', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'GetAudienceExport' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta/{name=properties/*/audienceExports/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetMetadata' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta/{name=properties/*/metadata}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListAudienceExports' => [ - 'method' => 'get', - 'uriTemplate' => '/v1beta/{parent=properties/*}/audienceExports', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'QueryAudienceExport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{name=properties/*/audienceExports/*}:query', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'RunPivotReport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:runPivotReport', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'RunRealtimeReport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:runRealtimeReport', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - 'RunReport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1beta/{property=properties/*}:runReport', - 'body' => '*', - 'placeholders' => [ - 'property' => [ - 'getters' => [ - 'getProperty', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php deleted file mode 100644 index 7b3d2e65321..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/BetaAnalyticsDataClientTest.php +++ /dev/null @@ -1,803 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return BetaAnalyticsDataClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new BetaAnalyticsDataClient($options); - } - - /** @test */ - public function batchRunPivotReportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new BatchRunPivotReportsResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->batchRunPivotReports(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunPivotReportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->batchRunPivotReports(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunReportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new BatchRunReportsResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->batchRunReports(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunReports', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunReportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->batchRunReports(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function checkCompatibilityTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new CheckCompatibilityResponse(); - $transport->addResponse($expectedResponse); - $response = $gapicClient->checkCompatibility(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CheckCompatibility', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function checkCompatibilityExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->checkCompatibility(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createAudienceExportTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceExportTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $expectedResponse = new AudienceExport(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAudienceExportTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceExport = new AudienceExport(); - $audienceExportAudience = 'audienceExportAudience1191136508'; - $audienceExport->setAudience($audienceExportAudience); - $audienceExportDimensions = []; - $audienceExport->setDimensions($audienceExportDimensions); - $response = $gapicClient->createAudienceExport($formattedParent, $audienceExport); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CreateAudienceExport', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAudienceExport(); - $this->assertProtobufEquals($audienceExport, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAudienceExportExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceExportTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceExport = new AudienceExport(); - $audienceExportAudience = 'audienceExportAudience1191136508'; - $audienceExport->setAudience($audienceExportAudience); - $audienceExportDimensions = []; - $audienceExport->setDimensions($audienceExportDimensions); - $response = $gapicClient->createAudienceExport($formattedParent, $audienceExport); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAudienceExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $expectedResponse = new AudienceExport(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - $response = $gapicClient->getAudienceExport($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetAudienceExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAudienceExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - try { - $gapicClient->getAudienceExport($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMetadataTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Metadata(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->metadataName('[PROPERTY]'); - $response = $gapicClient->getMetadata($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetMetadata', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMetadataExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->metadataName('[PROPERTY]'); - try { - $gapicClient->getMetadata($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceExportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $audienceExportsElement = new AudienceExport(); - $audienceExports = [ - $audienceExportsElement, - ]; - $expectedResponse = new ListAudienceExportsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAudienceExports($audienceExports); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $response = $gapicClient->listAudienceExports($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAudienceExports()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/ListAudienceExports', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceExportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - try { - $gapicClient->listAudienceExports($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryAudienceExportResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $response = $gapicClient->queryAudienceExport($name); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/QueryAudienceExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - try { - $gapicClient->queryAudienceExport($name); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runPivotReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new RunPivotReportResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->runPivotReport(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunPivotReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runPivotReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->runPivotReport(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runRealtimeReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $kind = 'kind3292052'; - $expectedResponse = new RunRealtimeReportResponse(); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->runRealtimeReport(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunRealtimeReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runRealtimeReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->runRealtimeReport(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $kind = 'kind3292052'; - $expectedResponse = new RunReportResponse(); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $response = $gapicClient->runReport(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - try { - $gapicClient->runReport(); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php b/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php deleted file mode 100644 index 57d3ff4db25..00000000000 --- a/owl-bot-staging/AnalyticsData/v1beta/tests/Unit/V1beta/Client/BetaAnalyticsDataClientTest.php +++ /dev/null @@ -1,872 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return BetaAnalyticsDataClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new BetaAnalyticsDataClient($options); - } - - /** @test */ - public function batchRunPivotReportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new BatchRunPivotReportsResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new BatchRunPivotReportsRequest(); - $response = $gapicClient->batchRunPivotReports($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunPivotReportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new BatchRunPivotReportsRequest(); - try { - $gapicClient->batchRunPivotReports($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunReportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new BatchRunReportsResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new BatchRunReportsRequest(); - $response = $gapicClient->batchRunReports($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunReports', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunReportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new BatchRunReportsRequest(); - try { - $gapicClient->batchRunReports($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function checkCompatibilityTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new CheckCompatibilityResponse(); - $transport->addResponse($expectedResponse); - $request = new CheckCompatibilityRequest(); - $response = $gapicClient->checkCompatibility($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CheckCompatibility', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function checkCompatibilityExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new CheckCompatibilityRequest(); - try { - $gapicClient->checkCompatibility($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createAudienceExportTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceExportTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $expectedResponse = new AudienceExport(); - $expectedResponse->setName($name); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createAudienceExportTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceExport = new AudienceExport(); - $audienceExportAudience = 'audienceExportAudience1191136508'; - $audienceExport->setAudience($audienceExportAudience); - $audienceExportDimensions = []; - $audienceExport->setDimensions($audienceExportDimensions); - $request = (new CreateAudienceExportRequest()) - ->setParent($formattedParent) - ->setAudienceExport($audienceExport); - $response = $gapicClient->createAudienceExport($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/CreateAudienceExport', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getAudienceExport(); - $this->assertProtobufEquals($audienceExport, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createAudienceExportExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/createAudienceExportTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $audienceExport = new AudienceExport(); - $audienceExportAudience = 'audienceExportAudience1191136508'; - $audienceExport->setAudience($audienceExportAudience); - $audienceExportDimensions = []; - $audienceExport->setDimensions($audienceExportDimensions); - $request = (new CreateAudienceExportRequest()) - ->setParent($formattedParent) - ->setAudienceExport($audienceExport); - $response = $gapicClient->createAudienceExport($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createAudienceExportTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function getAudienceExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $audience = 'audience975628804'; - $audienceDisplayName = 'audienceDisplayName406858307'; - $creationQuotaTokensCharged = 1232901266; - $rowCount = 1340416618; - $errorMessage = 'errorMessage-1938755376'; - $percentageCompleted = -1.29204764E8; - $expectedResponse = new AudienceExport(); - $expectedResponse->setName($name2); - $expectedResponse->setAudience($audience); - $expectedResponse->setAudienceDisplayName($audienceDisplayName); - $expectedResponse->setCreationQuotaTokensCharged($creationQuotaTokensCharged); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setErrorMessage($errorMessage); - $expectedResponse->setPercentageCompleted($percentageCompleted); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - $request = (new GetAudienceExportRequest()) - ->setName($formattedName); - $response = $gapicClient->getAudienceExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetAudienceExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getAudienceExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->audienceExportName('[PROPERTY]', '[AUDIENCE_EXPORT]'); - $request = (new GetAudienceExportRequest()) - ->setName($formattedName); - try { - $gapicClient->getAudienceExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMetadataTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Metadata(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->metadataName('[PROPERTY]'); - $request = (new GetMetadataRequest()) - ->setName($formattedName); - $response = $gapicClient->getMetadata($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/GetMetadata', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMetadataExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->metadataName('[PROPERTY]'); - $request = (new GetMetadataRequest()) - ->setName($formattedName); - try { - $gapicClient->getMetadata($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceExportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $audienceExportsElement = new AudienceExport(); - $audienceExports = [ - $audienceExportsElement, - ]; - $expectedResponse = new ListAudienceExportsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAudienceExports($audienceExports); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListAudienceExportsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listAudienceExports($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAudienceExports()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/ListAudienceExports', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAudienceExportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->propertyName('[PROPERTY]'); - $request = (new ListAudienceExportsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listAudienceExports($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $expectedResponse = new QueryAudienceExportResponse(); - $expectedResponse->setRowCount($rowCount); - $transport->addResponse($expectedResponse); - // Mock request - $name = 'name3373707'; - $request = (new QueryAudienceExportRequest()) - ->setName($name); - $response = $gapicClient->queryAudienceExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/QueryAudienceExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($name, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryAudienceExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $name = 'name3373707'; - $request = (new QueryAudienceExportRequest()) - ->setName($name); - try { - $gapicClient->queryAudienceExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runPivotReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new RunPivotReportResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new RunPivotReportRequest(); - $response = $gapicClient->runPivotReport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunPivotReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runPivotReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new RunPivotReportRequest(); - try { - $gapicClient->runPivotReport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runRealtimeReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $kind = 'kind3292052'; - $expectedResponse = new RunRealtimeReportResponse(); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new RunRealtimeReportRequest(); - $response = $gapicClient->runRealtimeReport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunRealtimeReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runRealtimeReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new RunRealtimeReportRequest(); - try { - $gapicClient->runRealtimeReport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rowCount = 1340416618; - $kind = 'kind3292052'; - $expectedResponse = new RunReportResponse(); - $expectedResponse->setRowCount($rowCount); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new RunReportRequest(); - $response = $gapicClient->runReport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/RunReport', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runReportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - $request = new RunReportRequest(); - try { - $gapicClient->runReport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchRunPivotReportsAsyncTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $kind = 'kind3292052'; - $expectedResponse = new BatchRunPivotReportsResponse(); - $expectedResponse->setKind($kind); - $transport->addResponse($expectedResponse); - $request = new BatchRunPivotReportsRequest(); - $response = $gapicClient->batchRunPivotReportsAsync($request)->wait(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.analytics.data.v1beta.BetaAnalyticsData/BatchRunPivotReports', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } -}