BucketField Class
Contains methods and constructors to work with information about a bucket field, including bucket type, name, and bucketed values.
The following are constructors for BucketField.
-
Creates an instance of the
Reports.BucketFieldclass using the specified parameters. -
Creates an instance of the
Reports.BucketFieldclass. You can then set values by using the class’ssetmethods.
Creates an instance of the Reports.BucketField class using the specified parameters.
public BucketField(Reports.BucketType bucketType, String devloperName, String label, Boolean nullTreatedAsZero, String otherBucketLabel, String sourceColumnName, List<Reports.BucketFieldValue> values)
-
bucketType:
Type: Reports.BucketType
The type of bucket.
-
devloperName:
Type: String
API
name of the bucket.
-
label:
Type: String
User-facing
name of the bucket.
-
nullTreatedAsZero:
Type: Boolean
Specifies whether null values are converted to zero (
true) or not (false). -
otherBucketLabel:
Type: String
Name of the fields grouped as
Other(in buckets ofBucketTypePICKLIST). -
sourceColumnName:
Type: String
Name of the bucketed field.
-
values:
Type: List<Reports.BucketType>
Types of the values included in the bucket.
Creates an instance of the Reports.BucketField class. You can then set values by using the class’s set methods.
public BucketField()
The following are methods for BucketField.
-
Returns the bucket type.
-
Returns the bucket’s API name.
-
Returns the user-facing name of the bucket.
-
Returns
trueif null values are converted to the number zero, otherwise returnsfalse. -
Returns the name of fields grouped as
Otherin buckets of typePICKLIST. -
Returns the API name of the bucketed field.
-
Returns the report values grouped by the bucket field.
-
Sets the
BucketTypeof the bucket. -
Sets the
BucketTypeof the bucket. -
Sets the API name of the bucket.
-
Sets the user-facing name of the bucket.
-
setNullTreatedAsZero(nullTreatedAsZero)
Specifies whether null values in the bucket are converted to zero (
true) or not (false). -
setOtherBucketLabel(otherBucketLabel)
Sets the name of the fields grouped as
Other(in buckets ofBucketTypePICKLIST). -
setSourceColumnName(sourceColumnName)
Specifies the name of the bucketed field.
-
Specifies which type of values are included in the bucket.
-
Returns a string.
Returns the bucket type.
public Reports.BucketType getBucketType()
Type: Reports.BucketType
Returns the bucket’s API name.
public String getDevloperName()
Type: String
Returns the user-facing name of the bucket.
public String getLabel()
Type: String
Returns true if null values are converted to the number zero, otherwise returns false.
public Boolean getNullTreatedAsZero()
Type: Boolean
Returns the name of fields grouped as Other in buckets of type PICKLIST.
public String getOtherBucketLabel()
Type: String
Returns the API name of the bucketed field.
public String getSourceColumnName()
Type: String
Returns the report values grouped by the bucket field.
public List<Reports.BucketFieldValue> getValues()
Type: List<Reports.BucketFieldValue>
Sets the BucketType of the bucket.
public void setBucketType(String value)
-
value:
Type: String
See
the Reports.BucketType enum for valid values.
Type: void
Sets the BucketType of the bucket.
public void setBucketType(Reports.BucketType bucketType)
-
bucketType:
Type: Reports.BucketType
Type: void
Sets the API name of the bucket.
public void setDevloperName(String devloperName)
-
devloperName:
Type: String
The API name to assign to the bucket.
Type: void
Sets the user-facing name of the bucket.
public void setLabel(String label)
-
label:
Type: String
Type: void
Specifies whether null values in the bucket are converted to zero (true) or not (false).
public void setNullTreatedAsZero(Boolean nullTreatedAsZero)
-
nullTreatedAsZero:
Type: Boolean
Type: void
Sets the name of the fields grouped as Other (in buckets of BucketType PICKLIST).
public void setOtherBucketLabel(String otherBucketLabel)
-
otherBucketLabel:
Type: String
Type: void
Specifies the name of the bucketed field.
public void setSourceColumnName(String sourceColumnName)
-
sourceColumnName:
Type: String
Type: void
Specifies which type of values are included in the bucket.
public void setValues(List<Reports.BucketFieldValue> values)
-
values:
Type: List<Reports.BucketFieldValue>
Type: void
Returns a string.
public String toString()
Type: String