isis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From danhayw...@apache.org
Subject svn commit: r1381293 [3/4] - in /incubator/isis/trunk/framework: applib/src/docbkx/guide/ applib/src/main/java/org/apache/isis/applib/annotation/ core/metamodel/src/main/java/org/apache/isis/core/metamodel/facetapi/ core/metamodel/src/main/java/org/apa...
Date Wed, 05 Sep 2012 18:48:15 GMT
Copied: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hidden/HiddenAnnotationFacetFactoryTest.java (from r1380413, incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hide/HiddenAnnotationFacetFactoryTest.java)
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hidden/HiddenAnnotationFacetFactoryTest.java?p2=incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hidden/HiddenAnnotationFacetFactoryTest.java&p1=incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hide/HiddenAnnotationFacetFactoryTest.java&r1=1380413&r2=1381293&rev=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hide/HiddenAnnotationFacetFactoryTest.java (original)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/hidden/HiddenAnnotationFacetFactoryTest.java Wed Sep  5 18:48:09 2012
@@ -17,7 +17,7 @@
  *  under the License.
  */
 
-package org.apache.isis.core.progmodel.facets.hide;
+package org.apache.isis.core.progmodel.facets.hidden;
 
 import java.lang.reflect.Method;
 import java.util.Collection;
@@ -29,8 +29,8 @@ import org.apache.isis.core.metamodel.fa
 import org.apache.isis.core.metamodel.facets.FacetFactory.ProcessMethodContext;
 import org.apache.isis.core.metamodel.facets.hide.HiddenFacet;
 import org.apache.isis.core.progmodel.facets.AbstractFacetFactoryTest;
