Class FieldLayoutImpl

java.lang.Object
com.atlassian.jira.issue.fields.screen.AbstractGVBean
com.atlassian.jira.issue.fields.layout.field.FieldLayoutImpl
All Implemented Interfaces:
FieldLayout
Direct Known Subclasses:
EditableDefaultFieldLayoutImpl

public class FieldLayoutImpl extends AbstractGVBean implements FieldLayout
  • Field Details

  • Constructor Details

    • FieldLayoutImpl

      public FieldLayoutImpl(org.ofbiz.core.entity.GenericValue genericValue, List<FieldLayoutItem> fieldLayoutItems)
  • Method Details

    • init

      protected void init()
      Specified by:
      init in class AbstractGVBean
    • getId

      public Long getId()
      Description copied from interface: FieldLayout
      The id of the field configuration.
      Specified by:
      getId in interface FieldLayout
      Returns:
      the id
    • getName

      public String getName()
      Description copied from interface: FieldLayout
      The name of the field configuration
      Specified by:
      getName in interface FieldLayout
      Returns:
      the name
    • getDescription

      public String getDescription()
      Description copied from interface: FieldLayout
      The description of the field configuration.
      Specified by:
      getDescription in interface FieldLayout
      Returns:
      the description
    • getType

      public String getType()
    • isDefault

      public boolean isDefault()
      Description copied from interface: FieldLayout
      Returns true if this is the default FieldLayout. This means that the "type" field holds "value".
      Specified by:
      isDefault in interface FieldLayout
      Returns:
      true if this is the default FieldLayout.
    • setId

      protected void setId(Long id)
    • setInternalName

      protected void setInternalName(String name)
    • setInternalDescription

      protected void setInternalDescription(String description)
    • getFieldLayoutItems

      public List<FieldLayoutItem> getFieldLayoutItems()
      Description copied from interface: FieldLayout
      A list of field layout item of this field configuration.
      Specified by:
      getFieldLayoutItems in interface FieldLayout
      Returns:
      a list of field layout items of this field configuration.
    • getFieldLayoutItem

      public FieldLayoutItem getFieldLayoutItem(OrderableField orderableField)
      Description copied from interface: FieldLayout
      Returns the field layout item for a given orderable field, if this orderable field is part of this field configuration.
      Specified by:
      getFieldLayoutItem in interface FieldLayout
      Parameters:
      orderableField - the orderable field to find in this field configuration.
      Returns:
      the field layout item if this field is part of this field configuration, otherwise null.
    • getFieldLayoutItem

      public FieldLayoutItem getFieldLayoutItem(String fieldId)
      Description copied from interface: FieldLayout
      Returns the field layout item for a given field if, if this field is part of this field configuration.
      Specified by:
      getFieldLayoutItem in interface FieldLayout
      Parameters:
      fieldId - the id of the field.
      Returns:
      the field layout item if this field is part of this field configuration, otherwise null.
    • getVisibleLayoutItems

      public List<FieldLayoutItem> getVisibleLayoutItems(Project project, List<String> issueTypes)
      Description copied from interface: FieldLayout
      Returns all visible field layout items (system fields and custom fields) for a given project and issue type(s).
      Specified by:
      getVisibleLayoutItems in interface FieldLayout
      Parameters:
      project - the project
      issueTypes - a list of issue types to use when checking for VISIBLE CUSTOM FIELDS.
      Returns:
      all visible field layout items for the given project and it's issue type(s).
    • getVisibleLayoutItems

      public List<FieldLayoutItem> getVisibleLayoutItems(ApplicationUser remoteUser, Project project, List<String> issueTypes)
      Description copied from interface: FieldLayout
      Returns all visible field layout items (system fields and custom fields) for a given project and issue type(s).
      Specified by:
      getVisibleLayoutItems in interface FieldLayout
      Parameters:
      remoteUser - the user TODO: User is not used! We should remove it!
      project - the project
      issueTypes - a list of issue types to use when checking for VISIBLE CUSTOM FIELDS.
      Returns:
      all visible field layout items for the given project and it's issue type(s).
    • getVisibleCustomFieldLayoutItems

      public List<FieldLayoutItem> getVisibleCustomFieldLayoutItems(Project project, List<String> issueTypes)
      Description copied from interface: FieldLayout
      Returns the list of Custom Fields in this Field Layout that are both visible and applicable to the given context (of project and Issue types).
      Specified by:
      getVisibleCustomFieldLayoutItems in interface FieldLayout
      Parameters:
      project - The project context
      issueTypes - The Issue Types for context
      Returns:
      the list of visible Custom Fields applicable to the given context (of project and Issue types).
    • getHiddenFields

      public List<Field> getHiddenFields(Project project, List<String> issueTypeIds)
      Description copied from interface: FieldLayout
      Returns all hidden fields (system fields and custom fields) for a given project and issue type(s).
      Specified by:
      getHiddenFields in interface FieldLayout
      Parameters:
      project - the project
      issueTypeIds - issueTypes a list of issue types to use when checking for HIDDEN CUSTOM FIELDS.
      Returns:
      all hidden fields (system fields and custom fields).
    • getFieldManager

      protected FieldManager getFieldManager()
    • getHackyFieldRendererRegistry

      protected HackyFieldRendererRegistry getHackyFieldRendererRegistry()
    • getRequiredFieldLayoutItems

      public List<FieldLayoutItem> getRequiredFieldLayoutItems(Project project, List<String> issueTypes)
      Description copied from interface: FieldLayout
      Returns the list of required fields for an issue type in a project.
      Specified by:
      getRequiredFieldLayoutItems in interface FieldLayout
      Parameters:
      project - the project
      issueTypes - the issue type.
      Returns:
      the list of required fields. System fields and custom fields.
    • isFieldHidden

      public boolean isFieldHidden(String fieldId)
      Description copied from interface: FieldLayout
      Checks if a field is hidden in this field configuration.
      Specified by:
      isFieldHidden in interface FieldLayout
      Parameters:
      fieldId - the field id.
      Returns:
      true if the field is hidden, otherwise false.
    • getRendererTypeForField

      public String getRendererTypeForField(String fieldId)
      Description copied from interface: FieldLayout
      Returns the render type for a given field in this field configuration.
      Specified by:
      getRendererTypeForField in interface FieldLayout
      Parameters:
      fieldId - the id of the field.
      Returns:
      the type of the renderer e.g. DefaultTextRenderer.RENDERER_TYPE ("jira-text-renderer")
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getInternalList

      protected List<FieldLayoutItem> getInternalList()