You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2020/07/23 08:59:45 UTC
[isis] branch ISIS-2222 updated: ISIS-2222: adds
@Property(hidden=...)
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch ISIS-2222
in repository https://gitbox.apache.org/repos/asf/isis.git
The following commit(s) were added to refs/heads/ISIS-2222 by this push:
new 1caedf7 ISIS-2222: adds @Property(hidden=...)
1caedf7 is described below
commit 1caedf7827b0d04c829d5627aa1d5e5dd4ff0868
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jul 23 09:59:19 2020 +0100
ISIS-2222: adds @Property(hidden=...)
Also fixes up ordering of annotations for some of the @PropertyLayout's
---
.../dom/annotDomain/Property/PropertyMenu.java | 19 ++
.../dom/annotDomain/Property/hidden/.gitkeep | 0
.../hidden/HiddenEverywhereMetaAnnotation.java} | 11 +-
.../hidden/PropertyHiddenVm-description.adoc} | 56 ++----
.../Property/hidden/PropertyHiddenVm.java} | 72 ++++----
.../Property/hidden/PropertyHiddenVm.layout.xml | 48 +++++
...yHiddenVm_mixinPropertyWithMetaAnnotation.java} | 12 +-
...mixinPropertyWithMetaAnnotationOverridden.java} | 19 +-
.../hidden/PropertyHiddenVm_returnsChildren.java | 29 +++
.../child/PropertyHiddenChildVm-description.adoc | 50 +++++
.../hidden/child/PropertyHiddenChildVm.java | 201 +++++++++++++++++++++
.../hidden/child/PropertyHiddenChildVm.layout.xml | 45 +++++
.../PropertyHiddenChildVm_mixinProperty.java} | 17 +-
.../PropertyOptionalityVm-description.adoc | 2 +
.../PropertyLayout/PropertyLayoutMenu.java | 18 +-
...otation.java => CssClassRedMetaAnnotation.java} | 2 +-
.../PropertyLayoutCssClassVm-description.adoc | 2 +-
.../cssClass/PropertyLayoutCssClassVm.java | 8 +-
...CssClassVm_mixinPropertyWithMetaAnnotation.java | 4 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 4 +-
...yLayoutCssClassVm_updateWithMetaAnnotation.java | 4 +-
...ClassVm_updateWithMetaAnnotationOverridden.java | 5 +-
.../describedAs/PropertyLayoutDescribedAsVm.java | 2 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 2 +-
...bedAsVm_updateWithMetaAnnotationOverridden.java | 2 +-
.../hidden/PropertyLayoutHiddenVm-description.adoc | 7 +
.../hidden/PropertyLayoutHiddenVm.java | 4 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 4 +-
.../PropertyLayoutLabelPositionVm.java | 2 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 2 +-
...itionVm_updateWithMetaAnnotationOverridden.java | 2 +-
...otation.java => MultiLine10MetaAnnotation.java} | 2 +-
.../PropertyLayoutMultiLineVm-description.adoc | 2 +-
.../multiLine/PropertyLayoutMultiLineVm.java | 9 +-
...ultiLineVm_mixinPropertyWithMetaAnnotation.java | 4 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 5 +-
...LayoutMultiLineVm_updateWithMetaAnnotation.java | 4 +-
...iLineVm_updateWithMetaAnnotationOverridden.java | 5 +-
.../named/PropertyLayoutNamedVm.java | 2 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 2 +-
...NamedVm_updateWithMetaAnnotationOverridden.java | 2 +-
.../renderDay/PropertyLayoutRenderDayVm.java | 4 +-
...m_mixinEndDateWithMetaAnnotationOverridden.java | 2 +-
..._updateEndDateWithMetaAnnotationOverridden.java | 2 +-
.../repainting/PropertyLayoutRepaintingVm.java | 4 +-
...paintingVm_mixinPropertyWithMetaAnnotation.java | 2 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 5 +-
.../PropertyLayoutTypicalLengthVm.java | 4 +-
..._mixinPropertyWithMetaAnnotationOverridden.java | 2 +-
...engthVm_updateWithMetaAnnotationOverridden.java | 2 +-
.../src/main/java/demoapp/dom/menubars.layout.xml | 1 +
51 files changed, 555 insertions(+), 165 deletions(-)
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/PropertyMenu.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/PropertyMenu.java
index a9db7bf..21f39d1 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/PropertyMenu.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/PropertyMenu.java
@@ -35,6 +35,8 @@ import lombok.extern.log4j.Log4j2;
import demoapp.dom.annotDomain.Property.editing.PropertyEditingVm;
import demoapp.dom.annotDomain.Property.fileAccept.PropertyFileAcceptVm;
+import demoapp.dom.annotDomain.Property.hidden.PropertyHiddenVm;
+import demoapp.dom.annotDomain.Property.hidden.child.PropertyHiddenChildVm;
import demoapp.dom.annotDomain.Property.maxLength.PropertyMaxLengthVm;
import demoapp.dom.annotDomain.Property.mustSatisfy.PropertyMustSatisfyVm;
import demoapp.dom.annotDomain.Property.optionality.PropertyOptionalityVm;
@@ -70,6 +72,23 @@ public class PropertyMenu {
}
@Action(semantics = SemanticsOf.SAFE)
+ @ActionLayout(cssClassFa="fa-glasses", describedAs = "Visibility of properties, eg in tables")
+ public PropertyHiddenVm hidden() {
+ val vm = new PropertyHiddenVm();
+ vm.setPropertyHiddenAnywhere("hidden anywhere");
+ vm.setPropertyHiddenEverywhere("hidden everywhere");
+ vm.setPropertyHiddenNowhereUsingAnnotation("hidden nowhere using annotation");
+ vm.setPropertyUsingMetaAnnotation("using meta-annotation");
+ vm.setPropertyUsingMetaAnnotationButOverridden("using meta-annotation but overridden");
+
+ vm.getChildren().add(new PropertyHiddenChildVm("child 1", vm));
+ vm.getChildren().add(new PropertyHiddenChildVm("child 2", vm));
+ vm.getChildren().add(new PropertyHiddenChildVm("child 3", vm));
+ return vm;
+ }
+
+
+ @Action(semantics = SemanticsOf.SAFE)
@ActionLayout(cssClassFa="fa-ruler-horizontal", describedAs = "Length of text fields")
public PropertyMaxLengthVm maxLength(){
val vm = new PropertyMaxLengthVm();
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/.gitkeep b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/.gitkeep
deleted file mode 100644
index e69de29..0000000
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/HiddenEverywhereMetaAnnotation.java
similarity index 58%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/HiddenEverywhereMetaAnnotation.java
index 2648b57..73bbad4 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/HiddenEverywhereMetaAnnotation.java
@@ -1,4 +1,4 @@
-package demoapp.dom.annotLayout.PropertyLayout.cssClass;
+package demoapp.dom.annotDomain.Property.hidden;
import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
@@ -6,12 +6,11 @@ import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
-import org.apache.isis.applib.annotation.ParameterLayout;
-import org.apache.isis.applib.annotation.PropertyLayout;
+import org.apache.isis.applib.annotation.Property;
+import org.apache.isis.applib.annotation.Where;
//tag::class[]
-@PropertyLayout(cssClass = "red") // <.>
-@ParameterLayout(cssClass = "red") // <.>
+@Property(hidden = Where.EVERYWHERE) // <.>
@Inherited
@Target({
ElementType.METHOD, ElementType.FIELD, // <.>
@@ -19,7 +18,7 @@ import org.apache.isis.applib.annotation.PropertyLayout;
ElementType.TYPE // <.>
})
@Retention(RetentionPolicy.RUNTIME)
-public @interface CssClassMetaAnnotation {
+public @interface HiddenEverywhereMetaAnnotation {
}
//end::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm-description.adoc
similarity index 67%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm-description.adoc
index 663b578..750487c 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm-description.adoc
@@ -1,50 +1,34 @@
The `hidden` hint indicates that the property should be hidden in certain contexts.
Most commonly, this is to hide properties in tables (parented, standalone, or both).
-* for properties, the hint can be specified using either the `@PropertyLayout` annotation, or a meta-annotation, or using the `Xxx.layout.xml` layout file.
+* for properties, the hint can be specified using either the `@Property` annotation, or a meta-annotation.
-* there is equivalent for a parameter (though parameters can be hidden dynamically using a `hide...()` supporting method)
+* there is no equivalent for a parameter (though parameters can be hidden dynamically using a `hide...()` supporting method)
Because some of the `hidden` variants relate to tables, this view model has a collection of child objects with those child objects annotated to show the relevant options.
There is also an action that returns this same set of child objects as a standalone list.
+[NOTE]
+====
+It is also specify to hide properties using `@PropertyLayout`.
+This is to allow the distinction between a property that is hidden as a deep domain concept, compared to a property that is hidden in some circumstances for cosmetic UI reasons.
+
+In the user interface, the effect is the same.
+====
== Annotated
The `hidden` hint can be specified explicitly using an annotation:
-* for properties, using `@PropertyLayout#hidden()`:
+* for properties, using `@Property#hidden()`:
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm.java[tags=annotation]
+include::PropertyHiddenVm.java[tags=annotation]
----
<.> explicitly indicate that the property should be visible in all contexts.
-Note that there is no equivalent for `@ParameterLayout`.
-
-== Layout File
-
-For properties (not parameters), the `hidden` hint can be specified using the `Xxx.layout.xml` file:
-
-* property definition:
-+
-[source,java,indent=0]
-----
-include::PropertyLayoutHiddenVm.java[tags=layout-file]
-----
-<.> `hidden` hint is _not_ present.
-
-* layout file snippet:
-+
-[source,xml,indent=0,tabsize=4]
-----
-<cpt:property id="propertyHiddenNowhereUsingLayout" hidden="NOWHERE"/>
-----
-
-One advantage of the layout file over the annotation is that the layout file is dynamic: it can be modified and the changes reloaded in a running application.
-
-TIP: It is sometimes necessary to invoke the `Rebuild Metamodel` action to see this take effect.
+Note that there is no equivalent for `@Parameter`.
== Variants
@@ -83,14 +67,14 @@ The source for the `propertyHiddenNowhereUsingAnnotation` property is quoted abo
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm.java[tags=variants-everywhere]
+include::PropertyHiddenVm.java[tags=variants-everywhere]
----
* Anywhere:
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm.java[tags=variants-anywhere]
+include::PropertyHiddenVm.java[tags=variants-anywhere]
----
Neither of these properties should be visible in the UI.
@@ -115,7 +99,7 @@ include::HiddenEverywhereMetaAnnotation.java[tags=class]
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm.java[tags=meta-annotated]
+include::PropertyHiddenVm.java[tags=meta-annotated]
----
<.> hint is inherited from the meta-annotation
@@ -123,7 +107,7 @@ include::PropertyLayoutHiddenVm.java[tags=meta-annotated]
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotation.java[tags=class]
+include::PropertyHiddenVm_mixinPropertyWithMetaAnnotation.java[tags=class]
----
<.> hint is inherited from the meta-annotation
@@ -137,20 +121,20 @@ The meta-annotation can itself be overridden:
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm.java[tags=meta-annotated-overridden]
+include::PropertyHiddenVm.java[tags=meta-annotated-overridden]
----
<.> hint from meta-annotation ...
-<.> \... is overridden by the `@PropertyLayout` annotation
+<.> \... is overridden by the `@Property` annotation
* or a mixin:
+
[source,java,indent=0]
----
-include::PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java[tags=meta-annotation-overridden]
+include::PropertyHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java[tags=meta-annotation-overridden]
----
<.> hint from meta-annotation ...
-<.> \... is overridden by the `@ParameterLayout` annotation
+<.> \... is overridden by the `@Parameter` annotation
In both cases, even though the meta-annotation indicates that the property should be hidden everywhere, the override indicates that they should be hidden nowhere.
Both properties should therefore be visible in the UI.
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.java
similarity index 68%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.java
index 1f4a9c1..330121d 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package demoapp.dom.annotLayout.PropertyLayout.hidden;
+package demoapp.dom.annotDomain.Property.hidden;
import java.util.ArrayList;
import java.util.List;
@@ -43,7 +43,7 @@ import lombok.NoArgsConstructor;
import lombok.Setter;
import demoapp.dom._infra.asciidocdesc.HasAsciiDocDescription;
-import demoapp.dom.annotLayout.PropertyLayout.hidden.child.PropertyLayoutHiddenChildVm;
+import demoapp.dom.annotDomain.Property.hidden.child.PropertyHiddenChildVm;
//tag::class[]
@XmlRootElement(name = "root")
@@ -51,22 +51,23 @@ import demoapp.dom.annotLayout.PropertyLayout.hidden.child.PropertyLayoutHiddenC
@XmlAccessorType(XmlAccessType.FIELD)
@DomainObject(
nature=Nature.VIEW_MODEL,
- objectType = "demo.PropertyLayoutHiddenVm",
+ objectType = "demo.PropertyHiddenVm",
editing = Editing.ENABLED
)
@NoArgsConstructor
-public class PropertyLayoutHiddenVm implements HasAsciiDocDescription {
+public class PropertyHiddenVm implements HasAsciiDocDescription {
public String title() {
- return "PropertyLayout#hidden";
+ return "Property#hidden";
}
//tag::annotation[]
- @Property(optionality = Optionality.OPTIONAL)
- @PropertyLayout(
+ @Property(
hidden = Where.NOWHERE // <.>
- , describedAs =
- "@PropertyLayout(hidden = Where.NOWHERE)"
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.NOWHERE)"
)
@MemberOrder(name = "annotation", sequence = "1")
@XmlElement(required = false)
@@ -74,40 +75,30 @@ public class PropertyLayoutHiddenVm implements HasAsciiDocDescription {
private String propertyHiddenNowhereUsingAnnotation;
//end::annotation[]
-//tag::layout-file[]
- @Property(optionality = Optionality.OPTIONAL)
- @PropertyLayout( // <.>
- describedAs =
- "<cpt:property id=\"...\" hidden=\"NOWHERE\"/>"
- )
- @MemberOrder(name = "layout-file", sequence = "1")
- @XmlElement(required = false)
- @Getter @Setter
- private String propertyHiddenNowhereUsingLayout;
-//end::layout-file[]
-
//tag::variants-everywhere[]
- @Property(optionality = Optionality.OPTIONAL)
+ @Property(
+ hidden = Where.EVERYWHERE // <.>
+ )
@PropertyLayout(
- hidden = Where.EVERYWHERE // <.>
- , describedAs =
- "@PropertyLayout(hidden = Where.EVERYWHERE)"
+ describedAs =
+ "@Property(hidden = Where.EVERYWHERE)"
)
@MemberOrder(name = "variants", sequence = "1")
- @XmlElement(required = false)
+ @XmlElement(required = true)
@Getter @Setter
private String propertyHiddenEverywhere;
//end::variants-everywhere[]
//tag::variants-anywhere[]
- @Property(optionality = Optionality.OPTIONAL)
+ @Property(
+ hidden = Where.ANYWHERE // <.>
+ )
@PropertyLayout(
- hidden = Where.ANYWHERE // <.>
- , describedAs =
- "@PropertyLayout(hidden = Where.ANYWHERE)"
+ describedAs =
+ "@Property(hidden = Where.ANYWHERE)"
)
@MemberOrder(name = "variants", sequence = "2")
- @XmlElement(required = false)
+ @XmlElement(required = true)
@Getter @Setter
private String propertyHiddenAnywhere;
//end::variants-anywhere[]
@@ -117,32 +108,33 @@ public class PropertyLayoutHiddenVm implements HasAsciiDocDescription {
@Collection
@XmlElementWrapper(name = "children")
@XmlElement(name = "child")
- private List<PropertyLayoutHiddenChildVm> children = new ArrayList<>();
+ private List<PropertyHiddenChildVm> children = new ArrayList<>();
//end::children[]
//tag::meta-annotated[]
- @Property(optionality = Optionality.OPTIONAL)
@HiddenEverywhereMetaAnnotation // <.>
+ @Property()
@PropertyLayout(
describedAs = "@HiddenEverywhereMetaAnnotation"
)
@MemberOrder(name = "meta-annotated", sequence = "1")
- @XmlElement(required = false)
+ @XmlElement(required = true)
@Getter @Setter
private String propertyUsingMetaAnnotation;
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@HiddenEverywhereMetaAnnotation // <.>
- @PropertyLayout(
+ @Property(
hidden = Where.NOWHERE // <.>
- , describedAs =
+ )
+ @PropertyLayout(
+ describedAs =
"@HiddenEverywhereMetaAnnotation " +
- "@PropertyLayout(hidden = Where.NOWHERE)"
+ "@Property(hidden = Where.NOWHERE)"
)
- @MemberOrder(name = "meta-annotated", sequence = "2")
- @XmlElement(required = false)
+ @MemberOrder(name = "meta-annotated-overridden", sequence = "2")
+ @XmlElement(required = true)
@Getter @Setter
private String propertyUsingMetaAnnotationButOverridden;
//end::meta-annotated-overridden[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.layout.xml b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.layout.xml
new file mode 100644
index 0000000..76ccb54
--- /dev/null
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm.layout.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<bs3:grid
+ xsi:schemaLocation="http://isis.apache.org/applib/layout/component http://isis.apache.org/applib/layout/component/component.xsd http://isis.apache.org/applib/layout/grid/bootstrap3 http://isis.apache.org/applib/layout/grid/bootstrap3/bootstrap3.xsd"
+ xmlns:bs3="http://isis.apache.org/applib/layout/grid/bootstrap3"
+ xmlns:cpt="http://isis.apache.org/applib/layout/component"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+
+
+ <bs3:row>
+ <bs3:col span="10" unreferencedActions="true">
+ <cpt:domainObject />
+ <cpt:action id="rebuildMetamodel"/>
+ </bs3:col>
+ <bs3:col span="2">
+ <cpt:fieldSet name="" id="sources" />
+ </bs3:col>
+ </bs3:row>
+
+ <bs3:row>
+ <bs3:col span="6">
+ <cpt:fieldSet name="Annotated" id="annotation"/>
+ <cpt:fieldSet name="Variants" id="variants"/>
+ <cpt:fieldSet name="Contributed" id="contributed"/>
+ <cpt:fieldSet name="Meta-annotated" id="meta-annotated"/>
+ <cpt:fieldSet name="Meta-annotated Overridden" id="meta-annotated-overridden"/>
+ <cpt:fieldSet name="Other" id="other" unreferencedProperties="true"/>
+ <cpt:collection id="children">
+ <cpt:action id="returnsChildren"/>
+ </cpt:collection>
+ </bs3:col>
+ <bs3:col span="6">
+ <cpt:fieldSet name="Description" id="description" >
+ <cpt:action id="clearHints" position="PANEL" />
+ <cpt:action id="downloadLayoutXml" position="PANEL_DROPDOWN"/>
+ <cpt:action id="rebuildMetamodel" position="PANEL_DROPDOWN"/>
+ <cpt:action id="downloadMetamodelXml" position="PANEL_DROPDOWN"/>
+ <cpt:action id="inspectMetamodel" position="PANEL_DROPDOWN"/>
+ <cpt:action id="downloadJdoMetadata" position="PANEL_DROPDOWN"/>
+ <cpt:action id="openRestApi" position="PANEL_DROPDOWN" />
+ <cpt:property id="description"/>
+ </cpt:fieldSet>
+ </bs3:col>
+ </bs3:row>
+ <bs3:row>
+ <bs3:col span="12" unreferencedCollections="true"/>
+ </bs3:row>
+
+</bs3:grid>
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotation.java
similarity index 78%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotation.java
index de4c6b5..3f31d30 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotation.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package demoapp.dom.annotLayout.PropertyLayout.cssClass;
+package demoapp.dom.annotDomain.Property.hidden;
import org.apache.isis.applib.annotation.MemberOrder;
import org.apache.isis.applib.annotation.Property;
@@ -26,21 +26,21 @@ import lombok.RequiredArgsConstructor;
//tag::class[]
@Property()
-@CssClassMetaAnnotation // <.>
+@HiddenEverywhereMetaAnnotation // <.>
@PropertyLayout(
describedAs =
- "@CssClassMetaAnnotation"
+ "@HiddenEverywhereMetaAnnotation"
)
@RequiredArgsConstructor
-public class PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation {
+public class PropertyHiddenVm_mixinPropertyWithMetaAnnotation {
// ...
//end::class[]
- private final PropertyLayoutCssClassVm propertyLayoutCssClassVm;
+ private final PropertyHiddenVm propertyHiddenVm;
@MemberOrder(name = "meta-annotated", sequence = "2")
public String prop() {
- return propertyLayoutCssClassVm.getPropertyUsingAnnotation();
+ return propertyHiddenVm.getPropertyHiddenNowhereUsingAnnotation();
}
//tag::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
similarity index 75%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
index 98aad0d..9112f48 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package demoapp.dom.annotLayout.PropertyLayout.hidden;
+package demoapp.dom.annotDomain.Property.hidden;
import org.apache.isis.applib.annotation.MemberOrder;
import org.apache.isis.applib.annotation.Property;
@@ -26,24 +26,25 @@ import org.apache.isis.applib.annotation.Where;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
-@HiddenEverywhereMetaAnnotation // <.>
+@HiddenEverywhereMetaAnnotation // <.>
+@Property(
+ hidden = Where.NOWHERE // <.>
+)
@PropertyLayout(
- hidden = Where.NOWHERE // <.>
- , describedAs =
+ describedAs =
"@HiddenEverywhereMetaAnnotation " +
- "@PropertyLayout(hidden = NOWHERE)"
+ "@Property(hidden = NOWHERE)"
)
@RequiredArgsConstructor
-public class PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden {
+public class PropertyHiddenVm_mixinPropertyWithMetaAnnotationOverridden {
// ...
//end::meta-annotation-overridden[]
- private final PropertyLayoutHiddenVm propertyLayoutHiddenVm;
+ private final PropertyHiddenVm propertyHiddenVm;
@MemberOrder(name = "meta-annotated-overridden", sequence = "2")
public String prop() {
- return propertyLayoutHiddenVm.getPropertyHiddenNowhereUsingAnnotation();
+ return propertyHiddenVm.getPropertyHiddenNowhereUsingAnnotation();
}
//tag::meta-annotation-overridden[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_returnsChildren.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_returnsChildren.java
new file mode 100644
index 0000000..1952f24
--- /dev/null
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/PropertyHiddenVm_returnsChildren.java
@@ -0,0 +1,29 @@
+package demoapp.dom.annotDomain.Property.hidden;
+
+import java.util.List;
+
+import org.apache.isis.applib.annotation.Action;
+import org.apache.isis.applib.annotation.SemanticsOf;
+
+import lombok.RequiredArgsConstructor;
+
+import demoapp.dom.annotDomain.Property.hidden.child.PropertyHiddenChildVm;
+
+@Action(
+ semantics = SemanticsOf.SAFE
+)
+@RequiredArgsConstructor
+public class PropertyHiddenVm_returnsChildren {
+
+ private final PropertyHiddenVm propertyHiddenVm;
+
+//tag::meta-annotation[]
+ public List<PropertyHiddenChildVm> act() {
+ return propertyHiddenVm.getChildren();
+ }
+//end::meta-annotation[]
+ public String default0Act() {
+ return propertyHiddenVm.getPropertyUsingMetaAnnotation();
+ }
+
+}
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm-description.adoc
new file mode 100644
index 0000000..b9acb0d
--- /dev/null
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm-description.adoc
@@ -0,0 +1,50 @@
+This (child) object displays the visibility of variations of the `hidden` hint.
+
+
+.Hidden Variants
+[cols="^1m,<2m,2a",options=header,frame="all"]
+|===
+^| Where
+^| This (child) object
+^| Notes
+
+| NOWHERE
+| propertyHiddenNowhere
+| Visible at all times
+
+| EVERYWHERE
+| propertyHiddenEverywhere
+
+| Should not be visible at all.
+
+| ANYWHERE
+| propertyHiddenAnywhere
+| Should not be visible at all +
+(synonym for EVERYWHERE)
+
+| ALL_TABLES
+| propertyHiddenAllTables
+| Visible in the object form, but _not_ visible in the child collection nor in the standalone list returned by the action.
+
+| OBJECT_FORMS
+| propertyHiddenObjectForms
+| Visible in collections, but _not_ in the object's detail.
+
+| STANDALONE_TABLES
+| propertyHiddenStandaloneTables
+| Visible in the object form and collection, but _not_ in the standalone list returned by the action.
+
+| ALL_EXCEPT_ +
+STANDALONE_TABLES
+| propertyHiddenAllExceptStandaloneTables
+| Visible only in the standalone list returned by the action.
+
+| PARENTED_TABLES
+| propertyHiddenParentedTables
+| Visible everywhere _except_ in the collection.
+
+| REFERENCES_PARENT
+| propertyHiddenReferencesParent
+| Visible everywhere _except_ in the collection, where the type of the property is the referencing parent object.
+
+|===
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.java
new file mode 100644
index 0000000..80e6238
--- /dev/null
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.java
@@ -0,0 +1,201 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package demoapp.dom.annotDomain.Property.hidden.child;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlTransient;
+import javax.xml.bind.annotation.XmlType;
+
+import org.apache.isis.applib.annotation.DomainObject;
+import org.apache.isis.applib.annotation.MemberOrder;
+import org.apache.isis.applib.annotation.Nature;
+import org.apache.isis.applib.annotation.Optionality;
+import org.apache.isis.applib.annotation.Property;
+import org.apache.isis.applib.annotation.PropertyLayout;
+import org.apache.isis.applib.annotation.Where;
+
+import lombok.Getter;
+import lombok.NoArgsConstructor;
+import lombok.Setter;
+
+import demoapp.dom._infra.asciidocdesc.HasAsciiDocDescription;
+import demoapp.dom.annotDomain.Property.hidden.PropertyHiddenVm;
+
+//tag::class[]
+@XmlRootElement(name = "child")
+@XmlType
+@XmlAccessorType(XmlAccessType.FIELD)
+@DomainObject(
+ nature=Nature.VIEW_MODEL,
+ objectType = "demo.PropertyHiddenChildVm"
+)
+@NoArgsConstructor
+public class PropertyHiddenChildVm implements HasAsciiDocDescription {
+
+ public PropertyHiddenChildVm(String value, PropertyHiddenVm parent) {
+ setPropertyHiddenNowhere(value);
+ setPropertyHiddenEverywhere(value);
+ setPropertyHiddenAnywhere(value);
+
+ setPropertyHiddenAllTables(value);
+ setPropertyHiddenObjectForms(value);
+
+ setPropertyHiddenStandaloneTables(value);
+ setPropertyHiddenAllExceptStandaloneTables(value);
+ setPropertyHiddenParentedTables(value);
+
+ setPropertyHiddenReferencesParent(parent);
+ }
+
+ public String title() {
+ return "PropertyLayout#hidden (child object)";
+ }
+
+//tag::variants-nowhere[]
+ @Property(
+ hidden = Where.NOWHERE // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.NOWHERE)"
+ )
+ @MemberOrder(name = "variants", sequence = "1")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenNowhere;
+//end::variants-nowhere[]
+
+//tag::variants-everywhere[]
+ @Property(
+ hidden = Where.EVERYWHERE // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.EVERYWHERE)"
+ )
+ @MemberOrder(name = "variants", sequence = "2")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenEverywhere;
+//end::variants-everywhere[]
+
+//tag::variants-anywhere[]
+ @Property(
+ hidden = Where.ANYWHERE // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.ANYWHERE)"
+ )
+ @MemberOrder(name = "variants", sequence = "2.1")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenAnywhere;
+//end::variants-everywhere[]
+
+//tag::variants-all_tables[]
+ @Property(
+ hidden = Where.ALL_TABLES // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.ALL_TABLES)"
+ )
+ @MemberOrder(name = "variants", sequence = "3")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenAllTables;
+//end::variants-all_tables[]
+
+//tag::variants-object_forms[]
+ @Property(
+ hidden = Where.OBJECT_FORMS // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.OBJECT_FORMS)"
+ )
+ @MemberOrder(name = "variants", sequence = "4")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenObjectForms;
+//end::variants-all_tables[]
+
+ //tag::variants-standalone_tables[]
+ @Property(
+ hidden = Where.STANDALONE_TABLES // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.STANDALONE_TABLES)"
+ )
+ @MemberOrder(name = "variants", sequence = "5")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenStandaloneTables;
+//end::variants-standalone_tables[]
+
+ //tag::variants-all_except_standalone_tables[]
+ @Property(
+ hidden = Where.ALL_EXCEPT_STANDALONE_TABLES // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.ALL_EXCEPT_STANDALONE_TABLES)"
+ )
+ @MemberOrder(name = "variants", sequence = "6")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenAllExceptStandaloneTables;
+//end::variants-all_except_standalone_tables[]
+
+
+ //tag::variants-parented_tables[]
+ @Property(
+ hidden = Where.PARENTED_TABLES // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.PARENTED_TABLES)"
+ )
+ @MemberOrder(name = "variants", sequence = "7")
+ @XmlElement(required = false)
+ @Getter @Setter
+ private String propertyHiddenParentedTables;
+//end::variants-parented_tables[]
+
+//tag::variants-references_parent[]
+ @Property(
+ hidden = Where.REFERENCES_PARENT // <.>
+ )
+ @PropertyLayout(
+ describedAs =
+ "@Property(hidden = Where.REFERENCES_PARENT)"
+ )
+ @MemberOrder(name = "variants", sequence = "8")
+ @XmlTransient // to avoid cycles
+ @Getter @Setter
+ private PropertyHiddenVm propertyHiddenReferencesParent;
+//tag::variants-references_parent[]
+
+}
+//end::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.layout.xml b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.layout.xml
new file mode 100644
index 0000000..2c69b88
--- /dev/null
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm.layout.xml
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<bs3:grid
+ xsi:schemaLocation="http://isis.apache.org/applib/layout/component http://isis.apache.org/applib/layout/component/component.xsd http://isis.apache.org/applib/layout/grid/bootstrap3 http://isis.apache.org/applib/layout/grid/bootstrap3/bootstrap3.xsd"
+ xmlns:bs3="http://isis.apache.org/applib/layout/grid/bootstrap3"
+ xmlns:cpt="http://isis.apache.org/applib/layout/component"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+
+
+ <bs3:row>
+ <bs3:col span="10" unreferencedActions="true">
+ <cpt:domainObject />
+ <cpt:action id="returnsStandaloneList"/>
+ <cpt:action id="rebuildMetamodel"/>
+ </bs3:col>
+ <bs3:col span="2">
+ <cpt:fieldSet name="" id="sources" />
+ </bs3:col>
+ </bs3:row>
+
+ <bs3:row>
+ <bs3:col span="6">
+ <cpt:fieldSet name="Variants" id="variants"/>
+ <cpt:fieldSet name="Contributed" id="contributed"/>
+ <cpt:fieldSet name="Meta-annotated" id="meta-annotated"/>
+ <cpt:fieldSet name="Meta-annotated Overridden" id="meta-annotated-overridden"/>
+ <cpt:fieldSet name="Other" id="other" unreferencedProperties="true"/>
+ </bs3:col>
+ <bs3:col span="6">
+ <cpt:fieldSet name="Description" id="description" >
+ <cpt:action id="clearHints" position="PANEL" />
+ <cpt:action id="downloadLayoutXml" position="PANEL_DROPDOWN"/>
+ <cpt:action id="rebuildMetamodel" position="PANEL_DROPDOWN"/>
+ <cpt:action id="downloadMetamodelXml" position="PANEL_DROPDOWN"/>
+ <cpt:action id="inspectMetamodel" position="PANEL_DROPDOWN"/>
+ <cpt:action id="downloadJdoMetadata" position="PANEL_DROPDOWN"/>
+ <cpt:action id="openRestApi" position="PANEL_DROPDOWN" />
+ <cpt:property id="description"/>
+ </cpt:fieldSet>
+ </bs3:col>
+ </bs3:row>
+ <bs3:row>
+ <bs3:col span="12" unreferencedCollections="true"/>
+ </bs3:row>
+
+</bs3:grid>
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm_mixinProperty.java
similarity index 72%
copy from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
copy to examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm_mixinProperty.java
index de4c6b5..5e192c3 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/hidden/child/PropertyHiddenChildVm_mixinProperty.java
@@ -16,31 +16,32 @@
* specific language governing permissions and limitations
* under the License.
*/
-package demoapp.dom.annotLayout.PropertyLayout.cssClass;
+package demoapp.dom.annotDomain.Property.hidden.child;
import org.apache.isis.applib.annotation.MemberOrder;
import org.apache.isis.applib.annotation.Property;
import org.apache.isis.applib.annotation.PropertyLayout;
+import org.apache.isis.applib.annotation.Where;
import lombok.RequiredArgsConstructor;
//tag::class[]
@Property()
-@CssClassMetaAnnotation // <.>
@PropertyLayout(
- describedAs =
- "@CssClassMetaAnnotation"
+ hidden = Where.ALL_TABLES // <.>
+ , describedAs =
+ "@Property(hidden = ALL_TABLES)"
)
@RequiredArgsConstructor
-public class PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation {
+public class PropertyHiddenChildVm_mixinProperty {
// ...
//end::class[]
- private final PropertyLayoutCssClassVm propertyLayoutCssClassVm;
+ private final PropertyHiddenChildVm propertyHiddenChildVm;
- @MemberOrder(name = "meta-annotated", sequence = "2")
+ @MemberOrder(name = "contributed", sequence = "1")
public String prop() {
- return propertyLayoutCssClassVm.getPropertyUsingAnnotation();
+ return propertyHiddenChildVm.getPropertyHiddenNowhere();
}
//tag::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/optionality/PropertyOptionalityVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/optionality/PropertyOptionalityVm-description.adoc
index 1ba692b..644ff73 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/optionality/PropertyOptionalityVm-description.adoc
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotDomain/Property/optionality/PropertyOptionalityVm-description.adoc
@@ -1,3 +1,5 @@
+CAUTION: TODO: can also use `@Nullable`, for parameters at least.
+
The `optionality` semantic specifies that a property or parameter is either optional or mandatory:
* for properties, the semantic can be specified using either the `@Property` annotation, or a meta-annotation
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/PropertyLayoutMenu.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/PropertyLayoutMenu.java
index ba836a6..da4204f 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/PropertyLayoutMenu.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/PropertyLayoutMenu.java
@@ -61,15 +61,15 @@ public class PropertyLayoutMenu {
}
@Action(semantics = SemanticsOf.SAFE)
- @ActionLayout(cssClassFa="fa-tag", describedAs = "Label positions")
- public PropertyLayoutLabelPositionVm labelPosition(){
- return new PropertyLayoutLabelPositionVm();
- }
-
- @Action(semantics = SemanticsOf.SAFE)
@ActionLayout(cssClassFa="fa-glasses", describedAs = "Visibility of properties, eg in tables")
public PropertyLayoutHiddenVm hidden() {
val vm = new PropertyLayoutHiddenVm();
+ vm.setPropertyHiddenAnywhere("hidden anywhere");
+ vm.setPropertyHiddenEverywhere("hidden everywhere");
+ vm.setPropertyHiddenNowhereUsingAnnotation("hidden nowhere using annotation");
+ vm.setPropertyUsingMetaAnnotation("using meta-annotation");
+ vm.setPropertyUsingMetaAnnotationButOverridden("using meta-annotation but overridden");
+
vm.getChildren().add(new PropertyLayoutHiddenChildVm("child 1", vm));
vm.getChildren().add(new PropertyLayoutHiddenChildVm("child 2", vm));
vm.getChildren().add(new PropertyLayoutHiddenChildVm("child 3", vm));
@@ -77,6 +77,12 @@ public class PropertyLayoutMenu {
}
@Action(semantics = SemanticsOf.SAFE)
+ @ActionLayout(cssClassFa="fa-tag", describedAs = "Label positions")
+ public PropertyLayoutLabelPositionVm labelPosition(){
+ return new PropertyLayoutLabelPositionVm();
+ }
+
+ @Action(semantics = SemanticsOf.SAFE)
@ActionLayout(cssClassFa="fa-align-justify", describedAs = "Textboxes")
public PropertyLayoutMultiLineVm multiLine(){
val vm = new PropertyLayoutMultiLineVm();
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassRedMetaAnnotation.java
similarity index 94%
rename from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java
rename to examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassRedMetaAnnotation.java
index 2648b57..e914e30 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/CssClassRedMetaAnnotation.java
@@ -19,7 +19,7 @@ import org.apache.isis.applib.annotation.PropertyLayout;
ElementType.TYPE // <.>
})
@Retention(RetentionPolicy.RUNTIME)
-public @interface CssClassMetaAnnotation {
+public @interface CssClassRedMetaAnnotation {
}
//end::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm-description.adoc
index 600d1e8..c403305 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm-description.adoc
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm-description.adoc
@@ -69,7 +69,7 @@ The CSS class hint can also be specified using a custom meta-annotation:
+
[source,java]
----
-include::CssClassMetaAnnotation.java[tags=class]
+include::CssClassRedMetaAnnotation.java[tags=class]
----
<.> annotated for a property ...
<.> \... and for a parameter.
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm.java
index fd12115..27b816d 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm.java
@@ -78,10 +78,10 @@ public class PropertyLayoutCssClassVm implements HasAsciiDocDescription {
//end::layout-file[]
//tag::meta-annotated[]
+ @CssClassRedMetaAnnotation // <.>
@Property(optionality = Optionality.OPTIONAL)
- @CssClassMetaAnnotation // <.>
@PropertyLayout(
- describedAs = "@CssClassMetaAnnotation"
+ describedAs = "@CssClassRedMetaAnnotation"
)
@MemberOrder(name = "meta-annotated", sequence = "1")
@XmlElement(required = false)
@@ -90,12 +90,12 @@ public class PropertyLayoutCssClassVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
+ @CssClassRedMetaAnnotation // <.>
@Property(optionality = Optionality.OPTIONAL)
- @CssClassMetaAnnotation // <.>
@PropertyLayout(
cssClass = "blue" // <.>
, describedAs =
- "@CssClassMetaAnnotation @PropertyLayout(...)"
+ "@CssClassRedMetaAnnotation @PropertyLayout(...)"
)
@MemberOrder(name = "meta-annotated-overridden", sequence = "1")
@XmlElement(required = false)
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
index de4c6b5..d3a1b58 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation.java
@@ -26,10 +26,10 @@ import lombok.RequiredArgsConstructor;
//tag::class[]
@Property()
-@CssClassMetaAnnotation // <.>
+@CssClassRedMetaAnnotation // <.>
@PropertyLayout(
describedAs =
- "@CssClassMetaAnnotation"
+ "@CssClassRedMetaAnnotation"
)
@RequiredArgsConstructor
public class PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotation {
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotationOverridden.java
index 5b1e844..4c8f024 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -25,12 +25,12 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
+@CssClassRedMetaAnnotation // <.>
@Property()
-@CssClassMetaAnnotation // <.>
@PropertyLayout(
cssClass = "blue" // <.>
, describedAs =
- "@CssClassMetaAnnotation @ParameterLayout(...)"
+ "@CssClassRedMetaAnnotation @ParameterLayout(...)"
)
@RequiredArgsConstructor
public class PropertyLayoutCssClassVm_mixinPropertyWithMetaAnnotationOverridden {
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotation.java
index edb6ae2..8f1a273 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotation.java
@@ -20,9 +20,9 @@ public class PropertyLayoutCssClassVm_updateWithMetaAnnotation {
//tag::meta-annotation[]
public PropertyLayoutCssClassVm act(
@Parameter(optionality = Optionality.OPTIONAL)
- @CssClassMetaAnnotation // <.>
+ @CssClassRedMetaAnnotation // <.>
@ParameterLayout(
- describedAs = "@CssClassMetaAnnotation"
+ describedAs = "@CssClassRedMetaAnnotation"
)
final String parameterUsingMetaAnnotation) {
propertyLayoutCssClassVm.setPropertyUsingMetaAnnotation(parameterUsingMetaAnnotation);
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotationOverridden.java
index 4dc7c17..926253a 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/cssClass/PropertyLayoutCssClassVm_updateWithMetaAnnotationOverridden.java
@@ -19,12 +19,13 @@ public class PropertyLayoutCssClassVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutCssClassVm act(
+ @CssClassRedMetaAnnotation // <.>
@Parameter(optionality = Optionality.OPTIONAL)
- @CssClassMetaAnnotation // <.>
@ParameterLayout(
cssClass = "blue" // <.>
, describedAs =
- "@CssClassMetaAnnotation @ParameterLayout(...)"
+ "@CssClassRedMetaAnnotation " +
+ "@ParameterLayout(...)"
)
final String parameterUsingMetaAnnotationButOverridden) {
propertyLayoutCssClassVm.setPropertyUsingMetaAnnotationButOverridden(parameterUsingMetaAnnotationButOverridden);
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm.java
index 2165bd7..ce728b4 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm.java
@@ -86,8 +86,8 @@ public class PropertyLayoutDescribedAsVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@DescribedAsMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
describedAs =
"@DescribedAsMetaAnnotation @PropertyLayout(...)" // <.>
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_mixinPropertyWithMetaAnnotationOverridden.java
index ba37a6a..a0e1159 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -25,8 +25,8 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
@DescribedAsMetaAnnotation // <.>
+@Property()
@PropertyLayout(
describedAs = // <.>
"@DescribedAsMetaAnnotation " +
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_updateWithMetaAnnotationOverridden.java
index 2159322..9ebfcad 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/describedAs/PropertyLayoutDescribedAsVm_updateWithMetaAnnotationOverridden.java
@@ -19,8 +19,8 @@ public class PropertyLayoutDescribedAsVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutDescribedAsVm act(
- @Parameter(optionality = Optionality.OPTIONAL)
@DescribedAsMetaAnnotation // <.>
+ @Parameter(optionality = Optionality.OPTIONAL)
@ParameterLayout(
describedAs = // <.>
"@DescribedAsMetaAnnotation @ParameterLayout(...)"
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc
index 663b578..1a250ad 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm-description.adoc
@@ -8,6 +8,13 @@ Most commonly, this is to hide properties in tables (parented, standalone, or bo
Because some of the `hidden` variants relate to tables, this view model has a collection of child objects with those child objects annotated to show the relevant options.
There is also an action that returns this same set of child objects as a standalone list.
+[NOTE]
+====
+It is also specify to hide properties using `@Property`.
+This is to allow the distinction between a property that is hidden as a deep domain concept, compared to a property that is hidden in some circumstances for cosmetic UI reasons.
+
+In the user interface, the effect is the same.
+====
== Annotated
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java
index 1f4a9c1..d95c977 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm.java
@@ -133,15 +133,15 @@ public class PropertyLayoutHiddenVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@HiddenEverywhereMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
hidden = Where.NOWHERE // <.>
, describedAs =
"@HiddenEverywhereMetaAnnotation " +
"@PropertyLayout(hidden = Where.NOWHERE)"
)
- @MemberOrder(name = "meta-annotated", sequence = "2")
+ @MemberOrder(name = "meta-annotated-overridden", sequence = "2")
@XmlElement(required = false)
@Getter @Setter
private String propertyUsingMetaAnnotationButOverridden;
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
index 98aad0d..87b6609 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/hidden/PropertyLayoutHiddenVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -26,10 +26,10 @@ import org.apache.isis.applib.annotation.Where;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
+@HiddenEverywhereMetaAnnotation // <.>
@Property()
-@HiddenEverywhereMetaAnnotation // <.>
@PropertyLayout(
- hidden = Where.NOWHERE // <.>
+ hidden = Where.NOWHERE // <.>
, describedAs =
"@HiddenEverywhereMetaAnnotation " +
"@PropertyLayout(hidden = NOWHERE)"
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm.java
index a037b1c..65d4c70 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm.java
@@ -91,8 +91,8 @@ public class PropertyLayoutLabelPositionVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@LabelPositionTopMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
labelPosition = LabelPosition.LEFT // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_mixinPropertyWithMetaAnnotationOverridden.java
index 015e159..7bcf241 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -26,8 +26,8 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
@LabelPositionTopMetaAnnotation // <.>
+@Property()
@PropertyLayout(
labelPosition = LabelPosition.LEFT // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_updateWithMetaAnnotationOverridden.java
index 818db6d..714064f 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/labelPosition/PropertyLayoutLabelPositionVm_updateWithMetaAnnotationOverridden.java
@@ -20,8 +20,8 @@ public class PropertyLayoutLabelPositionVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutLabelPositionVm act(
- @Parameter(optionality = Optionality.OPTIONAL)
@LabelPositionTopMetaAnnotation // <.>
+ @Parameter(optionality = Optionality.OPTIONAL)
@ParameterLayout(
labelPosition = LabelPosition.LEFT // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLineMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLine10MetaAnnotation.java
similarity index 94%
rename from examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLineMetaAnnotation.java
rename to examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLine10MetaAnnotation.java
index 37aec9d..0b5c8fc 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLineMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/MultiLine10MetaAnnotation.java
@@ -19,7 +19,7 @@ import org.apache.isis.applib.annotation.PropertyLayout;
ElementType.TYPE // <.>
})
@Retention(RetentionPolicy.RUNTIME)
-public @interface MultiLineMetaAnnotation {
+public @interface MultiLine10MetaAnnotation {
}
//end::class[]
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm-description.adoc b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm-description.adoc
index 57cebd6..deecf73 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm-description.adoc
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm-description.adoc
@@ -69,7 +69,7 @@ The multiline hint can also be specified using a custom meta-annotation:
+
[source,java]
----
-include::MultiLineMetaAnnotation.java[tags=class]
+include::MultiLine10MetaAnnotation.java[tags=class]
----
<.> annotated for a property ...
<.> \... and for a parameter.
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm.java
index 3d685a5..82bac88 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm.java
@@ -94,10 +94,10 @@ public class PropertyLayoutMultiLineVm implements HasAsciiDocDescription {
//end::layout-file[]
//tag::meta-annotated[]
+ @MultiLine10MetaAnnotation // <.>
@Property(optionality = Optionality.OPTIONAL)
- @MultiLineMetaAnnotation // <.>
@PropertyLayout(
- describedAs = "@MultiLineMetaAnnotation"
+ describedAs = "@MultiLine10MetaAnnotation"
)
@MemberOrder(name = "meta-annotated", sequence = "1")
@XmlElement(required = false)
@@ -106,12 +106,13 @@ public class PropertyLayoutMultiLineVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
+ @MultiLine10MetaAnnotation // <.>
@Property(optionality = Optionality.OPTIONAL)
- @MultiLineMetaAnnotation // <.>
@PropertyLayout(
multiLine = 3 // <.>
, describedAs =
- "@MultiLineMetaAnnotation @PropertyLayout(...)"
+ "@MultiLine10MetaAnnotation " +
+ "@PropertyLayout(multiLine = 3)"
)
@MemberOrder(name = "meta-annotated-overridden", sequence = "1")
@XmlElement(required = false)
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotation.java
index 2854dad..289634e 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotation.java
@@ -25,11 +25,11 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::class[]
+@MultiLine10MetaAnnotation // <.>
@Property()
-@MultiLineMetaAnnotation // <.>
@PropertyLayout(
describedAs =
- "@MultiLineMetaAnnotation"
+ "@MultiLine10MetaAnnotation"
)
@RequiredArgsConstructor
public class PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotation {
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotationOverridden.java
index e9e1750..c3e9c3f 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -25,12 +25,13 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
+@MultiLine10MetaAnnotation // <.>
@Property()
-@MultiLineMetaAnnotation // <.>
@PropertyLayout(
multiLine = 3 // <.>
, describedAs =
- "@MultiLineMetaAnnotation @PropertyLayout(...)"
+ "@MultiLine10MetaAnnotation " +
+ "@PropertyLayout(multiLine = 3)"
)
@RequiredArgsConstructor
public class PropertyLayoutMultiLineVm_mixinPropertyWithMetaAnnotationOverridden {
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotation.java
index d3e1b4c..68d65bc 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotation.java
@@ -38,9 +38,9 @@ public class PropertyLayoutMultiLineVm_updateWithMetaAnnotation {
//tag::meta-annotation[]
public PropertyLayoutMultiLineVm act(
@Parameter(optionality = Optionality.OPTIONAL)
- @MultiLineMetaAnnotation // <.>
+ @MultiLine10MetaAnnotation // <.>
@ParameterLayout(
- describedAs = "@MultiLineMetaAnnotation"
+ describedAs = "@MultiLine10MetaAnnotation"
)
final String parameterUsingMetaAnnotation) {
propertyLayoutMultiLineVm.setPropertyUsingMetaAnnotation(parameterUsingMetaAnnotation);
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotationOverridden.java
index e1757db..1dd0731 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/multiLine/PropertyLayoutMultiLineVm_updateWithMetaAnnotationOverridden.java
@@ -19,12 +19,13 @@ public class PropertyLayoutMultiLineVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutMultiLineVm act(
+ @MultiLine10MetaAnnotation // <.>
@Parameter(optionality = Optionality.OPTIONAL)
- @MultiLineMetaAnnotation // <.>
@ParameterLayout(
multiLine = 3 // <.>
, describedAs =
- "@MultiLineMetaAnnotation @ParameterLayout(...)"
+ "@MultiLine10MetaAnnotation " +
+ "@ParameterLayout(multiLine = 3)"
)
final String parameterUsingMetaAnnotationButOverridden) {
propertyLayoutMultiLineVm.setPropertyUsingMetaAnnotationButOverridden(parameterUsingMetaAnnotationButOverridden);
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm.java
index 5ddf266..2b6c65e 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm.java
@@ -92,8 +92,8 @@ public class PropertyLayoutNamedVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
+ @NamedMetaAnnotation // <.>
@Property(optionality = Optionality.OPTIONAL)
- @NamedMetaAnnotation // <.>
@PropertyLayout(
named = "@PropertyLayout name " +
"overrides meta-annotation" // <.>
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_mixinPropertyWithMetaAnnotationOverridden.java
index 1884478..fd52893 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -25,8 +25,8 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
@NamedMetaAnnotation // <.>
+@Property()
@PropertyLayout(
named = "@PropertyLayout overrides meta-annotation for mixin" // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_updateWithMetaAnnotationOverridden.java
index 26befcb..2d87095 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/named/PropertyLayoutNamedVm_updateWithMetaAnnotationOverridden.java
@@ -19,8 +19,8 @@ public class PropertyLayoutNamedVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutNamedVm act(
- @Parameter(optionality = Optionality.OPTIONAL)
@NamedMetaAnnotation // <.>
+ @Parameter(optionality = Optionality.OPTIONAL)
@ParameterLayout(
named = "@ParameterLayout overrides meta-annotation" // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm.java
index 057c956..86eb3ad 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm.java
@@ -120,8 +120,8 @@ public class PropertyLayoutRenderDayVm implements HasAsciiDocDescription {
//end::layout-file[]
//tag::meta-annotation[]
- @Property(optionality = Optionality.OPTIONAL)
@RenderDayMetaAnnotationEndDateExclusive // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
describedAs =
"@RenderDayMetaAnnotationEndDateExclusive"
@@ -134,8 +134,8 @@ public class PropertyLayoutRenderDayVm implements HasAsciiDocDescription {
//end::meta-annotation[]
//tag::meta-annotation-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@RenderDayMetaAnnotationStartDateInclusive // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
renderDay = RenderDay.AS_DAY_BEFORE
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_mixinEndDateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_mixinEndDateWithMetaAnnotationOverridden.java
index 054cbf7..0853c17 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_mixinEndDateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_mixinEndDateWithMetaAnnotationOverridden.java
@@ -28,9 +28,9 @@ import org.apache.isis.applib.annotation.RenderDay;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
// deliberately incorrectly annotated
@RenderDayMetaAnnotationStartDateInclusive // <.>
+@Property()
@PropertyLayout(
renderDay = RenderDay.AS_DAY_BEFORE // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_updateEndDateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_updateEndDateWithMetaAnnotationOverridden.java
index 60e43d0..76774ce 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_updateEndDateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/renderDay/PropertyLayoutRenderDayVm_updateEndDateWithMetaAnnotationOverridden.java
@@ -22,8 +22,8 @@ public class PropertyLayoutRenderDayVm_updateEndDateWithMetaAnnotationOverridden
//tag::meta-annotation-overridden[]
public PropertyLayoutRenderDayVm act(
- @Parameter(optionality = Optionality.OPTIONAL)
@RenderDayMetaAnnotationStartDateInclusive // <.>
+ @Parameter(optionality = Optionality.OPTIONAL)
@ParameterLayout(
renderDay = RenderDay.AS_DAY_BEFORE // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm.java
index 5ef92a0..3dbf832 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm.java
@@ -93,8 +93,8 @@ public class PropertyLayoutRepaintingVm implements HasAsciiDocDescription {
//end::layout-file[]
//tag::meta-annotated[]
- @Property(optionality = Optionality.OPTIONAL)
@RepaintingNoRepaintMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
describedAs = "@RepaintingNoRepaintMetaAnnotation"
)
@@ -106,8 +106,8 @@ public class PropertyLayoutRepaintingVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@RepaintingRepaintMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
repainting = Repainting.NO_REPAINT // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotation.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotation.java
index c4a5ee5..8d9b919 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotation.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotation.java
@@ -26,8 +26,8 @@ import org.apache.isis.applib.value.Blob;
import lombok.RequiredArgsConstructor;
//tag::class[]
-@Property()
@RepaintingNoRepaintMetaAnnotation // <.>
+@Property()
@PropertyLayout(
describedAs =
"@RepaintingNoRepaintMetaAnnotation"
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotationOverridden.java
index 6d05d7f..b747583 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/repainting/PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -27,12 +27,13 @@ import org.apache.isis.applib.value.Blob;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
@RepaintingRepaintMetaAnnotation // <.>
+@Property()
@PropertyLayout(
repainting = Repainting.NO_REPAINT // <.>
, describedAs =
- "@RepaintingNoRepaintMetaAnnotation @PropertyLayout(...)"
+ "@RepaintingRepaintMetaAnnotation " +
+ "@PropertyLayout(repainting = NO_REPAINT)"
)
@RequiredArgsConstructor
public class PropertyLayoutRepaintingVm_mixinPropertyWithMetaAnnotationOverridden {
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm.java
index 1a61af0..a8d4a23 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm.java
@@ -78,8 +78,8 @@ public class PropertyLayoutTypicalLengthVm implements HasAsciiDocDescription {
//end::layout-file[]
//tag::meta-annotated[]
- @Property(optionality = Optionality.OPTIONAL)
@TypicalLengthMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
describedAs = "@TypicalLengthMetaAnnotation"
)
@@ -90,8 +90,8 @@ public class PropertyLayoutTypicalLengthVm implements HasAsciiDocDescription {
//end::meta-annotated[]
//tag::meta-annotated-overridden[]
- @Property(optionality = Optionality.OPTIONAL)
@TypicalLengthMetaAnnotation // <.>
+ @Property(optionality = Optionality.OPTIONAL)
@PropertyLayout(
typicalLength = 5 // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_mixinPropertyWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_mixinPropertyWithMetaAnnotationOverridden.java
index 6887cdb..e7ded0e 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_mixinPropertyWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_mixinPropertyWithMetaAnnotationOverridden.java
@@ -25,8 +25,8 @@ import org.apache.isis.applib.annotation.PropertyLayout;
import lombok.RequiredArgsConstructor;
//tag::meta-annotation-overridden[]
-@Property()
@TypicalLengthMetaAnnotation // <.>
+@Property()
@PropertyLayout(
typicalLength = 3 // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_updateWithMetaAnnotationOverridden.java b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_updateWithMetaAnnotationOverridden.java
index e8bb57f..1be4561 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_updateWithMetaAnnotationOverridden.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/annotLayout/PropertyLayout/typicalLength/PropertyLayoutTypicalLengthVm_updateWithMetaAnnotationOverridden.java
@@ -19,8 +19,8 @@ public class PropertyLayoutTypicalLengthVm_updateWithMetaAnnotationOverridden {
//tag::meta-annotation-overridden[]
public PropertyLayoutTypicalLengthVm act(
- @Parameter(optionality = Optionality.OPTIONAL)
@TypicalLengthMetaAnnotation // <.>
+ @Parameter(optionality = Optionality.OPTIONAL)
@ParameterLayout(
typicalLength = 3 // <.>
, describedAs =
diff --git a/examples/demo/domain/src/main/java/demoapp/dom/menubars.layout.xml b/examples/demo/domain/src/main/java/demoapp/dom/menubars.layout.xml
index 418f5c0..050fe05 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/menubars.layout.xml
+++ b/examples/demo/domain/src/main/java/demoapp/dom/menubars.layout.xml
@@ -110,6 +110,7 @@ as a replacement for
<mb3:named>@Property</mb3:named>
<mb3:serviceAction objectType="demo.PropertyMenu" id="editing"/>
<mb3:serviceAction objectType="demo.PropertyMenu" id="fileAccept"/>
+ <mb3:serviceAction objectType="demo.PropertyMenu" id="hidden"/>
<mb3:serviceAction objectType="demo.PropertyMenu" id="maxLength"/>
<mb3:serviceAction objectType="demo.PropertyMenu" id="mustSatisfy"/>
<mb3:serviceAction objectType="demo.PropertyMenu" id="optionality"/>