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 2012/10/12 19:17:28 UTC

svn commit: r1397650 [10/12] - in /incubator/isis/trunk/framework/quickstart-archetype/archetype: ./ src/ src/main/ src/main/resources/ src/main/resources/META-INF/ src/main/resources/META-INF/maven/ src/main/resources/archetype-resources/ src/main/res...

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.css
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.css?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.css (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.css Fri Oct 12 17:17:19 2012
@@ -0,0 +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.
+ */

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.js
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.js?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.js (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/app.js Fri Oct 12 17:17:19 2012
@@ -0,0 +1,24 @@
+var util    = namespace('org.apache.isis.viewer.json.jqmobile.util');
+var generic = namespace('org.apache.isis.viewer.json.jqmobile.generic');
+
+$(function() {
+  $("#settings-theme input").click(function(e) {
+    
+    var theme = e.currentTarget.value;
+    $("div[data-role='page']").each( function() {
+      $(this).attr("data-theme", e);
+      // TODO: how refresh?
+    });
+  });
+
+  $(document).bind("pagebeforechange", generic.submitRenderAndNavigate);
+
+  // if user manually refreshes page for domain object, then re-retrieve
+  var locationHref = location.href;
+  if(locationHref.indexOf("genericDomainObjectView") != -1) {
+    var urlHref = generic.extract(locationHref);
+    generic.submitAndRender(urlHref, "pop");
+  } else {
+    $.mobile.changePage($("#home"))
+  }
+});
\ No newline at end of file

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/generic.js
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/generic.js?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/generic.js (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/generic.js Fri Oct 12 17:17:19 2012
@@ -0,0 +1,226 @@
+var util = namespace('org.apache.isis.viewer.json.jqmobile.util');
+var generic = namespace('org.apache.isis.viewer.json.jqmobile.generic');
+
+generic.itemLinks = function(jsonItems) { 
+  var items = $.map(jsonItems, function(value, i) {
+    return {
+      "hrefUrlEncoded" : util.urlencode(value.href),
+      "title" : value.title,
+      "href" : value.href
+    }
+  })
+  return items
+}
+
+generic.extract = function(urlHref) {
+  // does it match: foobar.html?dataUrl=xxx; if so, then return xxx
+  var matches = /.*?dataUrl=(.*)/.exec(urlHref)
+  var url = matches && matches[1]
+  if(url) {
+    return util.urldecode(url)
+  }
+  // does it simply match foobar.html; if so, then return null
+  if ( /.*\.html$/.test(urlHref)) {
+    return null
+  }
+  // simply return the URL, assuming it is the data url we need to get.
+  return urlHref
+}
+
+generic.returnTypeFor = function(memberItem) {
+  var detailsJson = util.grepAndFollowLink(memberItem.links, "details")
+  if (!detailsJson) {
+    return null;
+  }
+  var describedByJson = util.grepAndFollowLink(detailsJson.links, "describedby")
+  if (!describedByJson) {
+    return null;
+  }
+  var returnTypeLink = util.grepLink(describedByJson.links, "returntype")
+  return returnTypeLink? returnTypeLink.href : null;
+}
+
+generic.dataTypeFor = function(memberItem) {
+  var returnType = generic.returnTypeFor(memberItem);
+  if(returnType.endsWith("boolean")) return "boolean"
+  return "string"
+}
+
+generic.pageAndOptions = function(page, view, dataUrl, transition) {
+  var pageAndOptions = {
+      "page": page,
+      "options": { 
+         "dataUrl": "#" + view + "?dataUrl=" + util.urlencode(dataUrl),
+         "allowSamePageTransition": true,
+         "transition": transition
+       }
+    }
+  return pageAndOptions
+}
+
+generic.handleDomainObjectRepresentation = function(urlHref, pageChangeData, json, xhr) {
+  
+  var page = $("#genericDomainObjectView");
+  var header = page.children(":jqmData(role=header)");
+  var content = page.children(":jqmData(role=content)");
+  
+  header.find("h1").html(json.title);
+
+  // value properties
+  var valueProperties = json.members.filter(function(item) {
+    return item.memberType === "property" && item.value && !item.value.href;
+  });
+  
+  valueProperties = $.map( valueProperties, function(value, i) {
+    var dataType = generic.dataTypeFor(value)
+    return {
+      "id": value.id,
+      "value": value.value,
+      "dataTypeIsString": dataType === "string",
+      "dataTypeIsBoolean": dataType === "boolean"
+    }
+  } );
+
+  var valuePropertiesDiv = page.children(":jqmData(role=content)").find(".valueProperties");
+  var valuePropertiesTemplateDiv = page.children(".valueProperties-tmpl");
+  util.applyTemplateDiv(valueProperties, valuePropertiesDiv, valuePropertiesTemplateDiv);
+
+  
+  // reference properties
+  var referenceProperties = json.members.filter(function(item) {
+    return item.memberType === "property" && item.value && item.value.href;
+  });
+  var referencePropertiesList = page.children(":jqmData(role=content)").find(".referenceProperties");
+  var referencePropertiesTemplateDiv = page.children(".referenceProperties-tmpl");
+  util.applyTemplateDiv(referenceProperties, referencePropertiesList, referencePropertiesTemplateDiv);
+
+  var collections = json.members.filter(function(item) {
+    return item.memberType === "collection";
+  }).map(function(value, i) {
+    var href = util.grepLink(value.links, "details").href
+    return {
+      "hrefUrlEncoded" : util.urlencode(value.links[0].href),
+      "id" : value.id,
+      "href" : value.links[0].href
+    }
+  });
+
+  // collections
+  var collectionsList = page.children(":jqmData(role=content)").find(".collections");
+  var collectionsTemplateDiv = page.children(".collections-tmpl");
+  util.applyTemplateDiv(collections, collectionsList, collectionsTemplateDiv);
+
+  page.page();
+  content.find( ":jqmData(role=listview)" ).listview("refresh");
+  page.trigger("create");
+
+  return generic.pageAndOptions(page, "genericDomainObjectView", urlHref)
+} 
+
+
+generic.handleListRepresentation = function(urlHref, pageChangeData, json, xhr) {
+  
+  var page = $("#genericListView");
+  var header = page.children(":jqmData(role=header)");
+  var content = page.children(":jqmData(role=content)");
+
+  var items = generic.itemLinks(json.value)
+
+  header.find("h1").html("Objects");
+
+  var div = page.find("ul");
+  var templateDiv = page.find(".tmpl");
+  
+  util.applyTemplateDiv(items, div, templateDiv);
+
+  page.page();
+  content.find( ":jqmData(role=listview)" ).listview("refresh");
+  page.trigger("create");
+
+  return generic.pageAndOptions(page, "genericListView", urlHref)
+}
+
+generic.handleObjectCollectionRepresentation = function(urlHref, pageChangeData, json, xhr) {
+  
+  var page = $("#genericObjectCollectionView");
+  var header = page.children(":jqmData(role=header)");
+  var content = page.children(":jqmData(role=content)");
+
+  var items = generic.itemLinks(json.value)
+
+  var parentTitle = util.grepLink(json.links, "up").title
+  
+  var collectionId = json.id;
+  header.find("h1").html(collectionId + " for " + parentTitle);
+
+  var div = page.find("ul");
+  var templateDiv = page.find(".tmpl");
+  util.applyTemplateDiv(items, div, templateDiv);
+
+  page.page();
+  content.find( ":jqmData(role=listview)" ).listview("refresh");
+  page.trigger("create");
+
+  return generic.pageAndOptions(page, "genericObjectCollectionView", urlHref, "slideup")
+}
+
+
+generic.actionResultHandlers = {
+    "object": generic.handleDomainObjectRepresentation,
+    "list": generic.handleListRepresentation
+}
+
+generic.handleActionResultRepresentation = function(urlHref, pageChangeData, json, xhr) {
+  var resultType = json.resulttype
+  var handler = generic.actionResultHandlers[resultType];
+  if(!handler) {
+    alert("unable to handle result type")
+    return;
+  } 
+  return handler(urlHref, pageChangeData, json.result, xhr)
+}
+
+generic.handlers = {
+    "application/json;profile=\"urn:org.restfulobjects/domainobject\"": generic.handleDomainObjectRepresentation,
+    "application/json; profile=\"urn:org.restfulobjects/domainobject\"": generic.handleDomainObjectRepresentation,
+    "application/json;profile=\"urn:org.restfulobjects/list\"": generic.handleListRepresentation,
+    "application/json; profile=\"urn:org.restfulobjects/list\"": generic.handleListRepresentation,
+    "application/json;profile=\"urn:org.restfulobjects/objectcollection\"": generic.handleObjectCollectionRepresentation,
+    "application/json; profile=\"urn:org.restfulobjects/objectcollection\"": generic.handleObjectCollectionRepresentation,
+    "application/json;profile=\"urn:org.restfulobjects/actionresult\"": generic.handleActionResultRepresentation,
+    "application/json; profile=\"urn:org.restfulobjects/actionresult\"": generic.handleActionResultRepresentation
+}
+
+generic.submitAndRender = function(urlHref, pageChangeData) {
+  $.ajax({
+    url : urlHref,
+    dataType : 'json',
+    success : function(json, str, xhr) {
+      var contentType = xhr.getResponseHeader("Content-Type");
+      var handler = generic.handlers[contentType];
+      if(!handler) {
+        alert("unable to handle response")
+        return;
+      } 
+      var pageAndOptions = handler(urlHref, pageChangeData, json, xhr)
+
+      $.mobile.changePage(pageAndOptions.page, pageAndOptions.options);
+    }
+  })
+}
+
+generic.submitRenderAndNavigate = function(e, pageChangeData) {
+  if (typeof pageChangeData.toPage !== "string") {
+    return;
+  }
+
+  var url = $.mobile.path.parseUrl(pageChangeData.toPage)
+  var urlHref = generic.extract(url.href)
+  if(!urlHref) {
+    return;
+  }
+
+  generic.submitAndRender(urlHref, pageChangeData);
+  e.preventDefault();
+}
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/index.html
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/index.html?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/index.html (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/index.html Fri Oct 12 17:17:19 2012
@@ -0,0 +1,205 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+<!DOCTYPE html>
+<html>
+
+<head>
+<meta charset="utf-8">
+<meta name="viewport" content="initial-scale=1, width=device-width, target-densitydpi=device-dpi"/>
+
+<title>Apache Isis Online Demo</title>
+
+<link rel="stylesheet" href="../jquery.mobile/jquery.mobile-1.0.css" />
+
+<script src="../jquery/jquery-1.6.4.js"></script>
+<script src="../jquery.mobile/jquery.mobile-1.0.js"></script>
+<script src="../jquery.tmpl/jquery.tmpl-vBeta1.0.0.js"></script>
+
+<link rel="stylesheet" type="text/css" href="app.css" />
+
+<script type="text/javascript" src="namespace.js"></script>
+<script type="text/javascript" src="util.js"></script>
+<script type="text/javascript" src="generic.js"></script>
+<script type="text/javascript" src="app.js"></script>
+</head>
+
+<body id="pageHolder">
+	<div data-role="page" id="home">
+
+		<div data-role="header">
+			<h1>Home</h1>
+		</div>
+
+		<div data-role="content">
+            <br/>
+            <button>Tasks</button>
+            <ul data-role="listview" class="tasks"></ul>
+		</div>
+
+        <script class="tmpl" type="text/x-jquery-tmpl">
+            <li>
+                <a href="${symbol_dollar}{href}">${symbol_dollar}{title}</a>
+            </li>
+        </script>
+        
+        <script type="text/javascript">
+            ${symbol_dollar}("${symbol_pound}home button").click(function(){
+                ${symbol_dollar}.mobile.changePage("../services/toDoItems/actions/notYetDone/invoke", "pop")
+            });
+        </script>
+
+        <div data-role="footer" data-id="global-footer" data-position="fixed">
+            <a href="../index.html"  rel="external">home</a>&nbsp;|&nbsp;<a href="../services" rel="external">rest</a>&nbsp;|&nbsp;<a href="../logon.htmlviewer" rel="external">html</a>&nbsp;|&nbsp;<a href="../index.shtml" rel="external">scimpi</a>
+        </div>
+	</div>
+
+    <div data-role="page" id="genericListView">
+
+        <div data-role="header">
+            <a data-icon="back" data-rel="back">Back</a>
+            <h1>List</h1>
+        </div>
+
+        <div data-role="content">
+            <br/>
+            <ul data-filter="true" data-role="listview"></ul>
+        </div>
+
+        <script class="tmpl" type="text/x-jquery-tmpl">
+            <li>
+                <a href="${symbol_dollar}{href}">${symbol_dollar}{title}</a>
+            </li>
+        </script>
+
+        <div data-role="footer" data-id="global-footer" data-position="fixed">
+            <a href="../index.html"  rel="external">home</a>&nbsp;|&nbsp;<a href="../services" rel="external">rest</a>&nbsp;|&nbsp;<a href="../logon.htmlviewer" rel="external">html</a>&nbsp;|&nbsp;<a href="../index.shtml" rel="external">scimpi</a>
+        </div>
+    </div>
+
+    <div data-role="page" id="genericObjectCollectionView">
+
+        <div data-role="header">
+            <a data-icon="back" data-rel="back">Back</a>
+            <h1>Collection</h1>
+        </div>
+
+        <div data-role="content">
+            <br/>
+            <ul data-filter="true" data-role="listview"></ul>
+        </div>
+
+        <script class="tmpl" type="text/x-jquery-tmpl">
+            <li>
+                <a href="${symbol_dollar}{href}">${symbol_dollar}{title}</a>
+            </li>
+        </script>
+
+        <div data-role="footer" data-id="global-footer" data-position="fixed">
+            <a href="../index.html"  rel="external">home</a>&nbsp;|&nbsp;<a href="../services" rel="external">rest</a>&nbsp;|&nbsp;<a href="../logon.htmlviewer" rel="external">html</a>&nbsp;|&nbsp;<a href="../index.shtml" rel="external">scimpi</a>
+        </div>
+    </div>
+
+    <div data-role="page" id="genericDomainObjectView">
+
+        <div data-role="header">
+            <a data-icon="back" data-rel="back">Back</a>
+            <h1>Object</h1>
+        </div>
+
+        <div data-role="content">
+            <div class="valueProperties"></div>
+            <br/>
+            <p>References</p>
+            <ul data-role="listview" data-inset="true" class="referenceProperties"></ul>
+            <br/>
+            <p>Collections</p>
+            <ul data-role="listview" data-inset="true" class="collections"></ul>
+        </div>
+
+        <script class="valueProperties-tmpl" type="text/x-jquery-tmpl">
+            {{if dataTypeIsString}}
+                <label for="${symbol_dollar}{id}">${symbol_dollar}{id}:</label>
+                <input type="text"
+                    name="${symbol_dollar}{id}" id="${symbol_dollar}{id}" value="${symbol_dollar}{value}" placeholder="${symbol_dollar}{id}"
+                    class="required"/>
+            {{/if}}
+            {{if dataTypeIsBoolean}}
+                <div data-role="fieldcontain">
+                    <fieldset data-role="controlgroup">
+                        <legend>${symbol_dollar}{id}?</legend>
+                        <input type="checkbox" 
+                            name="${symbol_dollar}{id}" id="${symbol_dollar}{id}" value="${symbol_dollar}{value}"
+                            class="required"/>
+                        <label for="${symbol_dollar}{id}">${symbol_dollar}{id}</label>
+                    </fieldset>
+                </div>
+            {{/if}}
+         </script>
+
+        <script class="referenceProperties-tmpl" type="text/x-jquery-tmpl">
+            <li>
+                <a data-transition="slide" href="${symbol_dollar}{value.href}">
+                    <p>${symbol_dollar}{id}</p>
+                    <p><b>${symbol_dollar}{value.title}</b></p>
+                </a>
+            </li>
+         </script>
+
+        <script class="collections-tmpl" type="text/x-jquery-tmpl">
+            <li>
+                <a data-transition="slideup" href="${symbol_dollar}{href}">${symbol_dollar}{id}</a>
+            </li>
+         </script>
+
+        <div data-role="footer" data-id="global-footer" data-position="fixed">
+            <a href="../index.html"  rel="external">home</a>&nbsp;|&nbsp;<a href="../services" rel="external">rest</a>&nbsp;|&nbsp;<a href="../logon.htmlviewer" rel="external">html</a>&nbsp;|&nbsp;<a href="../index.shtml" rel="external">scimpi</a>
+        </div>
+    </div>
+
+	<div data-role="page" id="settings" data-add-back-btn="true">
+
+		<div data-role="header">
+			<h1>Settings</h1>
+		</div>
+
+		<div data-role="content">
+            
+            <fieldset id="settings-theme">
+                <legend>Theme:</legend>
+                    <input type="radio" name="settings-theme" id="settings-theme-a" value="a" checked="checked" />
+                    <label for="settings-theme-a">Dark</label>
+        
+                    <input type="radio" name="settings-theme" id="settings-theme-b" value="b"/>
+                    <label for="settings-theme-b">Blue</label>
+        
+                    <input type="radio" name="settings-theme" id="settings-theme-c" value="c"/>
+                    <label for="settings-theme-c">Grey</label>
+        
+                    <input type="radio" name="settings-theme" id="settings-theme-d" value="d"/>
+                    <label for="settings-theme-d">White</label>
+        
+                    <input type="radio" name="settings-theme" id="settings-theme-e" value="e"/>
+                    <label for="settings-theme-e">Yellow</label>
+            </fieldset>
+
+        </div>
+        
+        <script type="text/javascript">
+            ${symbol_dollar}("${symbol_pound}settings input").change(function(e){
+                var theme = ${symbol_dollar}(this).attr("value");
+                ${symbol_dollar}("div").filter( function() {
+                    var divDataRole = ${symbol_dollar}(this).attr("data-role")
+                    var isPage = (divDataRole === "page"); 
+                    return isPage;
+                }).attr("data-theme", theme);
+            });
+        </script>
+
+        <div data-role="footer" data-id="global-footer" data-position="fixed">
+            <a href="../index.html"  rel="external">home</a>&nbsp;|&nbsp;<a href="../services" rel="external">rest</a>&nbsp;|&nbsp;<a href="../logon.htmlviewer" rel="external">html</a>&nbsp;|&nbsp;<a href="../index.shtml" rel="external">scimpi</a>
+        </div>
+	</div>
+
+</body>
+</html>
\ No newline at end of file

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/namespace.js
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/namespace.js?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/namespace.js (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/namespace.js Fri Oct 12 17:17:19 2012
@@ -0,0 +1,13 @@
+namespace = function(namespaceString) {
+    var parts = namespaceString.split('.'),
+        parent = window,
+        currentPart = '';    
+
+    for(var i = 0, length = parts.length; i < length; i++) {
+        currentPart = parts[i];
+        parent[currentPart] = parent[currentPart] || {};
+        parent = parent[currentPart];
+    }
+
+    return parent;
+}
\ No newline at end of file

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/util.js
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/util.js?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/util.js (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-restfulobjects/src/main/webapp/mobile/util.js Fri Oct 12 17:17:19 2012
@@ -0,0 +1,94 @@
+String.prototype.endsWith = function(pattern) {
+    var d = this.length - pattern.length;
+    return d >= 0 && this.lastIndexOf(pattern) === d;
+};
+
+
+var util = namespace('org.apache.isis.viewer.json.jqmobile.util');
+
+util.findPage = function(selector) {
+  var page = $("#pageHolder").find(selector);
+  if(page[0]) {
+    return page[0];
+  }
+  return null
+}
+
+util.removePage = function(id) {
+  var page = util.findPage(id)
+  if(page) {
+    page.remove();
+  }
+}
+
+util.cloneAndInsertPage = function(sourceId, targetId) {
+  var page = $("#"+sourceId).clone().attr("id", targetId);
+  page.appendTo("#pageHolder");
+  return page
+}
+
+util.grepLink = function(links, relStr) {
+  return $.grep(links, function(v) { return v.rel === relStr } )[0]
+}
+
+util.followLink = function(link) {
+  var response = {};
+  $.ajax({
+    url : link.href,
+    dataType : 'json',
+    async: false,
+    success : function(json, str, xhr) {
+      response = { 
+          "json": json,
+          "str": str,
+          "xhr": xhr
+      }
+    }
+  })
+  return response;
+}
+
+util.grepAndFollowLink = function(links, rel) {
+  var link = util.grepLink(links, rel)
+  if (!link) { return null; }
+  var response = util.followLink(link);
+  if (!response) { return null; }
+  return response.json;
+}
+
+util.queryParamsFor = function (href) {
+    var vars = [], hash;
+    var hashes = href.slice(href.indexOf('?') + 1).split('&');
+    for(var i = 0; i < hashes.length; i++)
+    {
+        hash = hashes[i].split('=');
+        vars.push(hash[0]);
+        vars[hash[0]] = urldecode(hash[1]);
+    }
+    return vars;
+}
+
+// from http://phpjs.org/functions/urlencode:573
+util.urlencode = function(str) {
+    str = (str + '').toString();
+    return encodeURIComponent(str).replace(/!/g, '%21').replace(/'/g, '%27').replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/\*/g, '%2A').replace(/%20/g, '+');
+}
+
+// from http://phpjs.org/functions/urldecode:572
+util.urldecode = function(str) {
+	return decodeURIComponent((str + '').replace(/\+/g, '%20'));
+}
+
+util.applyTemplate = function(data, selector, templateSelector) {
+    $(selector).empty();
+    $(templateSelector)
+        .tmpl(data)
+        .appendTo(selector);
+}
+
+util.applyTemplateDiv = function(data, div, templateDiv) {
+  div.empty();
+  templateDiv
+      .tmpl(data)
+      .appendTo(div);
+}
\ No newline at end of file

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/ide/eclipse/launch/quickstart-viewer-scimpi.launch
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/ide/eclipse/launch/quickstart-viewer-scimpi.launch?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/ide/eclipse/launch/quickstart-viewer-scimpi.launch (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/ide/eclipse/launch/quickstart-viewer-scimpi.launch Fri Oct 12 17:17:19 2012
@@ -0,0 +1,23 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+<?xml version="1.0" encoding="UTF-8"?>
+<launchConfiguration type="org.eclipse.jdt.launching.localJavaApplication">
+  <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+    <listEntry value="/org.apache.isis.runtimes.dflt.webserver/src/main/java/org/apache/isis/WebServer.java"/>
+  </listAttribute>
+  <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+    <listEntry value="1"/>
+  </listAttribute>
+  <mapAttribute key="org.eclipse.debug.core.preferred_launchers">
+    <mapEntry value="org.eclipse.jdt.launching.localJavaApplication" key="[debug]"/>
+    <mapEntry value="org.eclipse.jdt.launching.localJavaApplication" key="[run]"/>
+  </mapAttribute>
+  <stringAttribute value="org.eclipse.jdt.launching.sourceLocator.JavaSourceLookupDirector" key="org.eclipse.debug.core.source_locator_id"/>
+  <booleanAttribute value="true" key="org.eclipse.jdt.debug.ui.INCLUDE_EXTERNAL_JARS"/>
+  <stringAttribute value="org.eclipse.m2e.launchconfig.classpathProvider" key="org.eclipse.jdt.launching.CLASSPATH_PROVIDER"/>
+  <stringAttribute value="org.apache.isis.WebServer" key="org.eclipse.jdt.launching.MAIN_TYPE"/>
+  <stringAttribute value="--type server_exploration" key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS"/>
+  <stringAttribute value="${rootArtifactId}-viewer-scimpi" key="org.eclipse.jdt.launching.PROJECT_ATTR"/>
+  <stringAttribute value="org.eclipse.m2e.launchconfig.sourcepathProvider" key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER"/>
+</launchConfiguration>

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/lib/.gitignore
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/lib/.gitignore?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/lib/.gitignore (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/lib/.gitignore Fri Oct 12 17:17:19 2012
@@ -0,0 +1,5 @@
+#
+# explicitly ignoring Microsoft JDBC4 jar
+# (cannot redistribute, licensing)
+#
+sqljdbc4.jar

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/pom.xml
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/pom.xml?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/pom.xml (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/pom.xml Fri Oct 12 17:17:19 2012
@@ -0,0 +1,201 @@
+<?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.
+--><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>${groupId}</groupId>
+        <artifactId>${rootArtifactId}</artifactId>
+        <version>${version}</version>
+    </parent>
+
+	<artifactId>${artifactId}</artifactId>
+	<name>Quickstart Scimpi Viewer</name>
+	
+	<description>This module runs Isis' Scimpi webapp viewer.  By default it is configured to
+	run using the in-memory object store, but it can be easily switched to, for example, the
+	mongo or fileserver object store by updating isis.properties.  
+	See other viewer modules for more persistence options.</description>
+	
+	<packaging>war</packaging>
+
+	<build>
+		<plugins>
+            <plugin>
+                <groupId>org.mortbay.jetty</groupId>
+                <artifactId>maven-jetty-plugin</artifactId>
+            </plugin>
+
+            <!-- mvn package -->
+            <plugin>
+                <groupId>org.simplericity.jettyconsole</groupId>
+                <artifactId>jetty-console-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <goals>
+                            <goal>createconsole</goal>
+                        </goals>
+                        <configuration>
+                            <backgroundImage>${basedir}/src/main/jettyconsole/isis-banner.png</backgroundImage>
+                        </configuration>
+                        <phase>package</phase>
+                    </execution>
+                </executions>
+            </plugin>
+
+            <!-- prereqs: mvn package -->
+            <!-- mvn antrun:run -->
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-antrun-plugin</artifactId>
+                <configuration>
+                    <tasks>
+                        <exec executable="java" failonerror="true">
+                            <arg value="-jar" />
+                            <arg value="${project.build.directory}/${project.build.finalName}-jetty-console.war" />
+                        </exec>
+                    </tasks>
+                </configuration>
+            </plugin>
+
+		</plugins>
+	</build>
+
+	<dependencies>
+	
+        <!-- other modules in this project -->
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>${rootArtifactId}-dom</artifactId>
+        </dependency>
+        
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>${rootArtifactId}-fixture</artifactId>
+        </dependency>
+
+
+
+        <!-- objectstore/domain service/repository implementations -->
+
+        <!--
+         - uncomment in order to use default object store
+         - (also edit isis.properties)
+         - 
+        -->
+		<dependency>
+			<groupId>org.apache.isis.runtimes.dflt.objectstores</groupId>
+			<artifactId>dflt</artifactId>
+		</dependency>
+        
+        <!--
+         - uncomment in order to use jdo object store
+         - (also edit isis.properties)
+         -
+         - (also uncomment in order to install facet factories used to
+         -  filter out any JDO enhancement to pojos) 
+        -->
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>${rootArtifactId}-objstore-jdo</artifactId>
+        </dependency>
+        
+
+
+        <!-- isis viewer -->
+        <dependency>
+            <groupId>org.apache.isis.viewer</groupId>
+            <artifactId>scimpi-servlet</artifactId>
+        </dependency>
+
+
+        <!-- isis runtime -->
+        <dependency>
+            <groupId>org.apache.isis.runtimes.dflt.bytecode</groupId>
+            <artifactId>dflt</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.isis.runtimes.dflt.profilestores</groupId>
+            <artifactId>dflt</artifactId>
+        </dependency>
+        
+        <!-- isis progmodel -->
+        <dependency>
+            <groupId>org.apache.isis.progmodels</groupId>
+            <artifactId>dflt</artifactId>
+        </dependency>
+
+        <!-- isis security implementations -->        
+        <dependency>
+            <groupId>org.apache.isis.security</groupId>
+            <artifactId>file</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.isis.security</groupId>
+            <artifactId>dflt</artifactId>
+        </dependency>
+        
+        <!-- to run using WebServer (optional) -->
+        <dependency>
+            <groupId>org.apache.isis.runtimes.dflt</groupId>
+            <artifactId>webserver</artifactId>
+            <scope>runtime</scope>
+            <optional>true</optional>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-servlet_2.5_spec</artifactId>
+            <version>1.2</version>
+        </dependency>
+
+
+
+		<!-- 
+		  JDBC drivers 
+		  (if using jdo or sql object store)
+		  -->
+
+        <dependency>
+            <groupId>org.hsqldb</groupId>
+            <artifactId>hsqldb</artifactId>
+            <version>2.2.8</version>
+        </dependency>
+
+		<!-- 
+		<dependency>
+			<groupId>com.microsoft.sqlserver</groupId>
+			<artifactId>jdbc</artifactId>
+			<version>4.0</version>
+			<scope>system</scope>
+			<optional>true</optional>
+			<systemPath>${basedir}/lib/sqljdbc4.jar</systemPath>
+		</dependency>
+		-->	
+			
+		<dependency>
+		  <groupId>org.lazyluke</groupId>
+		  <artifactId>log4jdbc-remix</artifactId>
+		  <version>0.2.7</version>
+		</dependency>
+
+	</dependencies>
+
+</project>

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.pdn
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.pdn?rev=1397650&view=auto
==============================================================================
Files incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.pdn (added) and incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.pdn Fri Oct 12 17:17:19 2012 differ

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.png
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.png?rev=1397650&view=auto
==============================================================================
Files incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.png (added) and incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/jettyconsole/isis-banner.png Fri Oct 12 17:17:19 2012 differ

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/resources/images/Default.png
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/resources/images/Default.png?rev=1397650&view=auto
==============================================================================
Files incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/resources/images/Default.png (added) and incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/resources/images/Default.png Fri Oct 12 17:17:19 2012 differ

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/edit.shtml
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/edit.shtml?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/edit.shtml (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/edit.shtml Fri Oct 12 17:17:19 2012
@@ -0,0 +1,27 @@
+<?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.
+-->
+<swf:page-title>Edit <swf:title icon="no" /></swf:page-title>
+<swf:template  file="../scimpi/style/template.shtml" />
+
+<swf:edit title="Change Item">
+    <swf:exclude name="done" />
+</swf:edit>
+
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/object.shtml
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/object.shtml?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/object.shtml (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/ToDoItem/object.shtml Fri Oct 12 17:17:19 2012
@@ -0,0 +1,32 @@
+<?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.
+-->
+<swf:page-title><swf:title-string /></swf:page-title>
+<swf:template  file="../scimpi/style/template.shtml" />
+
+<h2>To Do: <em><swf:title-string /></em></h2>
+<swf:short-form title=""/>
+
+<swf:edit-link show-as-button="true" container-class="action">Change Item</swf:edit-link>
+<swf:action-button method="markAsDone" />
+<swf:action-button method="markAsNotDone" />
+
+<p class="alternative">View object in <a href="/generic/object.shtml?_result=${_result}">generic page</a></p>
+
+<P>.</P>

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.passwords
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.passwords?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.passwords (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.passwords Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#  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.
+
+
+#
+# configuration file for the file-based authentication
+# not used by the onlinedemo
+#
+
+# list of users, and their password, and optionally roles
+sven:pass:role1|role2|role3
+dick:pass
+bob:pass
+joe:pass

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authentication_file.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the File-based authentication mechanism
+${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} (intentionally empty)
+${symbol_pound}

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.allow
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.allow?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.allow (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.allow Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#  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.
+
+
+#
+# configuration file for the file-based authorization
+#
+
+
+#
+# (intentionally empty)
+#
+
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/authorization_file.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,50 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the File-based authorization mechanism
+${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} the whitelist file
+${symbol_pound} (value shown below is the default)
+${symbol_pound}
+
+${symbol_pound}isis.authorization.file.whitelist=authorization_file.allow
+
+
+
+${symbol_pound}
+${symbol_pound} the blacklist file
+${symbol_pound} (there is no default value; provide a filename)
+${symbol_pound}
+
+${symbol_pound}isis.authorization.file.blacklist=
+
+
+
+${symbol_pound}
+${symbol_pound} switch on "learning mode".  In this mode the authorization mechanism
+${symbol_pound} will grant all requests, and log those requests into the allow file.
+${symbol_pound}
+
+${symbol_pound}isis.authorization.learn=true
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/isis.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/isis.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/isis.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/isis.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,185 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+${symbol_pound}
+${symbol_pound} specify system components.
+${symbol_pound}
+${symbol_pound} The values correspond to the named components in the installer-registry.properties file
+${symbol_pound} in the org.apache.isis.runtimes.dflt:runtime JAR (in the org.apache.isis.runtimes.dflt.runtime package)
+${symbol_pound}
+${symbol_pound} Although all configuration could reside in isis.properties, the recommendation is
+${symbol_pound} to split out into component specific files:
+${symbol_pound} 
+${symbol_pound}    xxx_yyy.properties files
+${symbol_pound}
+${symbol_pound} where
+${symbol_pound}    * xxx is the component type, and
+${symbol_pound}    * yyy is the component name.
+${symbol_pound}
+${symbol_pound} For example, persistor_sql.properties holds configuration information specific to the
+${symbol_pound}
+${symbol_pound}
+${symbol_pound} If the components are changed, also remember to edit pom.xml (further comments can be 
+${symbol_pound} found in the persistor_xxx.properties files)
+${symbol_pound}
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+
+${symbol_pound}
+${symbol_pound} configure the persistor (object store) to use
+${symbol_pound}
+${symbol_pound} * in-memory   requires no additional configuration, but stores object in-memory.
+${symbol_pound}               Only suitable for prototyping
+${symbol_pound} * datanucleus uses JDO DataNucleus to persist objects to relational database.
+${symbol_pound}               for objectstore-specific properties, see persistor_datanucleus.properties   
+${symbol_pound} * fileserver  uses a simple FileServer to persist objects as JSON documents.  It requires the fileserver component to be running
+${symbol_pound}               for objectstore-specific properties, see persistor_fileserver.properties 
+${symbol_pound} * mongodb     uses MongoDB to be persist objects as JSON documents.  It requires MongoDB to be installed and running
+${symbol_pound}               for objectstore-specific properties, see persistor_fileserver.properties  
+${symbol_pound} * sql         uses an RDBMS to persist objects as table rows.  
+${symbol_pound}               for objectstore-specific properties, see persistor_sql.properties
+${symbol_pound} * xml         uses the XML ObjectStore to be persist objects to a set of XML files.  Only suitable for prototyping.
+${symbol_pound}               for objectstore-specific properties, see persistor_xml.properties 
+${symbol_pound}
+${symbol_pound} NOTE:
+${symbol_pound} * if using non-naive implementations of services, edit isis.services (below) and 
+${symbol_pound} * if necessary, update the pom.xml to reference appropriate objstore-xxx module
+${symbol_pound} * for sql and datanucleus objectstores, update the pom.xml to reference appropriate JDBC driver
+${symbol_pound} 
+
+isis.persistor=in-memory
+${symbol_pound}isis.persistor=fileserver
+${symbol_pound}isis.persistor=mongodb
+
+
+${symbol_pound}
+${symbol_pound} configure authentication mechanism to use (to logon to the system)
+${symbol_pound} note:
+${symbol_pound} - authentication is disabled if running in exploration mode
+${symbol_pound} - the Scimpi viewer allows access to anonymous users
+${symbol_pound}
+ 
+${symbol_pound} default is file in SERVER mode, none in SERVER_EXPLORATION.  Configure in web.xml 
+isis.authentication=file
+
+
+${symbol_pound}
+${symbol_pound} configure authorization mechanism to use
+${symbol_pound}
+${symbol_pound} The authorization mechanism define each users' permissions to view/edit object properties 
+${symbol_pound} or collections, and to view/invoke object actions
+${symbol_pound}
+${symbol_pound} configuring this component automatically refines the metamodel (installing a facet factory
+${symbol_pound} which vetoes access as required)
+${symbol_pound}
+
+${symbol_pound} default is file in SERVER mode, none in SERVER_EXPLORATION.  Configure in web.xml 
+${symbol_pound}isis.authorization=file
+
+
+
+${symbol_pound}
+${symbol_pound} configure the user profile store to use.
+${symbol_pound} 
+${symbol_pound} the user profile store is supported by some viewers as a way to store 
+${symbol_pound} user-specific settings (eg colours, themes etc)
+${symbol_pound} 
+isis.user-profile-store=in-memory
+
+
+
+
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+${symbol_pound}
+${symbol_pound} MetaModel
+${symbol_pound}
+${symbol_pound} The metamodel typically does not require additional configuration, although
+${symbol_pound} the system components (defined above) may refine the metamodel for their needs.
+${symbol_pound}
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} additional programming model facets
+${symbol_pound}
+
+${symbol_pound}isis.reflector.facets.include=
+${symbol_pound}isis.reflector.facets.exclude=
+
+${symbol_pound} normally these facets would be installed by virtue of configuring the JDO object store
+${symbol_pound} need to be configured manually if running some other object store only because the
+${symbol_pound} JDO enhancer is still configured to run on the DOM project.
+isis.reflector.facets.include=${symbol_escape}
+	org.apache.isis.core.progmodel.facets.object.ignore.jdo.RemoveJdoEnhancementTypesFacetFactory,${symbol_escape}
+	org.apache.isis.core.progmodel.facets.object.ignore.jdo.RemoveJdoPrefixedMethodsFacetFactory
+
+${symbol_pound}
+${symbol_pound} metamodel validator
+${symbol_pound}
+
+${symbol_pound}isis.reflector.validator=
+
+
+
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+${symbol_pound}
+${symbol_pound} Application Services and fixtures
+${symbol_pound}
+${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound
 }${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}${symbol_pound}
+
+${symbol_pound}
+${symbol_pound} Specify the domain services.
+${symbol_pound} 
+${symbol_pound} These are the most important configuration properties in the system, as they define
+${symbol_pound} the set of the classes for Isis to instantiate as domain service singletons.
+${symbol_pound} From these domain service instances the rest of the metamodel is discovered, while the 
+${symbol_pound} end-user gains access to other domain objects by invoking the actions of the domain services.
+${symbol_pound}
+${symbol_pound} The implementations depend on the configured (see isis.persistor above) 
+${symbol_pound}
+
+
+${symbol_pound} if using the in-memory, XML, SQL, fileserver or mongo object stores:
+isis.services.prefix = dom
+isis.services = todo.ToDoItems
+
+
+${symbol_pound} if using the DataNucleus object store
+${symbol_pound} (with support for JDO's audit service, and installing fixtures using a domain service)
+${symbol_pound}isis.services.prefix = 
+${symbol_pound}isis.services = objstore.jdo.todo.ToDoItemsJdo,${symbol_escape}
+${symbol_pound}                fixture.todo.ToDoItemsFixturesService,${symbol_escape}
+${symbol_pound}                dom.audit.AuditServiceDemo
+
+
+
+
+
+${symbol_pound}
+${symbol_pound} Specify the (optional) test fixtures
+${symbol_pound}
+${symbol_pound} Fixtures are used to seed the object store with an initial set of data.  For the 
+${symbol_pound} in-memory object store, the fixtures are installed on every run.  For other
+${symbol_pound} object stores, they are used only when the object store is first initialized.
+${symbol_pound}
+isis.fixtures.prefix= fixture
+isis.fixtures= todo.ToDoItemsFixture
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/logging.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/logging.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/logging.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/logging.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,92 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+
+${symbol_pound}
+${symbol_pound} Isis uses log4j is used to provide system logging
+${symbol_pound}
+log4j.rootCategory=INFO, Console
+
+${symbol_pound} The console appender
+log4j.appender.Console=org.apache.log4j.ConsoleAppender
+log4j.appender.Console.target=System.out
+log4j.appender.Console.layout=org.apache.log4j.PatternLayout
+log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE}  [%-20c{1} %-10t %-5p]  %m%n
+
+log4j.appender.File=org.apache.log4j.RollingFileAppender
+log4j.appender.File.file=isis.log
+log4j.appender.File.append=false
+log4j.appender.File.layout=org.apache.log4j.PatternLayout
+log4j.appender.File.layout.ConversionPattern=%d [%-20c{1} %-10t %-5p]  %m%n
+
+
+
+
+
+! turn on the internal log4j debugging flag so we can see what it is doing
+${symbol_pound}log4j.debug=true
+
+
+log4j.logger.jdbc.sqlonly=DEBUG, sql, Console
+log4j.additivity.jdbc.sqlonly=false
+
+log4j.logger.jdbc.resultsettable=DEBUG, jdbc, Console
+log4j.additivity.jdbc.resultsettable=false
+
+
+
+log4j.logger.jdbc.audit=DEBUG,jdbc, Console
+log4j.additivity.jdbc.audit=false
+
+log4j.logger.jdbc.resultset=DEBUG,jdbc
+log4j.additivity.jdbc.resultset=false
+
+log4j.logger.jdbc.sqltiming=WARNING,sqltiming
+log4j.additivity.jdbc.sqltiming=false
+
+log4j.logger.jdbc.connection=FATAL,connection
+log4j.additivity.jdbc.connection=false
+
+
+
+log4j.appender.sql=org.apache.log4j.FileAppender
+log4j.appender.sql.File=./logs/sql.log
+log4j.appender.sql.Append=false
+log4j.appender.sql.layout=org.apache.log4j.PatternLayout
+log4j.appender.sql.layout.ConversionPattern=-----> %d{yyyy-MM-dd HH:mm:ss.SSS} %m%n%n
+
+log4j.appender.sqltiming=org.apache.log4j.FileAppender
+log4j.appender.sqltiming.File=./logs/sqltiming.log
+log4j.appender.sqltiming.Append=false
+log4j.appender.sqltiming.layout=org.apache.log4j.PatternLayout
+log4j.appender.sqltiming.layout.ConversionPattern=-----> %d{yyyy-MM-dd HH:mm:ss.SSS} %m%n%n
+
+log4j.appender.jdbc=org.apache.log4j.FileAppender
+log4j.appender.jdbc.File=./logs/jdbc.log
+log4j.appender.jdbc.Append=false
+log4j.appender.jdbc.layout=org.apache.log4j.PatternLayout
+log4j.appender.jdbc.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss.SSS} %m%n
+
+log4j.appender.connection=org.apache.log4j.FileAppender
+log4j.appender.connection.File=./logs/connection.log
+log4j.appender.connection.Append=false
+log4j.appender.connection.layout=org.apache.log4j.PatternLayout
+log4j.appender.connection.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss.SSS} %m%n
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_fileserver.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_fileserver.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_fileserver.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_fileserver.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the NoSQL FileServer objectstore
+${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} (intentionally empty)
+${symbol_pound}

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_in-memory.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_in-memory.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_in-memory.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_in-memory.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the In-memory objectstore
+${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} (intentionally empty)
+${symbol_pound}

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_mongodb.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_mongodb.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_mongodb.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/persistor_mongodb.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,50 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the NoSQL (mongo) objectstore
+${symbol_pound}
+
+
+
+${symbol_pound}
+${symbol_pound} The hostname that the MongoDB instance is running on
+${symbol_pound} 
+${symbol_pound} as per "new com.mongodb.Mongo(host, port)"
+${symbol_pound}
+${symbol_pound}isis.nosql.mongodb.host=localhost
+
+
+${symbol_pound}
+${symbol_pound} The port number that the MongoDB instance is running on
+${symbol_pound}
+${symbol_pound} as per "new com.mongodb.Mongo(host, port)"
+${symbol_pound}
+${symbol_pound}isis.nosql.mongodb.port=0
+
+
+${symbol_pound}
+${symbol_pound} the name of the mongodb database
+${symbol_pound}
+${symbol_pound} as in the 'show dbs' and 'use' command
+${symbol_pound}
+isis.nosql.mongodb.name=todoapp
+
+

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/viewer_scimpi.properties
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/viewer_scimpi.properties?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/viewer_scimpi.properties (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/viewer_scimpi.properties Fri Oct 12 17:17:19 2012
@@ -0,0 +1,28 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+${symbol_pound}  Licensed to the Apache Software Foundation (ASF) under one
+${symbol_pound}  or more contributor license agreements.  See the NOTICE file
+${symbol_pound}  distributed with this work for additional information
+${symbol_pound}  regarding copyright ownership.  The ASF licenses this file
+${symbol_pound}  to you under the Apache License, Version 2.0 (the
+${symbol_pound}  "License"); you may not use this file except in compliance
+${symbol_pound}  with the License.  You may obtain a copy of the License at
+${symbol_pound}  
+${symbol_pound}         http://www.apache.org/licenses/LICENSE-2.0
+${symbol_pound}         
+${symbol_pound}  Unless required by applicable law or agreed to in writing,
+${symbol_pound}  software distributed under the License is distributed on an
+${symbol_pound}  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+${symbol_pound}  KIND, either express or implied.  See the License for the
+${symbol_pound}  specific language governing permissions and limitations
+${symbol_pound}  under the License.
+
+${symbol_pound}
+${symbol_pound} configuration file for the Scimpi viewer
+${symbol_pound}
+
+
+${symbol_pound}
+${symbol_pound} (intentionally empty)
+${symbol_pound}

Added: incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/web.xml?rev=1397650&view=auto
==============================================================================
--- incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/web.xml (added)
+++ incubator/isis/trunk/framework/quickstart-archetype/archetype/src/main/resources/archetype-resources/viewer-scimpi/src/main/webapp/WEB-INF/web.xml Fri Oct 12 17:17:19 2012
@@ -0,0 +1,177 @@
+#set( $symbol_pound = '#' )
+#set( $symbol_dollar = '$' )
+#set( $symbol_escape = '\' )
+<?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.
+-->
+<web-app id="WebApp_ID" version="2.4"
+    xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+    <display-name>Apache Isis Webapp</display-name>
+
+
+    <welcome-file-list>
+        <welcome-file>index.html</welcome-file>
+    </welcome-file-list>
+    
+    <context-param>
+        <param-name>deploymentType</param-name>
+        <!-- 
+        <param-value>SERVER</param-value>
+         -->
+        <param-value>SERVER_EXPLORATION</param-value>
+    </context-param>
+
+    
+    
+    <!--
+    -
+    -
+    - config common to all viewer(s)
+    -
+    -
+    -->
+    
+    <!-- bootstrap the Isis metamodel and runtime -->
+    <listener>
+        <listener-class>org.apache.isis.runtimes.dflt.webapp.IsisWebAppBootstrapper</listener-class>
+    </listener>
+
+    <!-- which (optional) configuration file(s) to load -->
+    <context-param>
+        <param-name>isis.viewers</param-name>
+        <param-value>scimpi</param-value>
+    </context-param>
+
+
+    <!-- which configuration directory to read overloaded property files from -->
+    <!-- 
+    Normally configuration like this should be done from outside your web 
+    application. Especially if your configuration is not know in advance or
+    if it can change depending on where the application gets deployed.
+    
+    For instance to configure this in Tomcat outside the application WAR add
+    the following line to your application context ( For more detail see:
+    http://tomcat.apache.org/tomcat-7.0-doc/config/context.html${symbol_pound}Context_Parameters )
+     
+    <Parameter name="isis.config.dir" value="/usr/local/tomcat/conf/"
+         override="true"/>
+         
+    If your configuration directory is fixed you can enable the following 
+    context parameter in here and forget about the outside part.
+         
+    <context-param>
+      <param-name>isis.config.dir</param-name>
+      <param-value>location of your config directory if fixed</param-value>
+    </context-param>
+    -->
+
+    <!-- cache static resources for 1 day -->
+    <filter>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <filter-class>org.apache.isis.core.webapp.content.ResourceCachingFilter</filter-class>
+        <init-param>
+            <param-name>CacheTime</param-name>
+            <param-value>86400</param-value>
+        </init-param>
+    </filter>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.js</url-pattern>
+    </filter-mapping>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.css</url-pattern>
+    </filter-mapping>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.png</url-pattern>
+    </filter-mapping>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.jpg</url-pattern>
+    </filter-mapping>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.gif</url-pattern>
+    </filter-mapping>
+    <filter-mapping>
+        <filter-name>ResourceCachingFilter</filter-name>
+        <url-pattern>*.html</url-pattern>
+    </filter-mapping>
+    
+    <servlet>
+        <servlet-name>Resource</servlet-name>
+        <servlet-class>org.apache.isis.core.webapp.content.ResourceServlet</servlet-class>
+    </servlet>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.css</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.png</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.jpg</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.gif</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.js</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>Resource</servlet-name>
+        <url-pattern>*.html</url-pattern>
+    </servlet-mapping>
+    
+
+
+
+    <!--
+    -
+    -
+    - config specific to the scimpi-viewer
+    -
+    -
+    -->
+    <servlet>
+        <servlet-name>ScimpiDispatcher</servlet-name>
+        <servlet-class>org.apache.isis.viewer.scimpi.servlet.DispatcherServlet</servlet-class>
+        <init-param>
+             <param-name>view</param-name>
+             <param-value>login.shtml</param-value>
+        </init-param>
+        <load-on-startup>1</load-on-startup>
+    </servlet>
+    <servlet-mapping>
+        <servlet-name>ScimpiDispatcher</servlet-name>
+        <url-pattern>*.shtml</url-pattern>
+    </servlet-mapping>
+    <servlet-mapping>
+        <servlet-name>ScimpiDispatcher</servlet-name>
+        <url-pattern>*.app</url-pattern>
+    </servlet-mapping>
+
+</web-app>