com.vaadin.flow.server.menu.

Record Class AvailableViewInfo

java.lang.Object
java.lang.Record
com.vaadin.flow.server.menu.AvailableViewInfo

Record Components:

title - title of view

rolesAllowed - logged in roles allowed for view

loginRequired - requires login

route - path string

lazy - lazy loaded

register - register view

menu - menu item information

children - view children

routeParameters - view parameters

flowLayout - if server layout should be used

All Implemented Interfaces:

Serializable

public record AvailableViewInfo(String title, String[] rolesAllowed, boolean loginRequired, String route, boolean lazy, boolean register, MenuData menu, List<AvailableViewInfo> children, Map<String,RouteParamType> routeParameters, boolean flowLayout) extends Record implements Serializable

Represents a view configuration for use with a menu.

See Also:

  • Constructor Details

    • AvailableViewInfo

      public AvailableViewInfo(String title, String[] rolesAllowed, boolean loginRequired, String route, boolean lazy, boolean register, MenuData menu, List<AvailableViewInfo> children, Map<String,RouteParamType> routeParameters, boolean flowLayout)

      Creates an instance of a AvailableViewInfo record class.

      Parameters:

      title - the value for the title record component

      rolesAllowed - the value for the rolesAllowed record component

      loginRequired - the value for the loginRequired record component

      route - the value for the route record component

      lazy - the value for the lazy record component

      register - the value for the register record component

      menu - the value for the menu record component

      children - the value for the children record component

      routeParameters - the value for the routeParameters record component

      flowLayout - the value for the flowLayout record component

  • Method Details

    • equals

      public boolean equals(Object o)

      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.

      Specified by:

      equals in class Record

      Parameters:

      o - the object with which to compare

      Returns:

      true if this object is the same as the o argument; false otherwise.

    • hashCode

      public int hashCode()

      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.

      Specified by:

      hashCode in class Record

      Returns:

      a hash code value for this object

    • toString

      public String toString()

      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.

      Specified by:

      toString in class Record

      Returns:

      a string representation of this object

    • title

      public String title()

      Returns the value of the title record component.

      Returns:

      the value of the title record component

    • rolesAllowed

      public String[] rolesAllowed()

      Returns the value of the rolesAllowed record component.

      Returns:

      the value of the rolesAllowed record component

    • loginRequired

      public boolean loginRequired()

      Returns the value of the loginRequired record component.

      Returns:

      the value of the loginRequired record component

    • route

      public String route()

      Returns the value of the route record component.

      Returns:

      the value of the route record component

    • lazy

      public boolean lazy()

      Returns the value of the lazy record component.

      Returns:

      the value of the lazy record component

    • register

      public boolean register()

      Returns the value of the register record component.

      Returns:

      the value of the register record component

    • children

      public List<AvailableViewInfo> children()

      Returns the value of the children record component.

      Returns:

      the value of the children record component

    • routeParameters

      public Map<String,RouteParamType> routeParameters()

      Returns the value of the routeParameters record component.

      Returns:

      the value of the routeParameters record component

    • flowLayout

      public boolean flowLayout()

      Returns the value of the flowLayout record component.

      Returns:

      the value of the flowLayout record component