public Collection<Binding> wire(final BindingContext context) { final List<Field> actions = context.getAnnotatedFields(EnabledIf.class); final List<Binding> bindings = Lists.newArrayList(); for (final Field field : actions) { final EnabledIf action = field.getAnnotation(EnabledIf.class); final String to = action.to(); final boolean invert = (action.type() == Type.INVERTED); try { bindings.addAll(wire(to, field, context, invert)); } catch (final Exception e) { throw new BindingException("could not wire up @EnabledIf on " + field.getName(), e); } } return bindings; }