[ 
https://issues.apache.org/jira/browse/ISIS-970?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dan Haywood updated ISIS-970:
-----------------------------
    Description: 
specifically:
{code}
@DomainObject(
    auditingPolicy = ENABLED|DISABLED|AS_CONFIGURED     // instead of @Audited
    publishingPayloadFactory = SomePayloadFactory.class // instead of 
@PublishedObject
    autoCompleteRepository = SomeRepository.class       // instead of 
@AutoComplete(repository=...)
    autoCompleteAction = "autoComplete"                 // instead of 
@AutoComplete(action=...)
    bounded = true|false                                // instead of @Bounded. 
 takes precedence over autoComplete
    editPolicy = ENABLED | DISABLED | AS_CONFIGURED     // instead of @Immutable
    objectType = "CUS"                                  // instead of 
@ObjectType
    viewModel = true|false                              // instead of 
@ViewModel, defaults to false
)
{code}
and
{code}
@Property(
    interaction = ToDoItem.DueBy.class        // instead of @PropertyInteraction
    hidden = Where.NOWHERE etc                // instead of @Hidden(where=...); 
ignore the When enum
    disabled = Where.OBJECT_FORMS etc.        // instead of 
@Disabled(where=...); ignore the When enum
    disabledReason = "..."                    // instead of 
@Disabled(reason=...)
    maxLength = 20                            // instead of @MaxLength; default 
of -1 indicates not specified
    mustSatisfy  = {SomeSpecification.class}  // instead of @MustSatisfy
    notPersisted = true|false                 // instead of @NotPersisted; 
defaults to false
    cardinality = DEFAULT|OPTIONAL|MANDATORY  // instead of @Optional and 
@Mandatory.  
    regexPattern  = ".+\@.+"                  // instead of 
@RegEx(validation=...)
    regexPatternReplacement = "email address" // instead of @RegEx(format=...)
    regexPatternFlags = 1                     // superset of 
@RegEx(caseSensitive=...)
)
{code}
where cardinality defaults to mandatory unless Column(allowsNull="true") is set.

and
{code}
@Collection(
    interaction = ToDoItem.Dependencies.class // instead of 
@CollectionInteraction
    hidden = Where.NOWHERE etc                // instead of @Hidden(where=...); 
ignore the When enum
    disabled = Where.OBJECT_FORMS etc.        // instead of 
@Disabled(where=...); ignore the When enum
    disabledReason = "..."                    // instead of 
@Disabled(reason=...)
    typeOf = OrderLine.class                  // instead of @TypeOf
)
{code}
and
{code}
@Action(
    interaction = ToDoItem.Completed.class               // instead of 
@ActionInteraction
    hidden = Where.NOWHERE etc                           // instead of 
@Hidden(where=...); ignore the When enum
    disabled = Where.OBJECT_FORMS etc.                   // instead of 
@Disabled(where=...); ignore the When enum
    disabledReason = "..."                               // instead of 
@Disabled(reason=...)
    semantics = Semantics.SAFE etc.                      // instead of 
@ActionSemantics
    appliesToPolicy = AppliesTo.COLLECTION               // instead of @Bulk 
and @Bulk(appliesTo=...)
    commandPolicy = ENABLED|DISABLED|AS_CONFIGURED       // instead of @Command
    commandPersistence = Persistence.PERSISTED           // instead of 
@Command(persistence=...)
    commandExecuteIn = ExecuteIn.FOREGROUND              // instead of 
@Command(executeIn=...)
    publishingPayloadFactory = SomePayloadFactory.class  // instead of 
@PublishedAction
)
{code}
and
{code}
@Parameter(
    minLength   = 3                               // instead of @MinLength
    mustSatisfy = {SomeSpecification.class}       // instead of @MustSatisfy
    cardinality = DEFAULT|OPTIONAL|MANDATORY      // instead of @Optional and 
@Mandatory.  
    regexPattern  = ".+\@.+"                      // instead of 
@RegEx(validation=...)
    regexPatternReplacement = "email address"     // instead of 
@RegEx(format=...)
    regexPatternFlags = 1                         // superset of 
@RegEx(caseSensitive=...)
)    
{code}

for ISIS-964:
{code}
@DomainObjectLayout {
    bookmarkable = BookmarkPolicy.ROOT       // or CHILD
}
{code}



This would result in the full complement of Isis annotations being:
- @DomainService  and @DomainServiceLayout
- @DomainObject  and @DomainObjectLayout
- @Property   and @PropertyLayout
- @Collection and @CollectionLayout
- @Action and @ActionLayout
- @Parameter and @ParameterLayout

Also two further additional UI hints:
- @Title
- @MemberGroupLayout

All the above @XxxLayout annotations can instead be specified using a 
.layout.json file.

The following 3rd-party annotations also supported:
- @javax.validation.constraints.Digits
- @javax.enterprise.context.RequestScoped    
- @javax.jdo.annotations.*

~~~
Need to decide what to do with remaining annotations (mostly pertaining to 
value types and other DDD ideas); remove or keep?  They are:
- @Value
- @Defaulted
- @Encodeable
- @EqualByContent
- @Parseable
- @Aggregated
- @NotPersistable
- @Facets


  was:
specifically:
{code}
@DomainObject(
    auditingPolicy     = ENABLED|DISABLED|AS_CONFIGURED  // replaces @Audited
    publishingPayloadFactory = SomePayloadFactory.class  // replaces 
@PublishedObject; possibly factor out PayloadFactory.Default so similar to 
interaction
    autoCompleteRepository = SomeRepository.class  // instead of 
@AutoComplete(repository=...)
    autoCompleteAction = "autoComplete"                      // instead of 
@AutoComplete(action=...)
    bounded      = true|false                // instead of @Bounded.  takes 
precedence over autoComplete
    editPolicy = ENABLED | DISABLED | AS_CONFIGURED // replaces @Immutable
    objectType   = "CUS"                      // instead of @ObjectType
    viewModel    = true|false                // instead of @ViewModel, defaults 
to false
)
{code}
and
{code}
@Property(
    interaction    = ToDoItem.DueBy.class   // instead of @PropertyInteraction; 
PropertyInteractionEvent.Default.class for default
    hidden          = Where.NO_WHERE etc             // instead of @Hidden; 
ignore the When enum
    disabled       = Where.OBJECT_FORMS etc.   // instead of @Disabled; ignore 
the When enum
    disabledReason = "..."                                        // optional, 
representing @Disabled(reason=...)
    maxLength    = 20                                               // instead 
of @MaxLength; default of -1 indicates not specified
    mustSatisfy  = {SomeSpecification.class}        // instead of @MustSatisfy
    notPersisted = true|false                                    // instead of 
@NotPersisted; defaults to false
    cardinality     = DEFAULT|OPTIONAL|MANDATORY    // instead of @Optional and 
@Mandatory.  Defaults to mandatory unless Column(allowsNull="true") is set.
    regexPattern  = ".+\@.+"                  // corresponds to 
@RegEx(validation=...)
    regexPatternReplacement = "email address"  // corresponds to 
@RegEx(format=...)
    regexPatternFlags = 1            // superset of @RegEx(caseSensitive=...)
)
{code}
and
{code}
@Collection(
    interaction =  ToDoItem.Dependencies.class   // instead of 
@CollectionInteraction; CollectionInteractionEvent.Default.class for default
    hidden          = Where.NO_WHERE etc             // instead of @Hidden; 
ignore the When enum
    disabled       = Where.OBJECT_FORMS etc.   // instead of @Disabled; ignore 
the When enum
    disabledReason = "..."                                        // optional, 
representing @Disabled(reason=...)
    typeOf=            = OrderLine.class                      // instead of 
@TypeOf
)
{code}
and
{code}
@Action(
    interaction        = ToDoItem.Completed.class  // instead of 
@ActionInteraction; ActionInteractionEvent.Default.class for default
    hidden          = Where.NO_WHERE etc             // instead of @Hidden; 
ignore the When enum
    disabled       = Where.OBJECT_FORMS etc.   // instead of @Disabled; ignore 
the When enum
    disabledReason = "..."                                        // optional, 
representing @Disabled(reason=...)
    semantics          = Semantics.SAFE etc.           // instead of 
@ActionSemantics
    appliesToPolicy      = AppliesTo.COLLECTION    // or BULK_AND_REGULAR
    commandPolicy   = ENABLED|DISABLED|AS_CONFIGURED    // instead of @Command
    commandPersistence = Persistence.PERSISTED     // instead of 
@Command(persistence=...)
    commandExecuteIn   = ExecuteIn.FOREGROUND      // instead of 
@Command(executeIn=...)
    publishingPayloadFactory     = SomePayloadFactory.class  // instead of 
@PublishedAction; probably factor out PayloadFactory.Default so similar to 
interaction
)
{code}
and
{code}
@Parameter(
    minLength   = 3                                                  // instead 
of @MinLength
    mustSatisfy = {SomeSpecification.class}        // instead of @MustSatisfy
    cardinality     = DEFAULT|OPTIONAL|MANDATORY    // instead of @Optional
    regexPattern  = ".+\@.+"                  // corresponds to 
@RegEx(validation=...)
    regexPatternReplacement = "email address"  // corresponds to 
@RegEx(format=...)
    regexPatternFlags = 1            // superset of @RegEx(caseSensitive=...)
)    
{code}

for ISIS-964:
{code}
@DomainObjectLayout {
    bookmarkable = BookmarkPolicy.ROOT       // or CHILD
}
{code}



This would result in the full complement of Isis annotations being:
- @DomainService  and @DomainServiceLayout
- @DomainObject  and @DomainObjectLayout
- @Property   and @PropertyLayout
- @Collection and @CollectionLayout
- @Action and @ActionLayout
- @Parameter and @ParameterLayout

Also two further additional UI hints:
- @Title
- @MemberGroupLayout

All the above @XxxLayout annotations can instead be specified using a 
.layout.json file.

The following 3rd-party annotations also supported:
- @javax.validation.constraints.Digits
- @javax.enterprise.context.RequestScoped    
- @javax.jdo.annotations.*

~~~
Need to decide what to do with remaining annotations (mostly pertaining to 
value types and other DDD ideas); remove or keep?  They are:
- @Value
- @Defaulted
- @Encodeable
- @EqualByContent
- @Parseable
- @Aggregated
- @NotPersistable
- @Facets



> Introduce new annotations to collect together all non-UI (layout) hints, and 
> deprecate old annotations
> ------------------------------------------------------------------------------------------------------
>
>                 Key: ISIS-970
>                 URL: https://issues.apache.org/jira/browse/ISIS-970
>             Project: Isis
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: core-1.7.0
>            Reporter: Dan Haywood
>            Assignee: Dan Haywood
>             Fix For: core-1.8.0
>
>
> specifically:
> {code}
> @DomainObject(
>     auditingPolicy = ENABLED|DISABLED|AS_CONFIGURED     // instead of @Audited
>     publishingPayloadFactory = SomePayloadFactory.class // instead of 
> @PublishedObject
>     autoCompleteRepository = SomeRepository.class       // instead of 
> @AutoComplete(repository=...)
>     autoCompleteAction = "autoComplete"                 // instead of 
> @AutoComplete(action=...)
>     bounded = true|false                                // instead of 
> @Bounded.  takes precedence over autoComplete
>     editPolicy = ENABLED | DISABLED | AS_CONFIGURED     // instead of 
> @Immutable
>     objectType = "CUS"                                  // instead of 
> @ObjectType
>     viewModel = true|false                              // instead of 
> @ViewModel, defaults to false
> )
> {code}
> and
> {code}
> @Property(
>     interaction = ToDoItem.DueBy.class        // instead of 
> @PropertyInteraction
>     hidden = Where.NOWHERE etc                // instead of 
> @Hidden(where=...); ignore the When enum
>     disabled = Where.OBJECT_FORMS etc.        // instead of 
> @Disabled(where=...); ignore the When enum
>     disabledReason = "..."                    // instead of 
> @Disabled(reason=...)
>     maxLength = 20                            // instead of @MaxLength; 
> default of -1 indicates not specified
>     mustSatisfy  = {SomeSpecification.class}  // instead of @MustSatisfy
>     notPersisted = true|false                 // instead of @NotPersisted; 
> defaults to false
>     cardinality = DEFAULT|OPTIONAL|MANDATORY  // instead of @Optional and 
> @Mandatory.  
>     regexPattern  = ".+\@.+"                  // instead of 
> @RegEx(validation=...)
>     regexPatternReplacement = "email address" // instead of @RegEx(format=...)
>     regexPatternFlags = 1                     // superset of 
> @RegEx(caseSensitive=...)
> )
> {code}
> where cardinality defaults to mandatory unless Column(allowsNull="true") is 
> set.
> and
> {code}
> @Collection(
>     interaction = ToDoItem.Dependencies.class // instead of 
> @CollectionInteraction
>     hidden = Where.NOWHERE etc                // instead of 
> @Hidden(where=...); ignore the When enum
>     disabled = Where.OBJECT_FORMS etc.        // instead of 
> @Disabled(where=...); ignore the When enum
>     disabledReason = "..."                    // instead of 
> @Disabled(reason=...)
>     typeOf = OrderLine.class                  // instead of @TypeOf
> )
> {code}
> and
> {code}
> @Action(
>     interaction = ToDoItem.Completed.class               // instead of 
> @ActionInteraction
>     hidden = Where.NOWHERE etc                           // instead of 
> @Hidden(where=...); ignore the When enum
>     disabled = Where.OBJECT_FORMS etc.                   // instead of 
> @Disabled(where=...); ignore the When enum
>     disabledReason = "..."                               // instead of 
> @Disabled(reason=...)
>     semantics = Semantics.SAFE etc.                      // instead of 
> @ActionSemantics
>     appliesToPolicy = AppliesTo.COLLECTION               // instead of @Bulk 
> and @Bulk(appliesTo=...)
>     commandPolicy = ENABLED|DISABLED|AS_CONFIGURED       // instead of 
> @Command
>     commandPersistence = Persistence.PERSISTED           // instead of 
> @Command(persistence=...)
>     commandExecuteIn = ExecuteIn.FOREGROUND              // instead of 
> @Command(executeIn=...)
>     publishingPayloadFactory = SomePayloadFactory.class  // instead of 
> @PublishedAction
> )
> {code}
> and
> {code}
> @Parameter(
>     minLength   = 3                               // instead of @MinLength
>     mustSatisfy = {SomeSpecification.class}       // instead of @MustSatisfy
>     cardinality = DEFAULT|OPTIONAL|MANDATORY      // instead of @Optional and 
> @Mandatory.  
>     regexPattern  = ".+\@.+"                      // instead of 
> @RegEx(validation=...)
>     regexPatternReplacement = "email address"     // instead of 
> @RegEx(format=...)
>     regexPatternFlags = 1                         // superset of 
> @RegEx(caseSensitive=...)
> )    
> {code}
> for ISIS-964:
> {code}
> @DomainObjectLayout {
>     bookmarkable = BookmarkPolicy.ROOT       // or CHILD
> }
> {code}
> This would result in the full complement of Isis annotations being:
> - @DomainService  and @DomainServiceLayout
> - @DomainObject  and @DomainObjectLayout
> - @Property   and @PropertyLayout
> - @Collection and @CollectionLayout
> - @Action and @ActionLayout
> - @Parameter and @ParameterLayout
> Also two further additional UI hints:
> - @Title
> - @MemberGroupLayout
> All the above @XxxLayout annotations can instead be specified using a 
> .layout.json file.
> The following 3rd-party annotations also supported:
> - @javax.validation.constraints.Digits
> - @javax.enterprise.context.RequestScoped    
> - @javax.jdo.annotations.*
> ~~~
> Need to decide what to do with remaining annotations (mostly pertaining to 
> value types and other DDD ideas); remove or keep?  They are:
> - @Value
> - @Defaulted
> - @Encodeable
> - @EqualByContent
> - @Parseable
> - @Aggregated
> - @NotPersistable
> - @Facets



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to