Class HtmlField

java.lang.Object
jp.ecuacion.splib.web.bean.HtmlField
Direct Known Subclasses:
HtmlFieldNumber, HtmlFieldString

public class HtmlField extends Object
Stores attributes of each html component which controls the behiviors of it in html pages.

It is named with "field" because it's name is defined in the "field" format like "mailAddress".

  • Field Details

    • id

      @Nonnull protected String id
      Is an ID which the root record name plus dot (like "acc.") is removed from the itemId.

      When you treat the field in the record belonging to the root record, you need to define it like childRecord.childFieldName.

      It is required if you construct this class.

    • displayNameId

      protected String displayNameId
      Is an ID to the display name of the field.

      The display name can be obtained by referring field_names.properties with it.

    • isNotEmpty

      Shows whether the field allows empty.

      When this value is true, required validation is executed on server side, and shows "required" mark on the component in the html page.

      It doesn't depend on the data type.

      The default value is preset: false. So the value becomes false if you don't have to set this value.

  • Constructor Details

    • HtmlField

      public HtmlField(String id)
      Constructs a new instance with ID.
      Parameters:
      id - fieldId
  • Method Details

    • getId

      public String getId()
    • displayNameId

      public HtmlField displayNameId(String displayNameId)
    • getDisplayNameId

      public String getDisplayNameId()
      Returns displayNameId value if it's not null, and
      Returns:
    • isNotEmpty

      public HtmlField isNotEmpty(boolean isNotEmpty)
    • isNotEmpty

      public HtmlField isNotEmpty(HtmlField.HtmlFieldConditionKeyEnum authKind, String authString, boolean isNotEmpty)
      複数登録する場合は、登録順序に意味がある。先に登録されたものから順に検証し、当てはまればその値を使用する。
    • getIsNotEmpty

      public boolean getIsNotEmpty(String loginState, SplibSecurityUtil.RolesAndAuthoritiesBean bean)