question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

@ClientCallable should support return values

See original GitHub issue

Given

@ClientCallable
public void removeTodo(int index, String text) {
...
}

I really want to be able to provide information back to the client about whether the item was deleted, or if e.g. an optimistic locking / merge conflict occurred. The logical way would be

@ClientCallable
public boolean removeTodo(int index, String text) {

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
Legiothcommented, May 3, 2018

On the client side, one quite obvious API approach would be that element.$server.foo(1, "foo") returns a Promise.

0reactions
Legiothcommented, Nov 8, 2019

This feature barely missed the train for Vaadin 14.1. It will be in Vaadin 14.2 that will be released at some point in the beginning of next year.

Read more comments on GitHub >

github_iconTop Results From Across the Web

client callable script include for field value - ServiceNow
In client callable script include function use GlideRecord query on table 'Maintain' and get the no of records assigned to passed parameter ...
Read more >
Remote Procedure Calls | Manipulating DOM with Element API
If the return value is a JavaScript Promise , then a return value will be sent to the server only when the Promise...
Read more >
Client & Server Code in One UI Action - ServiceNow Guru
//Get the values from the Incident Table so we can write-back to it. Done in server side code now. var comments = g_form.getValue('comments');...
Read more >
AutomationPeer.GetFlowsToCore Method (Microsoft.UI.Xaml ...
... an associated UI Automation client-callable method. You can override any of the "Core" methods to return alternative values in a custom automation...
Read more >
Vaadin 18 | Need to pass a message from client to server ...
And then the <vaadin-horizontal-layout> instance would get the $server. ... ClientCallable; import com.vaadin.flow.component.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found