}
@Override
public MetaRuleset createMetaRuleset(Class type)
{
MetaRuleset m = new MetaRulesetImpl(_delegate.getTag(), type);
// ignore standard component attributes
m.ignore("binding").ignore("id");
// add auto wiring for attributes
m.addRule(ComponentRule.INSTANCE);
// add special rule for passthrough attributes
m.addRule(PassthroughRuleImpl.INSTANCE);
// if it's an ActionSource
if (ActionSource.class.isAssignableFrom(type))
{
m.addRule(ActionSourceRule.INSTANCE);
}
// if it's a ValueHolder
if (ValueHolder.class.isAssignableFrom(type))
{
m.addRule(ValueHolderRule.INSTANCE);
// if it's an EditableValueHolder
if (EditableValueHolder.class.isAssignableFrom(type))
{
m.ignore("submittedValue");
m.ignore("valid");
m.addRule(EditableValueHolderRule.INSTANCE);
}
}
return m;
}