public static final class Bucket.Lifecycle.Rule.Condition extends GeneratedMessageV3 implements Bucket.Lifecycle.Rule.ConditionOrBuilder
A condition of an object which triggers some action.
Protobuf type google.storage.v2.Bucket.Lifecycle.Rule.Condition
Fields
AGE_DAYS_FIELD_NUMBER
public static final int AGE_DAYS_FIELD_NUMBER
Field Value
CREATED_BEFORE_FIELD_NUMBER
public static final int CREATED_BEFORE_FIELD_NUMBER
Field Value
CUSTOM_TIME_BEFORE_FIELD_NUMBER
public static final int CUSTOM_TIME_BEFORE_FIELD_NUMBER
Field Value
DAYS_SINCE_CUSTOM_TIME_FIELD_NUMBER
public static final int DAYS_SINCE_CUSTOM_TIME_FIELD_NUMBER
Field Value
DAYS_SINCE_NONCURRENT_TIME_FIELD_NUMBER
public static final int DAYS_SINCE_NONCURRENT_TIME_FIELD_NUMBER
Field Value
IS_LIVE_FIELD_NUMBER
public static final int IS_LIVE_FIELD_NUMBER
Field Value
MATCHES_STORAGE_CLASS_FIELD_NUMBER
public static final int MATCHES_STORAGE_CLASS_FIELD_NUMBER
Field Value
NONCURRENT_TIME_BEFORE_FIELD_NUMBER
public static final int NONCURRENT_TIME_BEFORE_FIELD_NUMBER
Field Value
NUM_NEWER_VERSIONS_FIELD_NUMBER
public static final int NUM_NEWER_VERSIONS_FIELD_NUMBER
Field Value
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getAgeDays()
Age of an object (in days). This condition is satisfied when an
object reaches the specified age.
A value of 0 indicates that all objects immediately match this
condition.
int32 age_days = 1;
Returns
Type |
Description |
int |
The ageDays.
|
getCreatedBefore()
public Date getCreatedBefore()
This condition is satisfied when an object is created before midnight
of the specified date in UTC.
.google.type.Date created_before = 2;
Returns
Type |
Description |
com.google.type.Date |
The createdBefore.
|
getCreatedBeforeOrBuilder()
public DateOrBuilder getCreatedBeforeOrBuilder()
This condition is satisfied when an object is created before midnight
of the specified date in UTC.
.google.type.Date created_before = 2;
Returns
Type |
Description |
com.google.type.DateOrBuilder |
|
getCustomTimeBefore()
public Date getCustomTimeBefore()
An object matches this condition if the custom timestamp set on the
object is before the specified date in UTC.
.google.type.Date custom_time_before = 8;
Returns
Type |
Description |
com.google.type.Date |
The customTimeBefore.
|
getCustomTimeBeforeOrBuilder()
public DateOrBuilder getCustomTimeBeforeOrBuilder()
An object matches this condition if the custom timestamp set on the
object is before the specified date in UTC.
.google.type.Date custom_time_before = 8;
Returns
Type |
Description |
com.google.type.DateOrBuilder |
|
getDaysSinceCustomTime()
public int getDaysSinceCustomTime()
Number of days that have elapsed since the custom timestamp set on an
object.
The value of the field must be a nonnegative integer.
int32 days_since_custom_time = 7;
Returns
Type |
Description |
int |
The daysSinceCustomTime.
|
getDaysSinceNoncurrentTime()
public int getDaysSinceNoncurrentTime()
This condition is relevant only for versioned objects. An object
version satisfies this condition only if these many days have been
passed since it became noncurrent. The value of the field must be a
nonnegative integer. If it's zero, the object version will become
eligible for Lifecycle action as soon as it becomes noncurrent.
int32 days_since_noncurrent_time = 9;
Returns
Type |
Description |
int |
The daysSinceNoncurrentTime.
|
getDefaultInstance()
public static Bucket.Lifecycle.Rule.Condition getDefaultInstance()
Returns
getDefaultInstanceForType()
public Bucket.Lifecycle.Rule.Condition getDefaultInstanceForType()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
getIsLive()
public boolean getIsLive()
Relevant only for versioned objects. If the value is
true
, this condition matches live objects; if the value
is false
, it matches archived objects.
bool is_live = 3;
Returns
Type |
Description |
boolean |
The isLive.
|
getMatchesStorageClass(int index)
public String getMatchesStorageClass(int index)
Objects having any of the storage classes specified by this condition
will be matched. Values include MULTI_REGIONAL
, REGIONAL
,
NEARLINE
, COLDLINE
, STANDARD
, and
DURABLE_REDUCED_AVAILABILITY
.
repeated string matches_storage_class = 5;
Parameter
Name |
Description |
index |
int
The index of the element to return.
|
Returns
Type |
Description |
String |
The matchesStorageClass at the given index.
|
getMatchesStorageClassBytes(int index)
public ByteString getMatchesStorageClassBytes(int index)
Objects having any of the storage classes specified by this condition
will be matched. Values include MULTI_REGIONAL
, REGIONAL
,
NEARLINE
, COLDLINE
, STANDARD
, and
DURABLE_REDUCED_AVAILABILITY
.
repeated string matches_storage_class = 5;
Parameter
Name |
Description |
index |
int
The index of the value to return.
|
Returns
Type |
Description |
ByteString |
The bytes of the matchesStorageClass at the given index.
|
getMatchesStorageClassCount()
public int getMatchesStorageClassCount()
Objects having any of the storage classes specified by this condition
will be matched. Values include MULTI_REGIONAL
, REGIONAL
,
NEARLINE
, COLDLINE
, STANDARD
, and
DURABLE_REDUCED_AVAILABILITY
.
repeated string matches_storage_class = 5;
Returns
Type |
Description |
int |
The count of matchesStorageClass.
|
getMatchesStorageClassList()
public ProtocolStringList getMatchesStorageClassList()
Objects having any of the storage classes specified by this condition
will be matched. Values include MULTI_REGIONAL
, REGIONAL
,
NEARLINE
, COLDLINE
, STANDARD
, and
DURABLE_REDUCED_AVAILABILITY
.
repeated string matches_storage_class = 5;
Returns
getNoncurrentTimeBefore()
public Date getNoncurrentTimeBefore()
This condition is relevant only for versioned objects. An object
version satisfies this condition only if it became noncurrent before
the specified date in UTC.
.google.type.Date noncurrent_time_before = 10;
Returns
Type |
Description |
com.google.type.Date |
The noncurrentTimeBefore.
|
getNoncurrentTimeBeforeOrBuilder()
public DateOrBuilder getNoncurrentTimeBeforeOrBuilder()
This condition is relevant only for versioned objects. An object
version satisfies this condition only if it became noncurrent before
the specified date in UTC.
.google.type.Date noncurrent_time_before = 10;
Returns
Type |
Description |
com.google.type.DateOrBuilder |
|
getNumNewerVersions()
public int getNumNewerVersions()
Relevant only for versioned objects. If the value is N, this
condition is satisfied when there are at least N versions (including
the live version) newer than this version of the object.
int32 num_newer_versions = 4;
Returns
Type |
Description |
int |
The numNewerVersions.
|
getParserForType()
public Parser<Bucket.Lifecycle.Rule.Condition> getParserForType()
Returns
Overrides
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hasAgeDays()
public boolean hasAgeDays()
Age of an object (in days). This condition is satisfied when an
object reaches the specified age.
A value of 0 indicates that all objects immediately match this
condition.
int32 age_days = 1;
Returns
Type |
Description |
boolean |
Whether the ageDays field is set.
|
hasCreatedBefore()
public boolean hasCreatedBefore()
This condition is satisfied when an object is created before midnight
of the specified date in UTC.
.google.type.Date created_before = 2;
Returns
Type |
Description |
boolean |
Whether the createdBefore field is set.
|
hasCustomTimeBefore()
public boolean hasCustomTimeBefore()
An object matches this condition if the custom timestamp set on the
object is before the specified date in UTC.
.google.type.Date custom_time_before = 8;
Returns
Type |
Description |
boolean |
Whether the customTimeBefore field is set.
|
hasDaysSinceCustomTime()
public boolean hasDaysSinceCustomTime()
Number of days that have elapsed since the custom timestamp set on an
object.
The value of the field must be a nonnegative integer.
int32 days_since_custom_time = 7;
Returns
Type |
Description |
boolean |
Whether the daysSinceCustomTime field is set.
|
hasDaysSinceNoncurrentTime()
public boolean hasDaysSinceNoncurrentTime()
This condition is relevant only for versioned objects. An object
version satisfies this condition only if these many days have been
passed since it became noncurrent. The value of the field must be a
nonnegative integer. If it's zero, the object version will become
eligible for Lifecycle action as soon as it becomes noncurrent.
int32 days_since_noncurrent_time = 9;
Returns
Type |
Description |
boolean |
Whether the daysSinceNoncurrentTime field is set.
|
hasIsLive()
public boolean hasIsLive()
Relevant only for versioned objects. If the value is
true
, this condition matches live objects; if the value
is false
, it matches archived objects.
bool is_live = 3;
Returns
Type |
Description |
boolean |
Whether the isLive field is set.
|
hasNoncurrentTimeBefore()
public boolean hasNoncurrentTimeBefore()
This condition is relevant only for versioned objects. An object
version satisfies this condition only if it became noncurrent before
the specified date in UTC.
.google.type.Date noncurrent_time_before = 10;
Returns
Type |
Description |
boolean |
Whether the noncurrentTimeBefore field is set.
|
hasNumNewerVersions()
public boolean hasNumNewerVersions()
Relevant only for versioned objects. If the value is N, this
condition is satisfied when there are at least N versions (including
the live version) newer than this version of the object.
int32 num_newer_versions = 4;
Returns
Type |
Description |
boolean |
Whether the numNewerVersions field is set.
|
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilder()
public static Bucket.Lifecycle.Rule.Condition.Builder newBuilder()
Returns
newBuilder(Bucket.Lifecycle.Rule.Condition prototype)
public static Bucket.Lifecycle.Rule.Condition.Builder newBuilder(Bucket.Lifecycle.Rule.Condition prototype)
Parameter
Returns
newBuilderForType()
public Bucket.Lifecycle.Rule.Condition.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Bucket.Lifecycle.Rule.Condition.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
public static Bucket.Lifecycle.Rule.Condition parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static Bucket.Lifecycle.Rule.Condition parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static Bucket.Lifecycle.Rule.Condition parseFrom(byte[] data)
Parameter
Name |
Description |
data |
byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Bucket.Lifecycle.Rule.Condition parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static Bucket.Lifecycle.Rule.Condition parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Bucket.Lifecycle.Rule.Condition parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Bucket.Lifecycle.Rule.Condition parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static Bucket.Lifecycle.Rule.Condition parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static Bucket.Lifecycle.Rule.Condition parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static Bucket.Lifecycle.Rule.Condition parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static Bucket.Lifecycle.Rule.Condition parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Bucket.Lifecycle.Rule.Condition parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<Bucket.Lifecycle.Rule.Condition> parser()
Returns
toBuilder()
public Bucket.Lifecycle.Rule.Condition.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions