Record Class MenuAction
java.lang.Object
java.lang.Record
org.apache.causeway.viewer.commons.applib.services.menu.model.MenuAction
- All Implemented Interfaces:
Serializable,MenuEntry
public record MenuAction(@NonNull org.apache.causeway.applib.services.bookmark.Bookmark serviceBookmark, @NonNull org.apache.causeway.applib.Identifier actionId, @NonNull String name, String cssClassFa)
extends Record
implements MenuEntry
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionMenuAction(@NonNull org.apache.causeway.applib.services.bookmark.Bookmark serviceBookmark, @NonNull org.apache.causeway.applib.Identifier actionId, @NonNull String name, String cssClassFa) Creates an instance of aMenuActionrecord class. -
Method Summary
Modifier and TypeMethodDescription@NonNull org.apache.causeway.applib.IdentifieractionId()Returns the value of theactionIdrecord component.Returns the value of thecssClassFarecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Optional<org.apache.causeway.core.metamodel.interactions.managed.ManagedAction>@NonNull Stringname()Returns the value of thenamerecord component.static MenuActionof(@NonNull org.apache.causeway.core.metamodel.interactions.managed.ManagedAction managedAction) @NonNull org.apache.causeway.applib.services.bookmark.BookmarkReturns the value of theserviceBookmarkrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
MenuAction
public MenuAction(@NonNull @NonNull org.apache.causeway.applib.services.bookmark.Bookmark serviceBookmark, @NonNull @NonNull org.apache.causeway.applib.Identifier actionId, @NonNull @NonNull String name, @Nullable String cssClassFa) Creates an instance of aMenuActionrecord class.- Parameters:
serviceBookmark- the value for theserviceBookmarkrecord componentactionId- the value for theactionIdrecord componentname- the value for thenamerecord componentcssClassFa- the value for thecssClassFarecord component
-
-
Method Details
-
of
public static MenuAction of(@NonNull @NonNull org.apache.causeway.core.metamodel.interactions.managed.ManagedAction managedAction) -
managedAction
public Optional<org.apache.causeway.core.metamodel.interactions.managed.ManagedAction> managedAction() -
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
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. All components in this record class are compared withObjects::equals(Object,Object). -
serviceBookmark
Returns the value of theserviceBookmarkrecord component.- Returns:
- the value of the
serviceBookmarkrecord component
-
actionId
Returns the value of theactionIdrecord component.- Returns:
- the value of the
actionIdrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
cssClassFa
Returns the value of thecssClassFarecord component.- Returns:
- the value of the
cssClassFarecord component
-