Errai 3.0.1-SNAPSHOT

org.jboss.errai.bus.server.annotations
Annotation Type Remote


@Retention(value=RUNTIME)
@Target(value=TYPE)
public @interface Remote

Indicates that the annotated interface specifies the contract for a remote service.

Usage notes: The most common way of invoking a remote service is via the Caller facility in ErraiIOC:

     @Remote
     public class MyService {
       void serviceMethod();
     }

     public class ClientClass {
       @Inject
       private Caller<MyService> myService;

       ...

       private void callRemoteService() {
         myService.call(new RemoteCallback() { ... }).serviceMethod();
       }
     }
 

Another mechanism for invoking a remote service is the MessageBuilder.createCall() API.


Errai 3.0.1-SNAPSHOT

Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.