-import org.apache.isis.core.progmodel.facets.members.hide.HiddenFacetAbstract;
-import org.apache.isis.core.progmodel.facets.members.hide.annotation.HiddenAnnotationForMemberFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.HiddenFacetAbstract;
+import org.apache.isis.core.progmodel.facets.members.hidden.annotation.HiddenAnnotationForMemberFacetFactory;
 
 public class HiddenAnnotationFacetFactoryTest extends AbstractFacetFactoryTest {
 

Added: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/members/commonlyused/CommonlyUsedAnnotationFacetFactoryTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/members/commonlyused/CommonlyUsedAnnotationFacetFactoryTest.java?rev=1381293&view=auto
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/members/commonlyused/CommonlyUsedAnnotationFacetFactoryTest.java (added)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/members/commonlyused/CommonlyUsedAnnotationFacetFactoryTest.java Wed Sep  5 18:48:09 2012
@@ -0,0 +1,101 @@
+/*
+ *  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 org.apache.isis.core.progmodel.facets.members.commonlyused;
+
+import java.lang.reflect.Method;
+import java.util.Collection;
+
+import org.apache.isis.applib.annotation.CommonlyUsed;
+import org.apache.isis.applib.annotation.Disabled;
+import org.apache.isis.core.metamodel.facetapi.Facet;
+import org.apache.isis.core.metamodel.facets.FacetFactory.ProcessMethodContext;
+import org.apache.isis.core.metamodel.facets.FacetedMethod;
+import org.apache.isis.core.metamodel.facets.members.commonlyused.CommonlyUsedFacet;
+import org.apache.isis.core.progmodel.facets.AbstractFacetFactoryTest;
+
+public class CommonlyUsedAnnotationFacetFactoryTest extends AbstractFacetFactoryTest {
+
+    private CommonlyUsedAnnotationFacetFactory facetFactory;
+
+    @Override
+    protected void setUp() throws Exception {
+        super.setUp();
+
+        facetFactory = new CommonlyUsedAnnotationFacetFactory();
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        facetFactory = null;
+        super.tearDown();
+    }
+
+    public void testCommonlyUsedAnnotationPickedUpOnProperty() {
+
+        class Customer {
+            @CommonlyUsed
+            public int getNumberOfOrders() {
+                return 0;
+            }
+        }
+
+        facetedMethod = FacetedMethod.createForProperty(Customer.class, "numberOfOrders");
+        facetFactory.process(new ProcessMethodContext(Customer.class, facetedMethod.getMethod(), methodRemover, facetedMethod));
+
+        final Facet facet = facetedMethod.getFacet(CommonlyUsedFacet.class);
+        assertNotNull(facet);
+        assertTrue(facet instanceof CommonlyUsedFacetAnnotation);
+
+        assertNoMethodsRemoved();
+    }
+
+    public void testCommonlyUsedAnnotationPickedUpOnCollection() {
+        class Customer {
+            @CommonlyUsed
+            public Collection<?> getOrders() {
+                return null;
+            }
+        }
+        facetedMethod = FacetedMethod.createForCollection(Customer.class, "orders");
+        facetFactory.process(new ProcessMethodContext(Customer.class, facetedMethod.getMethod(), methodRemover, facetedMethod));
+
+        final Facet facet = facetedMethod.getFacet(CommonlyUsedFacet.class);
+        assertNotNull(facet);
+        assertTrue(facet instanceof CommonlyUsedFacetAnnotation);
+
+        assertNoMethodsRemoved();
+    }
+
+    public void testCommonlyUsedAnnotationPickedUpOnAction() {
+        class Customer {
+            @CommonlyUsed
+            public void someAction() {
+            }
+        }
+        final Method actionMethod = findMethod(Customer.class, "someAction");
+        facetFactory.process(new ProcessMethodContext(Customer.class, actionMethod, methodRemover, facetedMethod));
+
+        final Facet facet = facetedMethod.getFacet(CommonlyUsedFacet.class);
+        assertNotNull(facet);
+        assertTrue(facet instanceof CommonlyUsedFacetAnnotation);
+
+        assertNoMethodsRemoved();
+    }
+}

Modified: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/DeweyOrderSetTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/DeweyOrderSetTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/DeweyOrderSetTest.java (original)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/DeweyOrderSetTest.java Wed Sep  5 18:48:09 2012
@@ -68,11 +68,11 @@ public class DeweyOrderSetTest extends T
         }
     }
 
-    private final FacetedMethod lastNameMember = FacetedMethod.createProperty(Customer.class, "Last Name");
-    private final FacetedMethod firstNameMember = FacetedMethod.createProperty(Customer.class, "First Name");
-    private final FacetedMethod houseNumberMember = FacetedMethod.createProperty(Customer.class, "House Number");
-    private final FacetedMethod streetNameMember = FacetedMethod.createProperty(Customer.class, "Street Name");
-    private final FacetedMethod postalTownMember = FacetedMethod.createProperty(Customer.class, "Postal Town");
+    private final FacetedMethod lastNameMember = FacetedMethod.createForProperty(Customer.class, "Last Name");
+    private final FacetedMethod firstNameMember = FacetedMethod.createForProperty(Customer.class, "First Name");
+    private final FacetedMethod houseNumberMember = FacetedMethod.createForProperty(Customer.class, "House Number");
+    private final FacetedMethod streetNameMember = FacetedMethod.createForProperty(Customer.class, "Street Name");
+    private final FacetedMethod postalTownMember = FacetedMethod.createForProperty(Customer.class, "Postal Town");
     private final List<FacetedMethod> lastNameAndFirstName = ImmutableList.of(lastNameMember, firstNameMember);
     private final List<FacetedMethod> nameAndAddressMembers = ImmutableList.of(lastNameMember, firstNameMember, houseNumberMember, streetNameMember, postalTownMember);
     private final List<FacetedMethod> lastNameFirstNameAndPostalTown = ImmutableList.of(lastNameMember, firstNameMember, postalTownMember);

Modified: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/MemberOrderComparatorTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/MemberOrderComparatorTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/MemberOrderComparatorTest.java (original)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/ordering/memberorder/MemberOrderComparatorTest.java Wed Sep  5 18:48:09 2012
@@ -45,8 +45,8 @@ public class MemberOrderComparatorTest e
         }
     }
 
-    private final FacetedMethod m1 = FacetedMethod.createProperty(Customer.class, "abc");
-    private final FacetedMethod m2 = FacetedMethod.createProperty(Customer.class, "abc");
+    private final FacetedMethod m1 = FacetedMethod.createForProperty(Customer.class, "abc");
+    private final FacetedMethod m2 = FacetedMethod.createForProperty(Customer.class, "abc");
 
     @Override
     protected void setUp() {

Added: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/paged/PagedAnnotationFacetFactoryTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/paged/PagedAnnotationFacetFactoryTest.java?rev=1381293&view=auto
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/paged/PagedAnnotationFacetFactoryTest.java (added)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/paged/PagedAnnotationFacetFactoryTest.java Wed Sep  5 18:48:09 2012
@@ -0,0 +1,112 @@
+/*
+ *  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 org.apache.isis.core.progmodel.facets.paged;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.junit.Assert.assertThat;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.isis.applib.annotation.Paged;
+import org.apache.isis.core.metamodel.facetapi.Facet;
+import org.apache.isis.core.metamodel.facets.FacetFactory.ProcessClassContext;
+import org.apache.isis.core.metamodel.facets.FacetFactory.ProcessMethodContext;
+import org.apache.isis.core.metamodel.facets.FacetedMethod;
+import org.apache.isis.core.metamodel.facets.object.paged.PagedFacet;
+import org.apache.isis.core.progmodel.facets.AbstractFacetFactoryTest;
+
+public class PagedAnnotationFacetFactoryTest extends AbstractFacetFactoryTest {
+
+    private PagedAnnotationFacetFactory facetFactory;
+
+    @Override
+    protected void setUp() throws Exception {
+        super.setUp();
+
+        facetFactory = new PagedAnnotationFacetFactory();
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        facetFactory = null;
+        super.tearDown();
+    }
+
+    @Paged(20)
+    static class Customer {
+        @Paged(10)
+        public List<?> getOrders() {
+            return null;
+        }
+    }
+
+    static class CustomerWithoutPagedAnnotation {
+        public List<?> getOrders() {
+            return null;
+        }
+    }
+
+
+    public void testAnnotationPickedUpOnType() {
+        final ProcessClassContext processClassContext = new ProcessClassContext(Customer.class, methodRemover, facetHolder);
+        facetFactory.process(processClassContext);
+
+        final Facet facet = facetHolder.getFacet(PagedFacet.class);
+        assertNotNull(facet);
+        assertTrue(facet instanceof PagedFacetAnnotation);
+        PagedFacet pagedFacet = (PagedFacet) facet;
+        assertThat(pagedFacet.value(), is(20));
+    }
+
+    public void testNoAnnotationOnType() {
+        final ProcessClassContext processClassContext = new ProcessClassContext(CustomerWithoutPagedAnnotation.class, methodRemover, facetHolder);
+        facetFactory.process(processClassContext);
+
+        final Facet facet = facetHolder.getFacet(PagedFacet.class);
+        assertNull(facet);
+    }
+
+
+    public void testAnnotationPickedUpOnCollection() {
+        facetedMethod = FacetedMethod.createForCollection(Customer.class, "orders");
+        final Method method = facetedMethod.getMethod();
+        final ProcessMethodContext processMethodContext = new ProcessMethodContext(Customer.class, method, methodRemover, facetedMethod);
+        facetFactory.process(processMethodContext);
+
+        final Facet facet = facetedMethod.getFacet(PagedFacet.class);
+        assertNotNull(facet);
+        assertTrue(facet instanceof PagedFacetAnnotation);
+        PagedFacet pagedFacet = (PagedFacet) facet;
+        assertThat(pagedFacet.value(), is(10));
+    }
+
+    public void testNoAnnotationOnCollection() {
+        facetedMethod = FacetedMethod.createForCollection(CustomerWithoutPagedAnnotation.class, "orders");
+        final Method method = facetedMethod.getMethod();
+        final ProcessMethodContext processMethodContext = new ProcessMethodContext(Customer.class, method, methodRemover, facetedMethod);
+        facetFactory.process(processMethodContext);
+
+        final Facet facet = facetedMethod.getFacet(PagedFacet.class);
+        assertNull(facet);
+    }
+
+}

Modified: incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/properties/PropertyMethodsFacetFactoryTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/properties/PropertyMethodsFacetFactoryTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/properties/PropertyMethodsFacetFactoryTest.java (original)
+++ incubator/isis/trunk/framework/core/progmodel/src/test/java/org/apache/isis/core/progmodel/facets/properties/PropertyMethodsFacetFactoryTest.java Wed Sep  5 18:48:09 2012
@@ -37,23 +37,23 @@ import org.apache.isis.core.metamodel.fa
 import org.apache.isis.core.progmodel.facets.AbstractFacetFactoryTest;
 import org.apache.isis.core.progmodel.facets.members.describedas.staticmethod.DescribedAsFacetViaDescriptionMethodFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.describedas.staticmethod.DescribedAsFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.disable.DisableForContextFacet;
-import org.apache.isis.core.progmodel.facets.members.disable.DisableForSessionFacet;
-import org.apache.isis.core.progmodel.facets.members.disable.DisabledFacet;
-import org.apache.isis.core.progmodel.facets.members.disable.forsession.DisableForSessionFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.disable.forsession.DisabledFacetViaDisableForSessionMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.method.DisableForContextFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.disable.method.DisabledFacetViaDisableMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.staticmethod.DisabledFacetAlwaysEverywhere;
-import org.apache.isis.core.progmodel.facets.members.disable.staticmethod.DisabledFacetViaProtectMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.HideForContextFacet;
-import org.apache.isis.core.progmodel.facets.members.hide.HideForSessionFacet;
-import org.apache.isis.core.progmodel.facets.members.hide.forsession.HiddenFacetViaHideForSessionMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.forsession.HideForSessionFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.hide.method.HiddenFacetViaHideMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.method.HideForContextFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.hide.staticmethod.HiddenFacetAlwaysEverywhere;
-import org.apache.isis.core.progmodel.facets.members.hide.staticmethod.HiddenFacetViaAlwaysHideMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisableForContextFacet;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisableForSessionFacet;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisabledFacet;
+import org.apache.isis.core.progmodel.facets.members.disabled.forsession.DisableForSessionFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.disabled.forsession.DisabledFacetViaDisableForSessionMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.method.DisableForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.disabled.method.DisabledFacetViaDisableMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.staticmethod.DisabledFacetAlwaysEverywhere;
+import org.apache.isis.core.progmodel.facets.members.disabled.staticmethod.DisabledFacetViaProtectMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.HideForContextFacet;
+import org.apache.isis.core.progmodel.facets.members.hidden.HideForSessionFacet;
+import org.apache.isis.core.progmodel.facets.members.hidden.forsession.HiddenFacetViaHideForSessionMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.forsession.HideForSessionFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.hidden.method.HiddenFacetViaHideMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.method.HideForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.hidden.staticmethod.HiddenFacetAlwaysEverywhere;
+import org.apache.isis.core.progmodel.facets.members.hidden.staticmethod.HiddenFacetViaAlwaysHideMethodFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.named.staticmethod.NamedFacetViaMethod;
 import org.apache.isis.core.progmodel.facets.members.named.staticmethod.NamedFacetViaNameMethodFacetFactory;
 import org.apache.isis.core.progmodel.facets.properties.accessor.PropertyAccessorFacetFactory;

Modified: incubator/isis/trunk/framework/progmodels/dflt/src/main/java/org/apache/isis/progmodels/dflt/ProgrammingModelFacetsJava5.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/progmodels/dflt/src/main/java/org/apache/isis/progmodels/dflt/ProgrammingModelFacetsJava5.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/progmodels/dflt/src/main/java/org/apache/isis/progmodels/dflt/ProgrammingModelFacetsJava5.java (original)
+++ incubator/isis/trunk/framework/progmodels/dflt/src/main/java/org/apache/isis/progmodels/dflt/ProgrammingModelFacetsJava5.java Wed Sep  5 18:48:09 2012
@@ -43,16 +43,17 @@ import org.apache.isis.core.progmodel.fa
 import org.apache.isis.core.progmodel.facets.collections.notpersisted.annotation.NotPersistedAnnotationForCollectionFacetFactory;
 import org.apache.isis.core.progmodel.facets.collections.typeof.TypeOfAnnotationForCollectionsFacetFactory;
 import org.apache.isis.core.progmodel.facets.fallback.FallbackFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.commonlyused.CommonlyUsedAnnotationFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.describedas.annotation.DescribedAsAnnotationOnMemberFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.describedas.staticmethod.DescribedAsFacetViaDescriptionMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.annotation.DisabledAnnotationFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.forsession.DisabledFacetViaDisableForSessionMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.method.DisabledFacetViaDisableMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.disable.staticmethod.DisabledFacetViaProtectMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.annotation.HiddenAnnotationForMemberFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.forsession.HiddenFacetViaHideForSessionMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.method.HiddenFacetViaHideMethodFacetFactory;
-import org.apache.isis.core.progmodel.facets.members.hide.staticmethod.HiddenFacetViaAlwaysHideMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.annotation.DisabledAnnotationFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.forsession.DisabledFacetViaDisableForSessionMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.method.DisabledFacetViaDisableMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.disabled.staticmethod.DisabledFacetViaProtectMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.annotation.HiddenAnnotationForMemberFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.forsession.HiddenFacetViaHideForSessionMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.method.HiddenFacetViaHideMethodFacetFactory;
+import org.apache.isis.core.progmodel.facets.members.hidden.staticmethod.HiddenFacetViaAlwaysHideMethodFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.named.annotation.NamedAnnotationOnMemberFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.named.staticmethod.NamedFacetViaNameMethodFacetFactory;
 import org.apache.isis.core.progmodel.facets.members.order.MemberOrderAnnotationFacetFactory;
@@ -111,6 +112,7 @@ import org.apache.isis.core.progmodel.fa
 import org.apache.isis.core.progmodel.facets.object.validprops.ObjectValidPropertiesFacetFactory;
 import org.apache.isis.core.progmodel.facets.object.value.annotation.ValueFacetFactory;
 import org.apache.isis.core.progmodel.facets.object.viewmodel.annotation.ViewModelAnnotationFacetFactory;
+import org.apache.isis.core.progmodel.facets.paged.PagedAnnotationFacetFactory;
 import org.apache.isis.core.progmodel.facets.param.choices.enums.ParameterChoicesFacetDerivedFromChoicesFacetFacetFactory;
 import org.apache.isis.core.progmodel.facets.param.choices.method.ActionChoicesFacetFactory;
 import org.apache.isis.core.progmodel.facets.param.choices.methodnum.ActionParameterChoicesFacetFactory;
@@ -253,6 +255,7 @@ public class ProgrammingModelFacetsJava5
         addFactory(HiddenFacetViaHideForSessionMethodFacetFactory.class);
         addFactory(HiddenFacetViaAlwaysHideMethodFacetFactory.class);
         addFactory(HiddenFacetViaHideMethodFacetFactory.class);
+        addFactory(CommonlyUsedAnnotationFacetFactory.class);
 
         // objects
         addFactory(ObjectSpecIdAnnotationFacetFactory.class);
@@ -340,6 +343,8 @@ public class ProgrammingModelFacetsJava5
 
         addFactory(ParseableFacetFactory.class);
         addFactory(PluralAnnotationFacetFactory.class);
+        addFactory(PagedAnnotationFacetFactory.class);
+
 
         // must come after any facets that install titles
         addFactory(MaskAnnotationForTypeFacetFactory.class);

Modified: incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/main/java/org/apache/isis/progmodel/wrapper/metamodel/internal/DomainObjectInvocationHandler.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/main/java/org/apache/isis/progmodel/wrapper/metamodel/internal/DomainObjectInvocationHandler.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/main/java/org/apache/isis/progmodel/wrapper/metamodel/internal/DomainObjectInvocationHandler.java (original)
+++ incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/main/java/org/apache/isis/progmodel/wrapper/metamodel/internal/DomainObjectInvocationHandler.java Wed Sep  5 18:48:09 2012
@@ -67,8 +67,8 @@ import org.apache.isis.core.metamodel.sp
 import org.apache.isis.core.progmodel.facets.actions.validate.method.ActionValidationFacetViaMethod;
 import org.apache.isis.core.progmodel.facets.collections.validate.CollectionValidateAddToFacetViaMethod;
 import org.apache.isis.core.progmodel.facets.collections.validate.CollectionValidateRemoveFromFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.disable.method.DisableForContextFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.hide.method.HideForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.disabled.method.DisableForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.hidden.method.HideForContextFacetViaMethod;
 import org.apache.isis.core.progmodel.facets.properties.modify.PropertyClearFacetViaClearMethod;
 import org.apache.isis.core.progmodel.facets.properties.modify.PropertySetterFacetViaModifyMethod;
 import org.apache.isis.core.progmodel.facets.properties.validate.PropertyValidateFacetViaMethod;

Modified: incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/test/java/org/apache/isis/progmodel/wrapper/WrappedFactoryDefaultTest_wrappedObject_transient.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/test/java/org/apache/isis/progmodel/wrapper/WrappedFactoryDefaultTest_wrappedObject_transient.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/test/java/org/apache/isis/progmodel/wrapper/WrappedFactoryDefaultTest_wrappedObject_transient.java (original)
+++ incubator/isis/trunk/framework/progmodels/wrapper/wrapper-metamodel/src/test/java/org/apache/isis/progmodel/wrapper/WrappedFactoryDefaultTest_wrappedObject_transient.java Wed Sep  5 18:48:09 2012
@@ -51,8 +51,8 @@ import org.apache.isis.core.metamodel.fa
 import org.apache.isis.core.metamodel.spec.SpecificationLoader;
 import org.apache.isis.core.metamodel.spec.feature.OneToOneAssociation;
 import org.apache.isis.core.metamodel.specloader.specimpl.dflt.ObjectSpecificationDefault;
-import org.apache.isis.core.progmodel.facets.members.disable.DisabledFacet;
-import org.apache.isis.core.progmodel.facets.members.disable.staticmethod.DisabledFacetAlwaysEverywhere;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisabledFacet;
+import org.apache.isis.core.progmodel.facets.members.disabled.staticmethod.DisabledFacetAlwaysEverywhere;
 import org.apache.isis.core.progmodel.facets.properties.accessor.PropertyAccessorFacetViaAccessor;
 import org.apache.isis.core.progmodel.facets.properties.modify.PropertySetterFacetViaSetterMethod;
 import org.apache.isis.core.runtime.authentication.standard.SimpleSession;

Modified: incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/main/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/DisabledFacetDerivedFromJdoPrimaryKeyAnnotation.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/main/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/DisabledFacetDerivedFromJdoPrimaryKeyAnnotation.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/main/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/DisabledFacetDerivedFromJdoPrimaryKeyAnnotation.java (original)
+++ incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/main/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/DisabledFacetDerivedFromJdoPrimaryKeyAnnotation.java Wed Sep  5 18:48:09 2012
@@ -21,7 +21,7 @@ package org.apache.isis.runtimes.dflt.ob
 import org.apache.isis.applib.annotation.When;
 import org.apache.isis.applib.annotation.Where;
 import org.apache.isis.core.metamodel.facetapi.FacetHolder;
-import org.apache.isis.core.progmodel.facets.members.disable.DisabledFacetImpl;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisabledFacetImpl;
 
 
 /**

Modified: incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/test/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/GivenJdoPrimaryKeyAnnotationFacetFactoryTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/test/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/GivenJdoPrimaryKeyAnnotationFacetFactoryTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/test/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/GivenJdoPrimaryKeyAnnotationFacetFactoryTest.java (original)
+++ incubator/isis/trunk/framework/runtimes/dflt/objectstores/jdo/jdo-metamodel/src/test/java/org/apache/isis/runtimes/dflt/objectstores/jdo/metamodel/facets/prop/primarykey/GivenJdoPrimaryKeyAnnotationFacetFactoryTest.java Wed Sep  5 18:48:09 2012
@@ -30,7 +30,7 @@ import org.apache.isis.core.metamodel.fa
 import org.apache.isis.core.metamodel.facets.FacetFactory;
 import org.apache.isis.core.metamodel.facets.mandatory.MandatoryFacet;
 import org.apache.isis.core.progmodel.facets.AbstractFacetFactoryTest;
-import org.apache.isis.core.progmodel.facets.members.disable.DisabledFacet;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisabledFacet;
 
 public class GivenJdoPrimaryKeyAnnotationFacetFactoryTest extends AbstractFacetFactoryTest {
 

Modified: incubator/isis/trunk/framework/runtimes/dflt/runtime/src/test/java/org/apache/isis/runtimes/dflt/runtime/system/ObjectMemberAbstractTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/runtimes/dflt/runtime/src/test/java/org/apache/isis/runtimes/dflt/runtime/system/ObjectMemberAbstractTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/runtimes/dflt/runtime/src/test/java/org/apache/isis/runtimes/dflt/runtime/system/ObjectMemberAbstractTest.java (original)
+++ incubator/isis/trunk/framework/runtimes/dflt/runtime/src/test/java/org/apache/isis/runtimes/dflt/runtime/system/ObjectMemberAbstractTest.java Wed Sep  5 18:48:09 2012
@@ -47,13 +47,13 @@ import org.apache.isis.core.metamodel.sp
 import org.apache.isis.core.metamodel.spec.ObjectSpecification;
 import org.apache.isis.core.metamodel.spec.feature.ObjectMemberContext;
 import org.apache.isis.core.metamodel.specloader.specimpl.ObjectMemberAbstract;
-import org.apache.isis.core.progmodel.facets.members.disable.DisableForSessionFacetAbstract;
-import org.apache.isis.core.progmodel.facets.members.hide.HiddenFacetAbstract;
-import org.apache.isis.core.progmodel.facets.members.hide.HiddenFacetImpl;
-import org.apache.isis.core.progmodel.facets.members.hide.HiddenFacetNever;
-import org.apache.isis.core.progmodel.facets.members.hide.HideForContextFacetNone;
-import org.apache.isis.core.progmodel.facets.members.hide.HideForSessionFacetAbstract;
-import org.apache.isis.core.progmodel.facets.members.hide.staticmethod.HiddenFacetAlwaysEverywhere;
+import org.apache.isis.core.progmodel.facets.members.disabled.DisableForSessionFacetAbstract;
+import org.apache.isis.core.progmodel.facets.members.hidden.HiddenFacetAbstract;
+import org.apache.isis.core.progmodel.facets.members.hidden.HiddenFacetImpl;
+import org.apache.isis.core.progmodel.facets.members.hidden.HiddenFacetNever;
+import org.apache.isis.core.progmodel.facets.members.hidden.HideForContextFacetNone;
+import org.apache.isis.core.progmodel.facets.members.hidden.HideForSessionFacetAbstract;
+import org.apache.isis.core.progmodel.facets.members.hidden.staticmethod.HiddenFacetAlwaysEverywhere;
 import org.apache.isis.core.testsupport.jmock.JUnitRuleMockery2;
 import org.apache.isis.core.testsupport.jmock.JUnitRuleMockery2.Mode;
 import org.apache.isis.runtimes.dflt.runtime.persistence.objectstore.transaction.PojoAdapterBuilder;
@@ -206,7 +206,7 @@ class ObjectMemberAbstractImpl extends O
     }
 
     protected ObjectMemberAbstractImpl(final String id) {
-        super(FacetedMethod.createProperty(Customer.class, "firstName"), FeatureType.PROPERTY, new ObjectMemberContext(null, null, null, null, null));
+        super(FacetedMethod.createForProperty(Customer.class, "firstName"), FeatureType.PROPERTY, new ObjectMemberContext(null, null, null, null, null));
     }
 
     @Override

Modified: incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberDisabledTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberDisabledTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberDisabledTest.java (original)
+++ incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberDisabledTest.java Wed Sep  5 18:48:09 2012
@@ -28,8 +28,8 @@ import java.util.List;
 
 import org.junit.Test;
 
-import org.apache.isis.core.progmodel.facets.members.disable.annotation.DisabledFacetAnnotation;
-import org.apache.isis.core.progmodel.facets.members.disable.method.DisableForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.disabled.annotation.DisabledFacetAnnotation;
+import org.apache.isis.core.progmodel.facets.members.disabled.method.DisableForContextFacetViaMethod;
 import org.apache.isis.progmodel.wrapper.applib.DisabledException;
 import org.apache.isis.viewer.junit.sample.domain.Order;
 

Modified: incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberHiddenTest.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberHiddenTest.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberHiddenTest.java (original)
+++ incubator/isis/trunk/framework/viewer/junit/src/test/java/org/apache/isis/viewer/junit/MemberHiddenTest.java Wed Sep  5 18:48:09 2012
@@ -26,9 +26,9 @@ import static org.junit.Assert.fail;
 
 import org.junit.Test;
 
-import org.apache.isis.core.progmodel.facets.members.hide.annotation.HiddenFacetForMemberAnnotation;
-import org.apache.isis.core.progmodel.facets.members.hide.forsession.HideForSessionFacetViaMethod;
-import org.apache.isis.core.progmodel.facets.members.hide.method.HideForContextFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.hidden.annotation.HiddenFacetForMemberAnnotation;
+import org.apache.isis.core.progmodel.facets.members.hidden.forsession.HideForSessionFacetViaMethod;
+import org.apache.isis.core.progmodel.facets.members.hidden.method.HideForContextFacetViaMethod;
 import org.apache.isis.progmodel.wrapper.applib.HiddenException;
 import org.apache.isis.viewer.junit.sample.domain.Country;
 

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/EntityCollectionModel.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/EntityCollectionModel.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/EntityCollectionModel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/EntityCollectionModel.java Wed Sep  5 18:48:09 2012
@@ -29,6 +29,7 @@ import org.apache.wicket.Component;
 
 import org.apache.isis.core.metamodel.adapter.ObjectAdapter;
 import org.apache.isis.core.metamodel.adapter.mgr.AdapterManager.ConcurrencyChecking;
+import org.apache.isis.core.metamodel.facets.object.paged.PagedFacet;
 import org.apache.isis.core.metamodel.spec.ObjectSpecification;
 import org.apache.isis.core.metamodel.spec.feature.OneToManyAssociation;
 import org.apache.isis.runtimes.dflt.runtime.system.context.IsisContext;
@@ -52,6 +53,9 @@ public class EntityCollectionModel exten
 
     private static final long serialVersionUID = 1L;
 
+    private static final int PAGE_SIZE_DEFAULT_FOR_PARENTED = 12;
+    private static final int PAGE_SIZE_DEFAULT_FOR_STANDALONE = 25;
+
     public enum Type {
         /**
          * A simple list of object mementos, eg the result of invoking an action
@@ -103,7 +107,9 @@ public class EntityCollectionModel exten
 
         final ObjectSpecification elementSpec = collectionAsAdapter.getElementSpecification();
         final Class<?> elementType = elementSpec.getCorrespondingClass();
-        return new EntityCollectionModel(elementType, mementoList);
+        int pageSize = pageSize(elementSpec.getFacet(PagedFacet.class), PAGE_SIZE_DEFAULT_FOR_STANDALONE);
+        
+        return new EntityCollectionModel(elementType, mementoList, pageSize);
     }
 
     /**
@@ -142,10 +148,13 @@ public class EntityCollectionModel exten
 
     private SelectionHandler selectionHandler;
 
-    private EntityCollectionModel(final Class<?> typeOf, final List<ObjectAdapterMemento> mementoList) {
+    private final int pageSize;
+
+    private EntityCollectionModel(final Class<?> typeOf, final List<ObjectAdapterMemento> mementoList, final int pageSize) {
         this.type = Type.STANDALONE;
         this.typeOf = typeOf;
         this.mementoList = mementoList;
+        this.pageSize = pageSize;
     }
 
     private EntityCollectionModel(final ObjectAdapter adapter, final OneToManyAssociation collection) {
@@ -161,6 +170,11 @@ public class EntityCollectionModel exten
         this.typeOf = ClassLoaders.forName(collection.getSpecification());
         this.parentObjectAdapterMemento = parentAdapterMemento;
         this.collectionMemento = new CollectionMemento(collection);
+        this.pageSize = pageSize(collection.getFacet(PagedFacet.class), PAGE_SIZE_DEFAULT_FOR_PARENTED);
+    }
+
+    private static int pageSize(final PagedFacet pagedFacet, final int defaultPageSize) {
+        return pagedFacet != null ? pagedFacet.value(): defaultPageSize;
     }
 
     public boolean isParented() {
@@ -171,6 +185,10 @@ public class EntityCollectionModel exten
         return type == Type.STANDALONE;
     }
 
+    public int getPageSize() {
+        return pageSize;
+    }
+    
     /**
      * The name of the collection (if has an entity, ie, if
      * {@link #isParented() is parented}.)

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/ScalarModel.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/ScalarModel.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/ScalarModel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-model/src/main/java/org/apache/isis/viewer/wicket/model/models/ScalarModel.java Wed Sep  5 18:48:09 2012
@@ -35,6 +35,7 @@ import org.apache.isis.core.metamodel.ad
 import org.apache.isis.core.metamodel.consent.Consent;
 import org.apache.isis.core.metamodel.facetapi.Facet;
 import org.apache.isis.core.metamodel.facetapi.FacetHolder;
+import org.apache.isis.core.metamodel.facetapi.FacetProvider;
 import org.apache.isis.core.metamodel.facets.mandatory.MandatoryFacet;
 import org.apache.isis.core.metamodel.facets.object.parseable.ParseableFacet;
 import org.apache.isis.core.metamodel.spec.ObjectSpecId;
@@ -56,7 +57,7 @@ import org.apache.isis.viewer.wicket.mod
  * Is the backing model to each of the fields that appear in forms (for entities
  * or action dialogs).
  */
-public class ScalarModel extends EntityModel {
+public class ScalarModel extends EntityModel implements FacetProvider {
 
     private static final long serialVersionUID = 1L;
 
@@ -446,4 +447,5 @@ public class ScalarModel extends EntityM
         kind.resetVersion(this);
     }
 
+
 }

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.css
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.css?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.css (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.css Wed Sep  5 18:48:09 2012
@@ -22,6 +22,7 @@ table.collectionContentsAsAjaxTable {
 	border-bottom: 1px solid #407098;
 	font-size: 1em;
 	font-family: arial;
+	width: 95%
 }
 
 table.collectionContentsAsAjaxTable caption { text-align: left; }
@@ -46,7 +47,7 @@ table.collectionContentsAsAjaxTable tr t
 	padding-left: 8px; 
 	padding-right: 30px; 
 	background-color: #EEEEEE; 
-	border-bottom: 1px solid #407098; 
+	/*border-bottom: 1px solid #407098;*/ 
 	border-top: 1px solid #407098; 
 	text-align: left; 
 	white-space: nowrap; 

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/collectioncontents/ajaxtable/CollectionContentsAsAjaxTable.java Wed Sep  5 18:48:09 2012
@@ -67,7 +67,7 @@ public class CollectionContentsAsAjaxTab
         addSelectedButtonIfRequired(columns);
 
         final SortableDataProvider<ObjectAdapter> dataProvider = new CollectionContentsSortableDataProvider(model);
-        final AjaxFallbackDefaultDataTable<ObjectAdapter> dataTable = new AjaxFallbackDefaultDataTable<ObjectAdapter>("table", columns, dataProvider, 8);
+        final AjaxFallbackDefaultDataTable<ObjectAdapter> dataTable = new AjaxFallbackDefaultDataTable<ObjectAdapter>("table", columns, dataProvider, model.getPageSize());
         add(dataTable);
     }
 

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.css
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.css?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.css (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.css Wed Sep  5 18:48:09 2012
@@ -24,11 +24,15 @@ div.entitySummary {
 }
 
 div.entitySummary .iconAndTitle {
+	float: left;
     padding:1em;
 }
 
 div.entitySummary .actions {
+	float: left;
     padding:1em;
+	padding-top: 1.54em; 
+	padding-left: 50px;
 }
 
 .entitySummary .entityImage {
@@ -38,4 +42,7 @@ div.entitySummary .actions {
 	font-size: x-large;
 }
 
+div.entitySummary .clear {
+    clear: both;
+}
 

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.html
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.html?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.html (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/blocks/summary/EntitySummaryPanel.html Wed Sep  5 18:48:09 2012
@@ -36,7 +36,9 @@
              			</tbody>
       			   </table>
   			   </div>
+  			   <div class="clear"/>
 			</div>
 		</wicket:panel>
 	</body>
 </html>
+

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/combined/EntityCombinedPanel.css
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/combined/EntityCombinedPanel.css?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/combined/EntityCombinedPanel.css (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/entity/combined/EntityCombinedPanel.css Wed Sep  5 18:48:09 2012
@@ -27,9 +27,9 @@
 	-moz-column-width: 14em;
 	-webkit-column-width: 14em;
 	column-width: 14em;
-	
 }
 
+
 .entityCombined .entityProperties div.scalarPanel {
 }
 
@@ -43,10 +43,10 @@
 
 #entityPropertiesForLayout {
 	float: left;
-	width: 47%
+	width: 35%
 }
 
 #entityCollectionsForLayout {
 	float: right;
-	width: 47%
+	width: 64%
 }
\ No newline at end of file

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldAbstract.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldAbstract.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldAbstract.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldAbstract.java Wed Sep  5 18:48:09 2012
@@ -28,6 +28,9 @@ import org.apache.wicket.markup.html.for
 import org.apache.wicket.markup.html.panel.ComponentFeedbackPanel;
 import org.apache.wicket.model.Model;
 
+import org.apache.isis.core.metamodel.facetapi.FacetHolder;
+import org.apache.isis.core.metamodel.facetapi.FacetProvider;
+import org.apache.isis.core.metamodel.facets.SingleIntValueFacet;
 import org.apache.isis.core.metamodel.facets.maxlen.MaxLengthFacet;
 import org.apache.isis.core.metamodel.facets.typicallen.TypicalLengthFacet;
 import org.apache.isis.core.metamodel.spec.ObjectSpecification;
@@ -109,27 +112,27 @@ public abstract class ScalarPanelTextFie
     }
 
     private void setTextFieldSizeIfSpecified() {
-        final int size = determineSize();
-        if (size != -1) {
+        final Integer size = determineSize();
+        if (size != null) {
             textField.add(new AttributeModifier("size", true, new Model<String>("" + size)));
         }
     }
 
-    private int determineSize() {
-        final ScalarModel scalarModel = getModel();
-        final ObjectSpecification noSpec = scalarModel.getTypeOfSpecification();
-
-        final TypicalLengthFacet typicalLengthFacet = noSpec.getFacet(TypicalLengthFacet.class);
-        if (typicalLengthFacet != null) {
-            return typicalLengthFacet.value();
+    @SuppressWarnings("unchecked")
+    private Integer determineSize() {
+        return firstValueOf(getModel(), TypicalLengthFacet.class, MaxLengthFacet.class);
+    }
+    
+    private Integer firstValueOf(ScalarModel model, Class<? extends SingleIntValueFacet>... facetTypes) {
+        for(Class<? extends SingleIntValueFacet> facetType: facetTypes) {
+        final SingleIntValueFacet facet = model.getFacet(facetType);
+            if (facet != null) {
+                return facet.value();
+            }
         }
-        final MaxLengthFacet maxLengthFacet = noSpec.getFacet(MaxLengthFacet.class);
-        if (maxLengthFacet != null) {
-            return maxLengthFacet.value();
-        }
-        return -1;
+        return null;
     }
-
+    
     /**
      * Mandatory hook method to build the component to render the model when in
      * {@link Format#COMPACT compact} format.

Added: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldDatePickerAbstract.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldDatePickerAbstract.java?rev=1381293&view=auto
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldDatePickerAbstract.java (added)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/ScalarPanelTextFieldDatePickerAbstract.java Wed Sep  5 18:48:09 2012
@@ -0,0 +1,121 @@
+/*
+ *  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 org.apache.isis.viewer.wicket.ui.components.scalars;
+
+import java.util.Date;
+
+import org.apache.wicket.datetime.PatternDateConverter;
+import org.apache.wicket.datetime.markup.html.form.DateTextField;
+import org.apache.wicket.extensions.yui.calendar.DatePicker;
+import org.apache.wicket.markup.html.form.AbstractTextComponent;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.validation.IValidatable;
+import org.apache.wicket.validation.IValidator;
+import org.apache.wicket.validation.ValidationError;
+
+import org.apache.isis.core.metamodel.adapter.ObjectAdapter;
+import org.apache.isis.viewer.wicket.model.models.ScalarModel;
+
+/**
+ * Panel for rendering scalars representing dates, along with a date picker.
+ */
+public abstract class ScalarPanelTextFieldDatePickerAbstract<T> extends ScalarPanelTextFieldAbstract<java.util.Date> {
+
+    private static final long serialVersionUID = 1L;
+
+    private static final String DATE_PATTERN = "dd-MM-yyyy"; // TODO: yui calendar does not seem to understand 'dd-MMM-yyyy' (interprets as dd-MM-yyyy)
+    
+    private final String idScalarValue;
+
+    public ScalarPanelTextFieldDatePickerAbstract(final String id, String idScalarValue, final ScalarModel scalarModel) {
+        super(id, scalarModel);
+        this.idScalarValue = idScalarValue;
+    }
+
+    protected abstract java.util.Date asDate(final T pojo);
+    protected abstract T asPojo(final java.util.Date date);
+
+    @Override
+    protected AbstractTextComponent<java.util.Date> createTextField() {
+        final TextField<java.util.Date> textField = DateTextField.withConverter(idScalarValue, new Model<java.util.Date>() {
+            private static final long serialVersionUID = 1L;
+
+            @Override
+            public java.util.Date getObject() {
+                final ObjectAdapter adapter = getModel().getObject();
+                if (adapter == null) {
+                    return null;
+                }
+                @SuppressWarnings("unchecked")
+                final T pojo = (T) adapter.getObject();
+                final java.util.Date date = asDate(pojo);
+                return date;
+            }
+
+            @Override
+            public void setObject(final java.util.Date date) {
+                if(date == null) {
+                    getModel().setObject(null);
+                    return;
+                }
+                final T pojo = asPojo(date);
+                final ObjectAdapter adapter = adapterFor(pojo);
+                getModel().setObject(adapter);
+            }
+        }, new PatternDateConverter(DATE_PATTERN, true));
+        return textField;
+    }
+
+    @Override
+    protected void addSemantics() {
+        super.addSemantics();
+
+        final DatePicker datePicker = new DatePicker();
+        getTextField().add(datePicker);
+
+        addObjectAdapterValidator();
+    }
+
+    private void addObjectAdapterValidator() {
+        final AbstractTextComponent<Date> textField = getTextField();
+
+        textField.add(new IValidator<java.util.Date>() {
+            private static final long serialVersionUID = 1L;
+
+            @Override
+            public void validate(final IValidatable<java.util.Date> validatable) {
+                final java.util.Date proposedValue = validatable.getValue();
+                final T proposed = asPojo(proposedValue);
+                final ObjectAdapter proposedAdapter = adapterFor(proposed);
+                String reasonIfAny = scalarModel.validate(proposedAdapter);
+                if (reasonIfAny != null) {
+                    final ValidationError error = new ValidationError();
+                    error.setMessage(reasonIfAny);
+                    validatable.error(error);
+                }
+            }
+        });
+    }
+
+    private ObjectAdapter adapterFor(final Object pojo) {
+        return getAdapterManager().adapterFor(pojo);
+    }
+}

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java Wed Sep  5 18:48:09 2012
@@ -19,25 +19,31 @@
 
 package org.apache.isis.viewer.wicket.ui.components.scalars.jdkdates;
 
+import java.util.Date;
+
 import org.apache.isis.viewer.wicket.model.models.ScalarModel;
-import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelTextFieldParseableAbstract;
+import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelTextFieldDatePickerAbstract;
 
 /**
- * Panel for rendering scalars of type {@link JavaUtilDatePanel java.util.Date}.
+ * Panel for rendering scalars of type {@link java.util.Date}.
  */
-public class JavaUtilDatePanel extends ScalarPanelTextFieldParseableAbstract {
+public class JavaUtilDatePanel extends ScalarPanelTextFieldDatePickerAbstract<java.util.Date> {
 
     private static final long serialVersionUID = 1L;
     private static final String ID_SCALAR_VALUE = "scalarValue";
 
     public JavaUtilDatePanel(final String id, final ScalarModel scalarModel) {
         super(id, ID_SCALAR_VALUE, scalarModel);
+    }
 
+    @Override
+    protected Date asDate(Date pojo) {
+        return pojo;
     }
 
     @Override
-    protected void addSemantics() {
-        super.addSemantics();
+    protected Date asPojo(Date date) {
+        return date;
     }
 
 }

Copied: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.css (from r1380413, incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css)
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.css?p2=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.css&p1=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css&r1=1380413&r2=1381293&rev=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.css Wed Sep  5 18:48:09 2012
@@ -1,18 +1,18 @@
-/*
- *  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.
- */
+/*
+ *  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.
+ */

Copied: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.html (from r1380413, incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html)
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.html?p2=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.html&p1=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html&r1=1380413&r2=1381293&rev=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.html Wed Sep  5 18:48:09 2012
@@ -1,40 +1,40 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-  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.
--->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"  
-      xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd"  
-      xml:lang="en"  
-      lang="en">
-	<head></head>
-	<body>
-		<wicket:panel>
-			<div class="reference scalarPanel">
-				<label for="entityLink" wicket:id="scalarIfRegular">
-	      			<span wicket:id="scalarName" class="scalarName">[Label text]</span>
-	      			<span class="scalarValue">
-		      			<span class="entityLink" wicket:id="entityLink">[property or parameter value]</span>
-	      			</span>
-				</label>
-				<label wicket:id="scalarIfCompact"></label>
-      			<span wicket:id="feedback"></span>
-  			</div>
-		</wicket:panel>
-	</body>
-</html>
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  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.
+-->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"  
+      xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd"  
+      xml:lang="en"  
+      lang="en">
+	<head></head>
+	<body>
+		<wicket:panel>
+			<div class="javaUtilDate dateTime temporal scalarPanel">
+				<label for="scalarValue" wicket:id="scalarIfRegular">
+	      			<span wicket:id="scalarName" class="scalarName">[Label text]</span>
+	      			<span class="scalarValue">
+		      			<input type="text" name="scalarValue" id="scalarValue" wicket:id="scalarValue" />
+	      			</span>
+				</label>
+				<label wicket:id="scalarIfCompact"></label>
+      			<span style="padding-left: 100px" wicket:id="feedback"></span>
+			</div>
+		</wicket:panel>
+	</body>
+</html>

Copied: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.java (from r1380413, incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java)
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.java?p2=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.java&p1=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java&r1=1380413&r2=1381293&rev=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanel.java Wed Sep  5 18:48:09 2012
@@ -1,43 +1,51 @@
-/*
- *  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 org.apache.isis.viewer.wicket.ui.components.scalars.jdkdates;
-
-import org.apache.isis.viewer.wicket.model.models.ScalarModel;
-import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelTextFieldParseableAbstract;
-
-/**
- * Panel for rendering scalars of type {@link JavaUtilDatePanel java.util.Date}.
- */
-public class JavaUtilDatePanel extends ScalarPanelTextFieldParseableAbstract {
-
-    private static final long serialVersionUID = 1L;
-    private static final String ID_SCALAR_VALUE = "scalarValue";
-
-    public JavaUtilDatePanel(final String id, final ScalarModel scalarModel) {
-        super(id, ID_SCALAR_VALUE, scalarModel);
-
-    }
-
-    @Override
-    protected void addSemantics() {
-        super.addSemantics();
-    }
-
-}
+/*
+ *  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 org.apache.isis.viewer.wicket.ui.components.scalars.jodatime;
+
+import java.util.Date;
+
+import org.joda.time.LocalDate;
+
+import org.apache.isis.viewer.wicket.model.models.ScalarModel;
+import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelTextFieldDatePickerAbstract;
+
+/**
+ * Panel for rendering scalars of type {@link LocalDate}.
+ */
+public class JodaLocalDatePanel extends ScalarPanelTextFieldDatePickerAbstract<LocalDate> {
+
+    private static final long serialVersionUID = 1L;
+    private static final String ID_SCALAR_VALUE = "scalarValue";
+
+    public JodaLocalDatePanel(final String id, final ScalarModel scalarModel) {
+        super(id, ID_SCALAR_VALUE, scalarModel);
+    }
+
+    @Override
+    protected Date asDate(LocalDate pojo) {
+        return pojo.toDateTimeAtStartOfDay().toDate();
+    }
+
+    @Override
+    protected LocalDate asPojo(Date date) {
+        return new LocalDate(date.getTime());
+    }
+
+}

Copied: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanelFactory.java (from r1380413, incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java)
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanelFactory.java?p2=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanelFactory.java&p1=incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java&r1=1380413&r2=1381293&rev=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jdkdates/JavaUtilDatePanel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/jodatime/JodaLocalDatePanelFactory.java Wed Sep  5 18:48:09 2012
@@ -1,43 +1,45 @@
-/*
- *  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 org.apache.isis.viewer.wicket.ui.components.scalars.jdkdates;
-
-import org.apache.isis.viewer.wicket.model.models.ScalarModel;
-import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelTextFieldParseableAbstract;
-
-/**
- * Panel for rendering scalars of type {@link JavaUtilDatePanel java.util.Date}.
- */
-public class JavaUtilDatePanel extends ScalarPanelTextFieldParseableAbstract {
-
-    private static final long serialVersionUID = 1L;
-    private static final String ID_SCALAR_VALUE = "scalarValue";
-
-    public JavaUtilDatePanel(final String id, final ScalarModel scalarModel) {
-        super(id, ID_SCALAR_VALUE, scalarModel);
-
-    }
-
-    @Override
-    protected void addSemantics() {
-        super.addSemantics();
-    }
-
-}
+/*
+ *  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 org.apache.isis.viewer.wicket.ui.components.scalars.jodatime;
+
+import org.apache.wicket.Component;
+import org.joda.time.LocalDate;
+
+import org.apache.isis.viewer.wicket.model.models.ScalarModel;
+import org.apache.isis.viewer.wicket.ui.ComponentFactory;
+import org.apache.isis.viewer.wicket.ui.components.scalars.ComponentFactoryScalarAbstract;
+
+/**
+ * {@link ComponentFactory} for {@link JodaLocalDatePanel}.
+ */
+public class JodaLocalDatePanelFactory extends ComponentFactoryScalarAbstract {
+
+    private static final long serialVersionUID = 1L;
+
+    public JodaLocalDatePanelFactory() {
+        super(LocalDate.class);
+    }
+
+    @Override
+    public Component createComponent(final String id, final ScalarModel scalarModel) {
+        return new JodaLocalDatePanel(id, scalarModel);
+    }
+
+}

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.css Wed Sep  5 18:48:09 2012
@@ -16,3 +16,8 @@
  *  specific language governing permissions and limitations
  *  under the License.
  */
+
+.reference .scalarIfCompact .scalarValue {
+	float: none;
+}
+ 
\ No newline at end of file

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.html Wed Sep  5 18:48:09 2012
@@ -26,13 +26,17 @@
 	<body>
 		<wicket:panel>
 			<div class="reference scalarPanel">
-				<label for="entityLink" wicket:id="scalarIfRegular">
+				<label for="entityLink" wicket:id="scalarIfRegular" class="scalarIfRegular">
 	      			<span wicket:id="scalarName" class="scalarName">[Label text]</span>
 	      			<span class="scalarValue">
 		      			<span class="entityLink" wicket:id="entityLink">[property or parameter value]</span>
 	      			</span>
 				</label>
-				<label wicket:id="scalarIfCompact"></label>
+				<label wicket:id="scalarIfCompact" class="scalarIfCompact">
+	      			<span class="scalarValue">
+		      			<span class="entityLink" wicket:id="entityLink">[property or parameter value]</span>
+	      			</span>
+				</label>
       			<span wicket:id="feedback"></span>
   			</div>
 		</wicket:panel>

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.java
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.java?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.java (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/scalars/reference/ReferencePanel.java Wed Sep  5 18:48:09 2012
@@ -79,25 +79,25 @@ public class ReferencePanel extends Scal
     protected FormComponentLabel addComponentForRegular() {
         final ScalarModel scalarModel = getModel();
         final String name = scalarModel.getName();
-
+        
         entityLink = (EntityLink) getComponentFactoryRegistry().createComponent(ComponentType.ENTITY_LINK, getModel());
-
+        
         entityLink.setOutputMarkupId(true);
         entityLink.setLabel(Model.of(name));
-
+        
         final FormComponentLabel labelIfRegular = new FormComponentLabel(ID_SCALAR_IF_REGULAR, entityLink);
-
         labelIfRegular.add(entityLink);
+        
         final Label scalarName = new Label(ID_SCALAR_NAME, getFormat().getLabelCaption(entityLink));
         labelIfRegular.add(scalarName);
-
+        
         addOrReplace(labelIfRegular);
-
+        
         addOrReplace(new ComponentFeedbackPanel(ID_FEEDBACK, entityLink));
-
+        
         addStandardSemantics();
         addSemantics();
-
+        
         return labelIfRegular;
     }
 
@@ -142,9 +142,40 @@ public class ReferencePanel extends Scal
      */
     @Override
     protected Component addComponentForCompact() {
-        final Label labelIfCompact = new Label(ID_SCALAR_IF_COMPACT, getModel().getObjectAsString());
+
+        //final Label labelIfCompact = new Label(ID_SCALAR_IF_COMPACT, getModel().getObjectAsString());
+        //addOrReplace(labelIfCompact);
+        //return labelIfCompact;
+
+        
+        final ScalarModel scalarModel = getModel();
+        final String name = scalarModel.getName();
+        
+        entityLink = (EntityLink) getComponentFactoryRegistry().createComponent(ComponentType.ENTITY_LINK, getModel());
+        
+        entityLink.setOutputMarkupId(true);
+        entityLink.setLabel(Model.of(name));
+        
+        final FormComponentLabel labelIfCompact = new FormComponentLabel(ID_SCALAR_IF_COMPACT, entityLink);
+        labelIfCompact.add(entityLink);
+        
+//        final Label scalarName = new Label(ID_SCALAR_NAME, getFormat().getLabelCaption(entityLink));
+//        labelIfCompact.add(scalarName);
+        
         addOrReplace(labelIfCompact);
+        
+        addOrReplace(new ComponentFeedbackPanel(ID_FEEDBACK, entityLink));
+        
+//        addStandardSemantics();
+//        addSemantics();
+        
         return labelIfCompact;
+        
+        //return addComponentIfCompact(idScalar);
     }
 
+//    @SuppressWarnings("unused")
+//    private Component addComponentIfCompact(final String idScalar) {
+//    }
+
 }

Modified: incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/widgets/entitylink/EntityLink.html
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/widgets/entitylink/EntityLink.html?rev=1381293&r1=1381292&r2=1381293&view=diff
==============================================================================
--- incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/widgets/entitylink/EntityLink.html (original)
+++ incubator/isis/trunk/framework/viewer/wicket/wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/widgets/entitylink/EntityLink.html Wed Sep  5 18:48:09 2012
@@ -31,10 +31,11 @@
 		<wicket:panel>
 			<span class="entityLink">
 				<input type="text" wicket:id="entityOid"/>
-				<img wicket:id="entityImage" class="entityImage" width="16" height="16"/>
+				
 				<select wicket:id="choices"/>
 				<span wicket:id="entityLinkWrapper">
 					<a href="#" wicket:id="entityLink">
+						<img wicket:id="entityImage" class="entityImage" width="16" height="16"/>
 						<span wicket:id="entityTitle">[property or parameter value]</span>
 					</a>
 				</span>



Mime
View raw message