All Manuals > LispWorks User Guide and Reference Manual > 41 The LW-JI Package

NextPrevUpTopContentsIndex

send-message-to-java-host

Function
Summary

Sends a message to the Java host.

Package

lw-ji

Signature

send-message-to-java-host message-string where-keyword => result

Arguments

message-string

A string.

where-keyword

One of the keywords :append, :add, :prepend, :add-no-scroll, :append-no-scroll and :reset.

Values

result

A boolean.

Description

The function send-message-to-java-host sends a message to the Java host. It funcalls the function that was passed as the send-message-to-java-host argument to init-java-interface, or the default function, with message-string and where-keyword.

On Android init-java-interface is given a function that ends up calling the method com.lispworks.Manager.addMessage.

The default function checks the keyword and then writes the string to cl:*terminal-io*, which is probably good enough for testing purposes.

result is t if there is a function, and nil otherwise.

Notes

The intended meanings of where-keyword are:

:reset

Erase any existing text and replace it by the message.

:prepend

Insert the message and a newline before any existing text.

:add-no-scroll

Add the message after all existing text.

:add

Like :add-no-scroll, and scroll to the beginning of the new message.

:append-no-scroll

Like :add-no-scroll, plus add a following newline.

:append

Like :append-no-scroll, and scroll to the beginning of the new message.

Compatibility note

The values :add-no-scroll and :add for where-keyword are new in LispWorks 7.1.

See also

init-java-interface
format-to-java-host


LispWorks User Guide and Reference Manual - 20 Sep 2017

NextPrevUpTopContentsIndex