Class ShellMessageBuilder<T>
java.lang.Object
org.springframework.shell.component.message.ShellMessageBuilder<T>
- Type Parameters:
T
- the payload type.
Shell spesific message builder.
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.messaging.Message<T>
build()
static org.springframework.messaging.Message<String>
Create ainterrupt
message.static org.springframework.messaging.Message<KeyEvent>
ofKeyEvent
(KeyEvent event) Create a message of aKeyEvent
.static org.springframework.messaging.Message<MouseEvent>
ofMouseEvent
(MouseEvent event) Create a message of aMouseEvent
.static org.springframework.messaging.Message<String>
ofRedraw()
Create aredraw
message.static org.springframework.messaging.Message<String>
Create asignal
message.static org.springframework.messaging.Message<?>
static org.springframework.messaging.Message<String>
ofViewFocus
(String action, View view) setEventType
(EventLoop.Type type) setPriority
(Integer priority) static <T> ShellMessageBuilder<T>
withPayload
(T payload) Create a builder for a newMessage
instance with the provided payload.
-
Method Details
-
withPayload
Create a builder for a newMessage
instance with the provided payload.- Type Parameters:
T
- The type of the payload.- Parameters:
payload
- the payload for the new message- Returns:
- A ShellMessageBuilder.
-
ofRedraw
Create aredraw
message.- Returns:
- a redraw message
-
ofInterrupt
Create ainterrupt
message.- Returns:
- a interrupt message
-
ofSignal
Create asignal
message.- Returns:
- a signal message
-
ofKeyEvent
Create a message of aKeyEvent
.- Parameters:
event
- the event type- Returns:
- a message with
KeyEvent
as a payload
-
ofMouseEvent
Create a message of aMouseEvent
.- Parameters:
event
- the event type- Returns:
- a message with
MouseEvent
as a payload
-
ofView
-
ofViewFocus
-
setPriority
-
setView
-
setEventType
-
setHeader
-
build
-