Interface ICustomField

All Known Subinterfaces:
AutomaticProgressCustomField, CheckboxCustomField, CurrencyCustomField, DateCustomField, DropDownCustomField, EmailCustomField, EmojiCustomField, LabelsCustomField, LocationCustomField, ManualProgressCustomField, NumberCustomField, PhoneCustomField, ShortTextCustomField, TasksCustomField, TextCustomField, URLCustomField, UsersCustomField
All Known Implementing Classes:
AutomaticProgressCustomFieldImpl, CheckboxCustomFieldImpl, CurrencyCustomFieldImpl, CustomFieldImpl, DateCustomFieldImpl, EmailCustomFieldImpl, EmojiCustomFieldImpl, LabelsCustomFieldImpl, LocationCustomFieldImpl, ManualProgressCustomFieldImpl, NumberCustomFieldImpl, PhoneCustomFieldImpl, ShortTextCustomFieldImpl, TasksCustomFieldImpl, TextCustomFieldImpl, URLCustomFieldImpl, UsersCustomFieldImpl

public interface ICustomField
Interface for custom fields. All custom fields class extend this, and may have more methods.
  • Method Details

    • getId

      String getId()
      Returns the ID of the custom field.
      Returns:
      an ID of the custom field
    • getName

      String getName()
      Returns the name of this Custom Field, which is displayed to the user.
      Returns:
      the name of this Custom Field
    • getValue

      Object getValue()
      Returns the value of this custom field.

      It's highly recommended to cast this value to the appropriate type, because it returns more appropriate data. For example, if the custom field is of type CustomFieldType.TEXT, you can cast the value to TextCustomField, this class can be found using CustomFieldType.getAssociatedClass().

      This will be null under the following circumstances:

      • No value is specified.
      • The task response did not contain a value. Notably when an individual task is retrieved.
      Returns:
      the value of this custom field
    • getType

      CustomFieldType getType()
      Returns the type of this custom field. This will be one of CustomFieldType.
      Returns:
      the type of this custom field
    • getTimeCreated

      OffsetDateTime getTimeCreated()
      Returns when this custom field was created.
      Returns:
      when this custom field was created
    • isRequired

      boolean isRequired()
      Whether this is a required field. Unlike the name implies, getValue() may still be null..

      This feature is exclusive to the Business plan or above, so this is likely to be false.

      Returns:
      if this is a required custom field.
    • getClickUp4j

      ClickUp4j getClickUp4j()
      Returns this ClickUp4j instance.
      Returns:
      this ClickUp4j instance