public final class CohortSpec extends com.google.protobuf.GeneratedMessageV3 implements CohortSpecOrBuilder
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 `cohortActiveUsers/cohortTotalUsers` and will be separate rows in the report.Protobuf type
google.analytics.data.v1beta.CohortSpec| Modifier and Type | Class and Description |
|---|---|
static class |
CohortSpec.Builder
The specification of cohorts for a cohort report.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
COHORT_REPORT_SETTINGS_FIELD_NUMBER |
static int |
COHORTS_FIELD_NUMBER |
static int |
COHORTS_RANGE_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
CohortReportSettings |
getCohortReportSettings()
Optional settings for a cohort report.
|
CohortReportSettingsOrBuilder |
getCohortReportSettingsOrBuilder()
Optional settings for a cohort report.
|
Cohort |
getCohorts(int index)
Defines the selection criteria to group users into cohorts.
|
int |
getCohortsCount()
Defines the selection criteria to group users into cohorts.
|
List<Cohort> |
getCohortsList()
Defines the selection criteria to group users into cohorts.
|
CohortOrBuilder |
getCohortsOrBuilder(int index)
Defines the selection criteria to group users into cohorts.
|
List<? extends CohortOrBuilder> |
getCohortsOrBuilderList()
Defines the selection criteria to group users into cohorts.
|
CohortsRange |
getCohortsRange()
Cohort reports follow cohorts over an extended reporting date range.
|
CohortsRangeOrBuilder |
getCohortsRangeOrBuilder()
Cohort reports follow cohorts over an extended reporting date range.
|
static CohortSpec |
getDefaultInstance() |
CohortSpec |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Parser<CohortSpec> |
getParserForType() |
int |
getSerializedSize() |
com.google.protobuf.UnknownFieldSet |
getUnknownFields() |
boolean |
hasCohortReportSettings()
Optional settings for a cohort report.
|
boolean |
hasCohortsRange()
Cohort reports follow cohorts over an extended reporting date range.
|
int |
hashCode() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static CohortSpec.Builder |
newBuilder() |
static CohortSpec.Builder |
newBuilder(CohortSpec prototype) |
CohortSpec.Builder |
newBuilderForType() |
protected CohortSpec.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static CohortSpec |
parseDelimitedFrom(InputStream input) |
static CohortSpec |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CohortSpec |
parseFrom(byte[] data) |
static CohortSpec |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CohortSpec |
parseFrom(ByteBuffer data) |
static CohortSpec |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CohortSpec |
parseFrom(com.google.protobuf.ByteString data) |
static CohortSpec |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CohortSpec |
parseFrom(com.google.protobuf.CodedInputStream input) |
static CohortSpec |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static CohortSpec |
parseFrom(InputStream input) |
static CohortSpec |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<CohortSpec> |
parser() |
CohortSpec.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int COHORTS_FIELD_NUMBER
public static final int COHORTS_RANGE_FIELD_NUMBER
public static final int COHORT_REPORT_SETTINGS_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public final com.google.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields in interface com.google.protobuf.MessageOrBuildergetUnknownFields in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public List<Cohort> getCohortsList()
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.
repeated .google.analytics.data.v1beta.Cohort cohorts = 1;getCohortsList in interface CohortSpecOrBuilderpublic List<? extends CohortOrBuilder> getCohortsOrBuilderList()
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.
repeated .google.analytics.data.v1beta.Cohort cohorts = 1;getCohortsOrBuilderList in interface CohortSpecOrBuilderpublic int getCohortsCount()
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.
repeated .google.analytics.data.v1beta.Cohort cohorts = 1;getCohortsCount in interface CohortSpecOrBuilderpublic Cohort getCohorts(int index)
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.
repeated .google.analytics.data.v1beta.Cohort cohorts = 1;getCohorts in interface CohortSpecOrBuilderpublic CohortOrBuilder getCohortsOrBuilder(int index)
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.
repeated .google.analytics.data.v1beta.Cohort cohorts = 1;getCohortsOrBuilder in interface CohortSpecOrBuilderpublic boolean hasCohortsRange()
Cohort reports follow cohorts over an extended reporting date range. This range specifies an offset duration to follow the cohorts over.
.google.analytics.data.v1beta.CohortsRange cohorts_range = 2;hasCohortsRange in interface CohortSpecOrBuilderpublic CohortsRange getCohortsRange()
Cohort reports follow cohorts over an extended reporting date range. This range specifies an offset duration to follow the cohorts over.
.google.analytics.data.v1beta.CohortsRange cohorts_range = 2;getCohortsRange in interface CohortSpecOrBuilderpublic CohortsRangeOrBuilder getCohortsRangeOrBuilder()
Cohort reports follow cohorts over an extended reporting date range. This range specifies an offset duration to follow the cohorts over.
.google.analytics.data.v1beta.CohortsRange cohorts_range = 2;getCohortsRangeOrBuilder in interface CohortSpecOrBuilderpublic boolean hasCohortReportSettings()
Optional settings for a cohort report.
.google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3;hasCohortReportSettings in interface CohortSpecOrBuilderpublic CohortReportSettings getCohortReportSettings()
Optional settings for a cohort report.
.google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3;getCohortReportSettings in interface CohortSpecOrBuilderpublic CohortReportSettingsOrBuilder getCohortReportSettingsOrBuilder()
Optional settings for a cohort report.
.google.analytics.data.v1beta.CohortReportSettings cohort_report_settings = 3;getCohortReportSettingsOrBuilder in interface CohortSpecOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static CohortSpec parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static CohortSpec parseFrom(InputStream input) throws IOException
IOExceptionpublic static CohortSpec parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CohortSpec parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static CohortSpec parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static CohortSpec parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static CohortSpec parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic CohortSpec.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static CohortSpec.Builder newBuilder()
public static CohortSpec.Builder newBuilder(CohortSpec prototype)
public CohortSpec.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected CohortSpec.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static CohortSpec getDefaultInstance()
public static com.google.protobuf.Parser<CohortSpec> parser()
public com.google.protobuf.Parser<CohortSpec> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public CohortSpec getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2022 Google LLC. All rights reserved.