Package io.micronaut.controlpanel.ui
Record Class Model
java.lang.Object
java.lang.Record
io.micronaut.controlpanel.ui.Model
- Record Components:
categories- The available categories.applicationName- The application name.activeEnvironments- The active environments.contentView- The content view.canRefresh- Whether the host application can be refreshed.canStop- Whether the host application can be stopped.ext- Any additional data to be passed to the view.
public record Model(List<ControlPanel.Category> categories, String applicationName, Set<String> activeEnvironments, io.micronaut.controlpanel.ui.Model.ContentView contentView, boolean canRefresh, boolean canStop, Map<String,Object> ext)
extends Record
Model to be passed to the view for rendering.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theactiveEnvironmentsrecord component.Returns the value of theapplicationNamerecord component.booleanReturns the value of thecanRefreshrecord component.booleancanStop()Returns the value of thecanStoprecord component.Returns the value of thecategoriesrecord component.io.micronaut.controlpanel.ui.Model.ContentViewReturns the value of thecontentViewrecord component.final booleanIndicates whether some other object is "equal to" this one.ext()Returns the value of theextrecord component.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Model
public Model(List<ControlPanel.Category> categories, String applicationName, Set<String> activeEnvironments, io.micronaut.controlpanel.ui.Model.ContentView contentView, boolean canRefresh, boolean canStop, Map<String, Object> ext) Creates an instance of aModelrecord class.- Parameters:
categories- the value for thecategoriesrecord componentapplicationName- the value for theapplicationNamerecord componentactiveEnvironments- the value for theactiveEnvironmentsrecord componentcontentView- the value for thecontentViewrecord componentcanRefresh- the value for thecanRefreshrecord componentcanStop- the value for thecanStoprecord componentext- the value for theextrecord component
-
-
Method Details
-
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. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
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 withObjects::equals(Object,Object); primitive components are compared with '=='. -
categories
Returns the value of thecategoriesrecord component.- Returns:
- the value of the
categoriesrecord component
-
applicationName
Returns the value of theapplicationNamerecord component.- Returns:
- the value of the
applicationNamerecord component
-
activeEnvironments
Returns the value of theactiveEnvironmentsrecord component.- Returns:
- the value of the
activeEnvironmentsrecord component
-
contentView
public io.micronaut.controlpanel.ui.Model.ContentView contentView()Returns the value of thecontentViewrecord component.- Returns:
- the value of the
contentViewrecord component
-
canRefresh
public boolean canRefresh()Returns the value of thecanRefreshrecord component.- Returns:
- the value of the
canRefreshrecord component
-
canStop
public boolean canStop()Returns the value of thecanStoprecord component.- Returns:
- the value of the
canStoprecord component
-
ext
Returns the value of theextrecord component.- Returns:
- the value of the
extrecord component
-