Skip to content

Instantly share code, notes, and snippets.

View mikebrock's full-sized avatar

mikebrock

  • Square
  • Toronto, Ontario, Canada
View GitHub Profile
@StyleBinding
@Retention(RetentionPolicy.RUNTIME)
public @interface Admin {
}
@StyleBinding
@Retention(RetentionPolicy.RUNTIME)
public @interface Admin {
}
@Templated
public class StyleBoundTemplate extends Composite {
@Inject @AutoBound DataBinder<TestModel> dataBinder;
@Inject @Bound @AdminBinding @DataField private Label testA;
@Inject @Bound @TestBinding @DataField private Label testB;
public Label getTestA() {
return testA;
}
String[] array = new String[] { "a", "b", "c" };
List<String> stringList = new ArrayList<String>();
Collections.addAll(stringList, array);
Foo foo = new Foo();
new MyInterfaceImpl().doSomething("foo", foo);
@Timed(type = TimerType.REPEATING, interval = 1, timeUnit = TimeUnit.SECONDS)
private void updateTime() {
timeWidget.setTime(System.currentTimeMillis);
}
@Timed(type = TimerType.REPEATING, interval = 1, timeUnit = TimeUnit.SECONDS)
private void updateTime() {
timeWidget.setTime(System.currentTimeMillis);
}
final AsyncBeanQuery beanQuery = new AsyncBeanQuery();
final AsyncBeanFuture<FoobieScopedBean> foobieScopedFuture1 = beanQuery.load(FoobieScopedBean.class);
final AsyncBeanFuture<FoobieScopedBean> foobieScopedFuture2 = beanQuery.load(FoobieScopedBean.class);
final AsyncBeanFuture<FoobieScopedOverriddenBean> foobieScopedOverriddenFuture1
= beanQuery.load(FoobieScopedOverriddenBean.class);
final AsyncBeanFuture<FoobieScopedOverriddenBean> foobieScopedOverriddenFuture2
= beanQuery.load(FoobieScopedOverriddenBean.class);
beanQuery.query(new Runnable() {
@Override
final AsyncBeanQuery beanQuery = new AsyncBeanQuery();
final AsyncBeanFuture<FoobieScopedBean> foobieScopedFuture1 = beanQuery.load(FoobieScopedBean.class);
final AsyncBeanFuture<FoobieScopedBean> foobieScopedFuture2 = beanQuery.load(FoobieScopedBean.class);
final AsyncBeanFuture<FoobieScopedOverriddenBean> foobieScopedOverriddenFuture1
= beanQuery.load(FoobieScopedOverriddenBean.class);
final AsyncBeanFuture<FoobieScopedOverriddenBean> foobieScopedOverriddenFuture2
= beanQuery.load(FoobieScopedOverriddenBean.class);
beanQuery.query(new Runnable() {
@Override
errai.bus.enable_clustering=true
errai.bus.clustering_provider=org.jboss.errai.bus.server.cluster.jgroups.JGroupsClusteringProvider
/**
* @author Mike Brock
*/
public enum ClusterCommands {
/**
* The <tt>WhoHandles</tt> verb is a broadcast message to the cluster that asks all buses who is
* responsible for handling the specified session.
*/
WhoHandles,