Description
eg, instead of:
@Action(semantics=SemanticsOf.SAFE)
@ActionLayout(contributed=Contributed.AS_ASSOCIATION)
@CollectionLayout(render=RenderType.EAGERLY)
public List<Foo> someFoos()
we could allow custom annotations like this to be defined:
@Action(semantics=SemanticsOf.SAFE)
@ActionLayout(contributed=Contributed.AS_ASSOCIATION)
@CollectionLayout(render=RenderType.EAGERLY)
public @interface ContributedCollection {
}
which would then allow:
@ContributedCollection
public List<Foo> someFoos() { ... }
~~~~
This might also be a good way to support value types, eg by introducing a new ValueObject and ValueObjectLayout annotations:
@ValueObject (
mustSatisfy=MoneySpec.class,
appliesTo=
)
@ValueObjectLayout(
named="Money"
)
public @interface Money {
}
and then:
public void deposit(@Money BigDecimal bd)
{ ... }Behind the scenes, Isis would just be copying facets from the ObjectSpecification that represents the @Money annotation onto the parameter or property feature..