Possibility of calling my static java method(and passing arguments ) in Ui binder (xml) [duplicate]

StackOverflow https://stackoverflow.com/questions/15156232

  •  16-03-2022
  •  | 
  •  

Вопрос

Is there a way pass arguments to java methods? Inside the Ui binder I imported class like below

<ui:with type="com..myproject.MyUtil" field="util"/>

I am calling a normal static method like

<g:Label text="{util.getEditInfoString}" ui:field="editInfo" />

I wrote my business logic in getEditInfoString() method and returns string,Which is working like a charm .

Now I have an requirement that need to pass one argument(string) to that method from my binder file .

What is the way to do that ??any hints ??

Thanks.

Это было полезно?

Решение

there is no support for argument passing. only methods without arguments can be invoked

Refer FieldReferenceConverter

gwt uibinder ui:with - calling methods with arguments

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top