devicemap-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wk...@apache.org
Subject svn commit: r1749196 [2/2] - in /devicemap/trunk/examples/1.0/java/gwt: ./ gwt-model/ gwt-model/src/ gwt-model/src/main/ gwt-model/src/main/java/ gwt-model/src/main/java/org/ gwt-model/src/main/java/org/devicemap/ gwt-model/src/main/java/org/devicemap/...
Date Sun, 19 Jun 2016 19:31:05 GMT
Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/PersonDetailPlace.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/PersonDetailPlace.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/PersonDetailPlace.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/PersonDetailPlace.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,47 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.mvp.place;
+
+import com.github.apetrelli.gwtintegration.util.shared.StringUtils;
+import com.google.gwt.place.shared.Place;
+import com.google.gwt.place.shared.PlaceTokenizer;
+
+/**
+ * Place for Welcome.
+ */
+public class PersonDetailPlace extends Place {
+	
+	private Long id;
+	
+	public PersonDetailPlace() {
+		this(null);
+	}
+	
+	public PersonDetailPlace(Long id) {
+		this.id = id;
+	}
+	
+	public Long getId() {
+		return id;
+	}
+	
+	/**
+	 * Implementation of Tokenizer for this class.
+	 */
+	public static class Tokenizer implements PlaceTokenizer<PersonDetailPlace> {
+
+		@Override
+		public PersonDetailPlace getPlace(String token) {
+			Long id = null;
+			if (!StringUtils.isBlank(token)) {
+				id = Long.decode(token);
+			}
+			return new PersonDetailPlace(id);
+		}
+
+		@Override
+		public String getToken(PersonDetailPlace place) {
+			return place.id != null ? place.id.toString() : "";
+		}
+		
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/WelcomePlace.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/WelcomePlace.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/WelcomePlace.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/mvp/place/WelcomePlace.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,28 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.mvp.place;
+
+import com.google.gwt.place.shared.Place;
+import com.google.gwt.place.shared.PlaceTokenizer;
+
+/**
+ * Place for Welcome.
+ */
+public class WelcomePlace extends Place {
+	
+	/**
+	 * Implementation of Tokenizer for this class.
+	 */
+	public static class Tokenizer implements PlaceTokenizer<WelcomePlace> {
+
+		@Override
+		public WelcomePlace getPlace(String token) {
+			return new WelcomePlace();
+		}
+
+		@Override
+		public String getToken(WelcomePlace place) {
+			return "";
+		}
+		
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/ApplicationRequestFactory.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/ApplicationRequestFactory.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/ApplicationRequestFactory.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/ApplicationRequestFactory.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,20 @@
+// WARNING: DO NOT EDIT THIS FILE. THIS FILE IS MANAGED BY SPRING ROO.
+
+package org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.request.PersonRequest;
+import com.google.web.bindery.requestfactory.shared.LoggingRequest;
+import com.google.web.bindery.requestfactory.shared.RequestFactory;
+
+/**
+ * The main request factory.
+ */
+public interface ApplicationRequestFactory extends RequestFactory {
+	
+	/**
+	 * @return a GWT logging request.
+	 */
+	LoggingRequest loggingRequest();
+	
+	PersonRequest personRequest();
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/proxy/PersonProxy.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/proxy/PersonProxy.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/proxy/PersonProxy.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/proxy/PersonProxy.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,45 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+import javax.validation.constraints.NotNull;
+
+import org.hibernate.validator.constraints.NotEmpty;
+
+import org.devicemap.examples.gwtcanvasdemo.model.domain.Person;
+import org.devicemap.examples.gwtcanvasdemo.module.server.locator.PersonLocator;
+import org.devicemap.examples.gwtcanvasdemo.shared.shared.enums.PersonalTitle;
+import com.google.web.bindery.requestfactory.shared.EntityProxy;
+import com.google.web.bindery.requestfactory.shared.ProxyFor;
+
+@ProxyFor(value = Person.class, locator = PersonLocator.class)
+public interface PersonProxy extends EntityProxy {
+	
+	Long getId();
+	
+	Integer getVersion();
+	
+	@NotNull
+	PersonalTitle getPersonalTitle();
+	
+	void setPersonalTitle(PersonalTitle personalTitle);
+	
+	@NotEmpty
+	String getFirstName();
+	
+	void setFirstName(String firstName);
+	
+	@NotEmpty
+	String getLastName();
+	
+	void setLastName(String lastName);
+	
+	Date getBirthDate();
+	
+	void setBirthDate(Date birthDate);
+	
+	BigDecimal getAnnualIncome();
+	
+	void setAnnualIncome(BigDecimal annualIncome);
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/request/PersonRequest.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/request/PersonRequest.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/request/PersonRequest.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/requestfactory/request/PersonRequest.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,24 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.request;
+
+import java.util.List;
+
+import com.github.apetrelli.gwtintegration.editor.client.requestfactory.CrudRequest;
+import com.github.apetrelli.gwtintegration.spring.context.server.requestfactory.GwtServiceLocator;
+import org.devicemap.examples.gwtcanvasdemo.model.service.PersonService;
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy.PersonProxy;
+import com.google.web.bindery.requestfactory.shared.Request;
+import com.google.web.bindery.requestfactory.shared.Service;
+
+@Service(value = PersonService.class, locator = GwtServiceLocator.class)
+public interface PersonRequest extends CrudRequest<PersonProxy, Long> {
+	
+	Request<PersonProxy> findOne(Long id);
+	
+	Request<PersonProxy> save(PersonProxy entityProxy);
+	
+	Request<Void> delete(Long id);
+
+	Request<Long> countAllPersons();
+	
+	Request<List<PersonProxy>> findAllPersons();
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/ListPersonsView.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/ListPersonsView.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/ListPersonsView.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/ListPersonsView.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,14 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui;
+
+import java.util.List;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy.PersonProxy;
+import com.github.apetrelli.gwtintegration.mvp.client.ui.MvpView;
+
+public interface ListPersonsView extends MvpView<ListPersonsView.Presenter> {
+	
+	void setPersons(List<PersonProxy> persons);
+	
+	public interface Presenter extends MvpView.Presenter {
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/PersonDetailView.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/PersonDetailView.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/PersonDetailView.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/PersonDetailView.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,17 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.ui.editor.PersonEditor;
+import com.github.apetrelli.gwtintegration.mvp.client.ui.MvpView;
+
+public interface PersonDetailView extends MvpView<PersonDetailView.Presenter> {
+	
+	PersonEditor getEditor();
+	
+	void canDelete(boolean canDelete);
+	
+	public interface Presenter extends MvpView.Presenter {
+		void save();
+		
+		void delete();
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/WelcomeView.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/WelcomeView.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/WelcomeView.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/WelcomeView.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,29 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui;
+
+import com.google.gwt.place.shared.Place;
+import com.google.gwt.user.client.ui.IsWidget;
+
+/**
+ * Interface view that describe the welcome web-page.
+ *
+ */
+public interface WelcomeView extends IsWidget {
+
+	/**
+	 * Set the associated activity.
+	 * @param presenter associated Activity.
+	 */
+	void setPresenter(Presenter presenter);
+	
+	/**
+	 * Interface bridge to activity and view.
+	 *
+	 */
+	public interface Presenter {
+		/**
+		 * Redirect the user to the indicate  place.
+		 * @param place Place associated.
+		 */
+		void goTo(Place place);
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,70 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui.editor;
+
+import java.io.IOException;
+import java.math.BigDecimal;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Date;
+import java.util.List;
+
+import com.github.apetrelli.gwtintegration.editor.client.widget.LeafValueEditorDecorator;
+import com.github.apetrelli.gwtintegration.editor.client.widget.ValueDateBox;
+import com.github.apetrelli.gwtintegration.editor.client.widget.ValueListBox;
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy.PersonProxy;
+import org.devicemap.examples.gwtcanvasdemo.shared.shared.enums.PersonalTitle;
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.editor.client.Editor;
+import com.google.gwt.editor.ui.client.ValueBoxEditorDecorator;
+import com.google.gwt.text.shared.Renderer;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.uibinder.client.UiField;
+import com.google.gwt.user.client.ui.Composite;
+import com.google.gwt.user.client.ui.Widget;
+
+public class PersonEditor extends Composite implements Editor<PersonProxy>{
+	
+	@UiField LeafValueEditorDecorator<ValueListBox<PersonalTitle>, PersonalTitle> personalTitle;
+	
+	@Ignore
+	@UiField(provided=true) ValueListBox<PersonalTitle> personalTitleListBox;
+	
+	@UiField ValueBoxEditorDecorator<String> firstName;
+	
+	@UiField ValueBoxEditorDecorator<String> lastName;
+	
+	@UiField LeafValueEditorDecorator<ValueDateBox, Date> birthDate;
+	
+	@UiField ValueBoxEditorDecorator<BigDecimal> annualIncome;
+	
+	private static PersonEditorUiBinder uiBinder = GWT
+			.create(PersonEditorUiBinder.class);
+
+	interface PersonEditorUiBinder extends UiBinder<Widget, PersonEditor> {
+	}
+
+	public PersonEditor() {
+		initPersonalTitle();
+		initWidget(uiBinder.createAndBindUi(this));
+	}
+
+	private void initPersonalTitle() {
+		personalTitleListBox = new ValueListBox<PersonalTitle>(new Renderer<PersonalTitle>() {
+
+			@Override
+			public String render(PersonalTitle object) {
+				return object != null ? object.toString() : "";
+			}
+
+			@Override
+			public void render(PersonalTitle object, Appendable appendable)
+					throws IOException {
+				appendable.append(render(object));
+			}
+		});
+		List<PersonalTitle> titles = new ArrayList<PersonalTitle>();
+		titles.add(null);
+		titles.addAll(Arrays.asList(PersonalTitle.values()));
+		personalTitleListBox.setAcceptableValues(titles);
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.ui.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.ui.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.ui.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/editor/PersonEditor.ui.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,43 @@
+<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
+<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
+	xmlns:g="urn:import:com.google.gwt.user.client.ui"
+	xmlns:e='urn:import:com.google.gwt.editor.ui.client'
+	xmlns:e1='urn:import:com.github.apetrelli.gwtintegration.editor.client.widget'>
+	<ui:style>
+		
+	</ui:style>
+	<ui:with field="util" type="org.devicemap.examples.gwtcanvasdemo.module.client.util.ViewUtils" />
+	<ui:with type="org.devicemap.examples.gwtcanvasdemo.module.client.i18n.MainMessages" field="messages" />
+	<g:FlowPanel>
+		<g:Label text="{messages.personalTitle}" />
+		<e1:LeafValueEditorDecorator ui:field="personalTitle">
+			<e1:valuebox>
+				<e1:ValueListBox ui:field="personalTitleListBox" />
+			</e1:valuebox>
+		</e1:LeafValueEditorDecorator>
+		<g:Label text="{messages.firstName}" />
+		<e:ValueBoxEditorDecorator ui:field="firstName">
+			<e:valuebox>
+				<g:TextBox />
+			</e:valuebox>
+		</e:ValueBoxEditorDecorator>
+		<g:Label text="{messages.lastName}" />
+		<e:ValueBoxEditorDecorator ui:field="lastName">
+			<e:valuebox>
+				<g:TextBox />
+			</e:valuebox>
+		</e:ValueBoxEditorDecorator>
+		<g:Label text="{messages.birthDate}" />
+		<e1:LeafValueEditorDecorator ui:field="birthDate">
+			<e1:valuebox>
+				<e1:ValueDateBox format="{util.getDateFormatForDateBox}" />
+			</e1:valuebox>
+		</e1:LeafValueEditorDecorator>
+		<g:Label text="{messages.annualIncome}" />
+		<e:ValueBoxEditorDecorator ui:field="annualIncome">
+			<e:valuebox>
+				<e1:ValueBox renderer="{util.getMoneyRenderer}" parser="{util.getMoneyParser}" />
+			</e:valuebox>
+		</e:ValueBoxEditorDecorator>
+	</g:FlowPanel>
+</ui:UiBinder> 
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,30 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui;
+
+import com.github.apetrelli.gwtintegration.mvp.client.ui.HasBody;
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.uibinder.client.UiField;
+import com.google.gwt.user.client.ui.AcceptsOneWidget;
+import com.google.gwt.user.client.ui.Composite;
+import com.google.gwt.user.client.ui.SimplePanel;
+import com.google.gwt.user.client.ui.Widget;
+
+public class gwtcanvasdemoTemplate extends Composite implements HasBody {
+
+	private static gwtcanvasdemoTemplateUiBinder uiBinder = GWT
+			.create(gwtcanvasdemoTemplateUiBinder.class);
+	@UiField SimplePanel body;
+
+	interface gwtcanvasdemoTemplateUiBinder extends
+			UiBinder<Widget, gwtcanvasdemoTemplate> {
+	}
+
+	public gwtcanvasdemoTemplate() {
+		initWidget(uiBinder.createAndBindUi(this));
+	}
+	
+	@Override
+	public AcceptsOneWidget getBody() {
+		return body;
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.ui.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.ui.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.ui.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/gwtcanvasdemoTemplate.ui.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,33 @@
+<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
+<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
+	xmlns:g="urn:import:com.google.gwt.user.client.ui">
+	<ui:style>
+		.important {
+			font-weight: bold;
+		}
+		.resized {
+			height: 100%
+		}
+	</ui:style>
+	<ui:with type="org.devicemap.examples.gwtcanvasdemo.module.client.i18n.MainMessages" field="messages" />
+	<g:DockLayoutPanel>
+		<g:north size="100.0">
+			<g:FlowPanel>
+				<g:Label text="{messages.title}"/>
+			</g:FlowPanel>
+		</g:north>
+		<g:west size="100.0">
+			<g:FlowPanel>
+				<g:Hyperlink text="{messages.persons}" targetHistoryToken="ListPersonsPlace:" />
+			</g:FlowPanel>
+		</g:west>
+		<g:center>
+			<g:SimplePanel ui:field="body"/>
+		</g:center>
+		<g:south size="100.0">
+			<g:FlowPanel>
+				<g:Label text="{messages.footer}"/>
+			</g:FlowPanel>
+		</g:south>
+	</g:DockLayoutPanel>
+</ui:UiBinder> 
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,113 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui.impl;
+
+import java.util.Comparator;
+import java.util.List;
+
+import com.github.apetrelli.gwtintegration.cellview.client.builder.CellTableWithListDataBuilder;
+import com.github.apetrelli.gwtintegration.cellview.client.widget.SimplePagedTable;
+import com.github.apetrelli.gwtintegration.mvp.client.ui.impl.AbstractMvpView;
+import com.github.apetrelli.gwtintegration.util.shared.ObjectUtils;
+import org.devicemap.examples.gwtcanvasdemo.module.client.mvp.place.PersonDetailPlace;
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy.PersonProxy;
+import org.devicemap.examples.gwtcanvasdemo.module.client.ui.ListPersonsView;
+import org.devicemap.examples.gwtcanvasdemo.shared.shared.enums.PersonalTitle;
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.event.dom.client.ClickEvent;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.uibinder.client.UiField;
+import com.google.gwt.uibinder.client.UiHandler;
+import com.google.gwt.user.cellview.client.TextColumn;
+import com.google.gwt.user.client.ui.Widget;
+import com.google.gwt.view.client.CellPreviewEvent;
+import com.google.gwt.view.client.ProvidesKey;
+
+public class ListPersonsViewImpl extends AbstractMvpView<ListPersonsView.Presenter> implements ListPersonsView {
+
+	private static ListPersonsViewImplUiBinder uiBinder = GWT
+			.create(ListPersonsViewImplUiBinder.class);
+
+	interface ListPersonsViewImplUiBinder extends
+			UiBinder<Widget, ListPersonsViewImpl> {
+	}
+	
+	@UiField(provided=true) SimplePagedTable<PersonProxy> dataTable;
+
+	public ListPersonsViewImpl() {
+		CellTableWithListDataBuilder<PersonProxy> builder = CellTableWithListDataBuilder.create();
+		builder.createDefaultDataProvider()
+				.setKeyProvider(new PersonKeyProvider())
+				.createDefaultSelectionModel().addSelectionCellboxColumn()
+				.addColumn("Title", new TextColumn<PersonProxy>() {
+
+					@Override
+					public String getValue(PersonProxy object) {
+						PersonalTitle title = object.getPersonalTitle();
+						return title != null ? title.toString() : "-";
+					}
+				}, new Comparator<PersonProxy>() {
+
+					@Override
+					public int compare(PersonProxy o1, PersonProxy o2) {
+						return ObjectUtils.compare(o1.getPersonalTitle(),
+								o2.getPersonalTitle());
+					}
+				})
+				.addColumn("Surname", new TextColumn<PersonProxy>() {
+
+					@Override
+					public String getValue(PersonProxy object) {
+						return object.getLastName();
+					}
+				}, new Comparator<PersonProxy>() {
+
+					@Override
+					public int compare(PersonProxy o1, PersonProxy o2) {
+						return o1.getLastName().compareTo(o2.getLastName());
+					}
+				})
+				.addColumn("Name", new TextColumn<PersonProxy>() {
+
+					@Override
+					public String getValue(PersonProxy object) {
+						return object.getFirstName();
+					}
+				}, new Comparator<PersonProxy>() {
+
+					@Override
+					public int compare(PersonProxy o1, PersonProxy o2) {
+						return o1.getLastName().compareTo(o2.getFirstName());
+					}
+				}).setCellPreviewHandler(new CellPreviewEvent.Handler<PersonProxy>() {
+
+					@Override
+					public void onCellPreview(CellPreviewEvent<PersonProxy> event) {
+						   String type = event.getNativeEvent().getType();
+		                   if (type.equals("click")) {
+		                	   presenter.goTo(new PersonDetailPlace(event.getValue().getId()));
+		                   }
+		            }
+				});
+		dataTable = new SimplePagedTable<PersonProxy>(builder);
+		dataTable.setDefaultSortColumnIndex(2);
+		dataTable.setPageSize(5);
+		initWidget(uiBinder.createAndBindUi(this));
+	}
+
+	@Override
+	public void setPersons(List<PersonProxy> persons) {
+		dataTable.setItems(persons);
+	}
+
+	private static class PersonKeyProvider implements ProvidesKey<PersonProxy> {
+
+		@Override
+		public Object getKey(PersonProxy item) {
+			return item.getId();
+		}
+		
+	}
+	@UiHandler("add")
+	void onAddClick(ClickEvent event) {
+		presenter.goTo(new PersonDetailPlace());
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.ui.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.ui.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.ui.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/ListPersonsViewImpl.ui.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,14 @@
+<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
+<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
+	xmlns:g="urn:import:com.google.gwt.user.client.ui"
+	xmlns:c="urn:import:com.google.gwt.user.cellview.client"
+	xmlns:w="urn:import:com.github.apetrelli.gwtintegration.cellview.client.widget">
+	<ui:style>
+		
+	</ui:style>
+	<ui:with type="org.devicemap.examples.gwtcanvasdemo.module.client.i18n.MainMessages" field="messages" />
+	<g:FlowPanel>
+		<w:SimplePagedTable ui:field="dataTable" />
+		<g:Button text="{messages.add}" ui:field="add" />
+	</g:FlowPanel>
+</ui:UiBinder> 
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,52 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui.impl;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.ui.PersonDetailView;
+import org.devicemap.examples.gwtcanvasdemo.module.client.ui.editor.PersonEditor;
+import com.github.apetrelli.gwtintegration.mvp.client.ui.impl.AbstractMvpView;
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.event.dom.client.ClickEvent;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.uibinder.client.UiField;
+import com.google.gwt.uibinder.client.UiHandler;
+import com.google.gwt.user.client.ui.Button;
+import com.google.gwt.user.client.ui.Widget;
+
+public class PersonDetailViewImpl extends AbstractMvpView<PersonDetailView.Presenter> implements PersonDetailView {
+
+	@UiField PersonEditor editor;
+	
+	@UiField Button save;
+	
+	@UiField Button delete;
+	
+	private static PersonDetailViewImplUiBinder uiBinder = GWT
+			.create(PersonDetailViewImplUiBinder.class);
+
+	interface PersonDetailViewImplUiBinder extends
+			UiBinder<Widget, PersonDetailViewImpl> {
+	}
+
+	public PersonDetailViewImpl() {
+		initWidget(uiBinder.createAndBindUi(this));
+	}
+
+	@Override
+	public PersonEditor getEditor() {
+		return editor;
+	}
+	
+	@Override
+	public void canDelete(boolean canDelete) {
+		delete.setVisible(canDelete);
+	}
+
+	@UiHandler("save")
+	void onSaveClick(ClickEvent event) {
+		presenter.save();
+	}
+
+	@UiHandler("delete")
+	void onDeleteClick(ClickEvent event) {
+		presenter.delete();
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.ui.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.ui.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.ui.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/PersonDetailViewImpl.ui.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,14 @@
+<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
+<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
+	xmlns:g="urn:import:com.google.gwt.user.client.ui"
+	xmlns:e="urn:import:org.devicemap.examples.gwtcanvasdemo.module.client.ui.editor">
+	<ui:style>
+		
+	</ui:style>
+	<ui:with type="org.devicemap.examples.gwtcanvasdemo.module.client.i18n.MainMessages" field="messages" />
+	<g:FlowPanel>
+		<e:PersonEditor ui:field="editor" />
+		<g:Button ui:field="save" text="{messages.save}" />
+		<g:Button ui:field="delete" text="{messages.delete}" />
+	</g:FlowPanel>
+</ui:UiBinder> 
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,37 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.ui.impl;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.ui.WelcomeView;
+import com.google.gwt.core.client.GWT;
+import com.google.gwt.uibinder.client.UiBinder;
+import com.google.gwt.user.client.ui.Composite;
+import com.google.gwt.user.client.ui.Widget;
+
+/**
+ * Unique implementation of view welcome.
+ * Define and management the element of page.
+ *
+ */
+public class WelcomeViewImpl extends Composite implements WelcomeView {
+	
+	private static WelcomeViewImplUiBinder uiBinder = GWT
+			.create(WelcomeViewImplUiBinder.class);
+
+	/**
+	 * Bridge to view and UiBinder xml.
+	 *
+	 */
+	interface WelcomeViewImplUiBinder extends UiBinder<Widget, WelcomeViewImpl> {
+	}
+
+	/**
+	 * Constructor.
+	 */
+	public WelcomeViewImpl() {
+		initWidget(uiBinder.createAndBindUi(this));
+	}
+	
+	@Override
+	public void setPresenter(Presenter presenter) {
+		// Does nothing for the moment.
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.ui.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.ui.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.ui.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/ui/impl/WelcomeViewImpl.ui.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,17 @@
+<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
+<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
+	xmlns:g="urn:import:com.google.gwt.user.client.ui">
+	<ui:style>
+		.important {
+			font-weight: bold;
+		}
+		
+		.sideBySide {
+			float: left;
+		}
+	</ui:style>
+	<ui:with type="org.devicemap.examples.gwtcanvasdemo.module.client.i18n.MainMessages" field="messages" />
+	<g:FlowPanel>
+		<g:Label text="{messages.welcomeText}" />
+	</g:FlowPanel>
+</ui:UiBinder> 
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/util/ViewUtils.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/util/ViewUtils.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/util/ViewUtils.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/util/ViewUtils.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,47 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.util;
+
+import java.math.BigDecimal;
+
+import com.github.apetrelli.gwtintegration.editor.client.text.BigDecimalParser;
+import com.github.apetrelli.gwtintegration.editor.client.text.NumberFormatRenderer;
+import com.github.apetrelli.gwtintegration.editor.client.widget.ValueDateBox;
+import com.github.apetrelli.gwtintegration.editor.client.widget.ValueDateBox.ParsingFormat;
+import com.google.gwt.i18n.client.DateTimeFormat;
+import com.google.gwt.i18n.client.NumberFormat;
+import com.google.gwt.text.shared.Parser;
+import com.google.gwt.text.shared.Renderer;
+
+public class ViewUtils {
+	
+	private static DateTimeFormat dateFormat = DateTimeFormat.getFormat("dd/MM/yyyy");
+
+	private static ParsingFormat dateFormatForDateBox = new ValueDateBox.DefaultParsingFormat(dateFormat); 
+	
+	private static NumberFormat moneyFormat = NumberFormat.getFormat("#0.00");
+	
+	private static Renderer<BigDecimal> moneyRenderer = new NumberFormatRenderer<BigDecimal>(moneyFormat);
+
+	private static Parser<BigDecimal> moneyParser = BigDecimalParser.instance();
+	
+	private ViewUtils() {}
+	
+	public static DateTimeFormat getDateFormat() {
+		return dateFormat;
+	}
+	
+	public static ParsingFormat getDateFormatForDateBox() {
+		return dateFormatForDateBox;
+	}
+	
+	public static NumberFormat getMoneyFormat() {
+		return moneyFormat;
+	}
+	
+	public static Parser<BigDecimal> getMoneyParser() {
+		return moneyParser;
+	}
+	
+	public static Renderer<BigDecimal> getMoneyRenderer() {
+		return moneyRenderer;
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/validation/ValidatorFactory.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/validation/ValidatorFactory.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/validation/ValidatorFactory.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/client/validation/ValidatorFactory.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,23 @@
+package org.devicemap.examples.gwtcanvasdemo.module.client.validation;
+
+import javax.validation.Validator;
+
+import org.devicemap.examples.gwtcanvasdemo.module.client.requestfactory.proxy.PersonProxy;
+import com.google.gwt.core.shared.GWT;
+import com.google.gwt.validation.client.AbstractGwtValidatorFactory;
+import com.google.gwt.validation.client.GwtValidation;
+import com.google.gwt.validation.client.impl.AbstractGwtValidator;
+
+public class ValidatorFactory extends AbstractGwtValidatorFactory {
+
+	@GwtValidation({PersonProxy.class})
+	public interface GwtValidator extends Validator {
+		
+	}
+	
+	@Override
+	public AbstractGwtValidator createValidator() {
+		return GWT.create(GwtValidator.class);
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/locator/PersonLocator.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/locator/PersonLocator.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/locator/PersonLocator.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/locator/PersonLocator.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,45 @@
+package org.devicemap.examples.gwtcanvasdemo.module.server.locator;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+import org.devicemap.examples.gwtcanvasdemo.model.domain.Person;
+import org.devicemap.examples.gwtcanvasdemo.model.service.PersonService;
+import com.github.apetrelli.gwtintegration.hibernate.core.locator.DeproxierDeletableLocator;
+
+@Component
+public class PersonLocator extends DeproxierDeletableLocator<Person, Long> {
+
+	@Autowired
+	private PersonService service;
+	
+	@Override
+	public Person create(Class<? extends Person> clazz) {
+		return new Person();
+	}
+
+	@Override
+	public Person find(Long id) {
+		return service.findOne(id);
+	}
+
+	@Override
+	public Class<Person> getDomainType() {
+		return Person.class;
+	}
+
+	@Override
+	public Long getId(Person domainObject) {
+		return domainObject.getId();
+	}
+
+	@Override
+	public Class<Long> getIdType() {
+		return Long.class;
+	}
+
+	@Override
+	public Object getVersion(Person domainObject) {
+		return domainObject.getVersion();
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/PassAllAuthenticationProvider.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/PassAllAuthenticationProvider.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/PassAllAuthenticationProvider.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/PassAllAuthenticationProvider.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,53 @@
+package org.devicemap.examples.gwtcanvasdemo.module.server.security;
+
+import org.springframework.dao.DataAccessException;
+import org.springframework.security.authentication.AuthenticationServiceException;
+import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
+import org.springframework.security.authentication.dao.AbstractUserDetailsAuthenticationProvider;
+import org.springframework.security.core.AuthenticationException;
+import org.springframework.security.core.userdetails.UserDetails;
+import org.springframework.security.core.userdetails.UserDetailsService;
+
+public class PassAllAuthenticationProvider extends
+		AbstractUserDetailsAuthenticationProvider {
+
+    private UserDetailsService userDetailsService;
+
+	@Override
+	protected void additionalAuthenticationChecks(UserDetails userDetails,
+			UsernamePasswordAuthenticationToken authentication)
+			throws AuthenticationException {
+		// Do nothing
+
+	}
+
+    public void setUserDetailsService(UserDetailsService userDetailsService) {
+        this.userDetailsService = userDetailsService;
+    }
+
+    protected UserDetailsService getUserDetailsService() {
+        return userDetailsService;
+    }
+
+	@Override
+	protected UserDetails retrieveUser(String username,
+			UsernamePasswordAuthenticationToken authentication)
+			throws AuthenticationException {
+		UserDetails loadedUser;
+
+		try {
+			loadedUser = this.getUserDetailsService().loadUserByUsername(
+					username);
+		} catch (DataAccessException repositoryProblem) {
+			throw new AuthenticationServiceException(
+					repositoryProblem.getMessage(), repositoryProblem);
+		}
+
+		if (loadedUser == null) {
+			throw new AuthenticationServiceException(
+					"UserDetailsService returned null, which is an interface contract violation");
+		}
+		return loadedUser;
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleAuthority.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleAuthority.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleAuthority.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleAuthority.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,24 @@
+package org.devicemap.examples.gwtcanvasdemo.module.server.security;
+
+import org.springframework.security.core.GrantedAuthority;
+
+public class SampleAuthority implements GrantedAuthority {
+
+	private static final long serialVersionUID = -4504114106906301183L;
+
+	private String authority;
+	
+	public static final SampleAuthority READER = new SampleAuthority("READER");
+
+	public static final SampleAuthority WRITER = new SampleAuthority("WRITER");
+
+	private SampleAuthority(String authority) {
+		this.authority = authority;
+	}
+
+	@Override
+	public String getAuthority() {
+		return authority;
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleUserDetailsService.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleUserDetailsService.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleUserDetailsService.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SampleUserDetailsService.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,33 @@
+package org.devicemap.examples.gwtcanvasdemo.module.server.security;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.springframework.security.core.Authentication;
+import org.springframework.security.core.userdetails.AuthenticationUserDetailsService;
+import org.springframework.security.core.userdetails.UserDetails;
+import org.springframework.security.core.userdetails.UserDetailsService;
+import org.springframework.security.core.userdetails.UsernameNotFoundException;
+
+public class SampleUserDetailsService implements UserDetailsService, AuthenticationUserDetailsService<Authentication>{
+
+	@Override
+	public UserDetails loadUserDetails(Authentication token)
+			throws UsernameNotFoundException {
+		return loadUserByUsername(token.getName());
+	}
+
+	@Override
+	public UserDetails loadUserByUsername(String username)
+			throws UsernameNotFoundException {
+		List<SampleAuthority> authorities = new ArrayList<SampleAuthority>();
+		if ("reader".equals(username)) {
+			authorities.add(SampleAuthority.READER);
+		} else if ("writer".equals(username)) {
+			authorities.add(SampleAuthority.WRITER);
+		} else {
+			throw new UsernameNotFoundException(username);
+		}
+		return new SimpleUserDetails(username, authorities);
+	}
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SimpleUserDetails.java
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SimpleUserDetails.java?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SimpleUserDetails.java (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/java/org/devicemap/examples/gwtcanvasdemo/module/server/security/SimpleUserDetails.java Sun Jun 19 19:31:04 2016
@@ -0,0 +1,57 @@
+package org.devicemap.examples.gwtcanvasdemo.module.server.security;
+
+import java.util.Collection;
+
+import org.springframework.security.core.GrantedAuthority;
+import org.springframework.security.core.userdetails.UserDetails;
+
+public class SimpleUserDetails implements UserDetails {
+	
+	private static final long serialVersionUID = -4725095483759316543L;
+
+	private String username;
+	
+	private Collection<? extends GrantedAuthority> authorities;
+
+	public SimpleUserDetails(String username,
+			Collection<? extends GrantedAuthority> authorities) {
+		this.username = username;
+		this.authorities = authorities;
+	}
+
+	@Override
+	public Collection<? extends GrantedAuthority> getAuthorities() {
+		return authorities;
+	}
+
+	@Override
+	public String getPassword() {
+		return null;
+	}
+
+	@Override
+	public String getUsername() {
+		return username;
+	}
+
+	@Override
+	public boolean isAccountNonExpired() {
+		return true;
+	}
+
+	@Override
+	public boolean isAccountNonLocked() {
+		return true;
+	}
+
+	@Override
+	public boolean isCredentialsNonExpired() {
+		return true;
+	}
+
+	@Override
+	public boolean isEnabled() {
+		return true;
+	}
+
+}

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-resources/META-INF/spring/security-cas.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-resources/META-INF/spring/security-cas.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-resources/META-INF/spring/security-cas.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-resources/META-INF/spring/security-cas.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<beans:beans xmlns="http://www.springframework.org/schema/security"
+  xmlns:beans="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://www.springframework.org/schema/beans
+                    http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
+                    http://www.springframework.org/schema/security
+                    http://www.springframework.org/schema/security/spring-security-3.1.xsd">
+
+  <http auto-config="false" use-expressions="true">
+    <intercept-url pattern="/**" access="permitAll" />
+    <form-login />
+    <logout/>
+    <session-management session-fixation-protection="none" />
+  </http>
+
+  <authentication-manager>
+    <authentication-provider ref="authenticationProvider" />
+  </authentication-manager>
+  <beans:bean name="authenticationProvider" class="org.devicemap.examples.gwtcanvasdemo.module.server.security.PassAllAuthenticationProvider">
+    <beans:property name="userDetailsService" ref="userDetailsService" />
+  </beans:bean>
+  <beans:bean id="userDetailsService" class="org.devicemap.examples.gwtcanvasdemo.module.server.security.SampleUserDetailsService" />
+</beans:beans>

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-sources/org/devicemap/examples/gwtcanvasdemo/module/gwtcanvasdemo.gwt.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-sources/org/devicemap/examples/gwtcanvasdemo/module/gwtcanvasdemo.gwt.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-sources/org/devicemap/examples/gwtcanvasdemo/module/gwtcanvasdemo.gwt.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/production-sources/org/devicemap/examples/gwtcanvasdemo/module/gwtcanvasdemo.gwt.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.4.0//EN" "http://google-web-toolkit.googlecode.com/svn/tags/2.4.0/distro-source/core/src/gwt-module.dtd">
+<module rename-to="gwt">
+  <inherits name="com.google.gwt.user.User"/>
+  <inherits name="com.google.gwt.user.cellview.CellView"/>
+  <inherits name="com.google.gwt.logging.Logging"/>
+  <inherits name="com.google.gwt.text.Text"/>
+  <inherits name="com.google.gwt.i18n.I18N"/>
+  <inherits name="com.google.gwt.resources.Resources" />
+  <inherits name="com.google.gwt.user.theme.standard.Standard" />
+  <inherits name="com.github.apetrelli.gwtintegration.cellview.GwtIntegrationCellview"/>
+  <inherits name="com.github.apetrelli.gwtintegration.error.GwtIntegrationError"/>
+  <inherits name="com.github.apetrelli.gwtintegration.editor.GwtIntegrationEditor"/>
+  <inherits name="com.github.apetrelli.gwtintegration.mvp.GwtIntegrationMvp"/>
+  <inherits name="com.github.apetrelli.gwtintegration.requestfactory.GwtIntegrationRequestFactory"/>
+  <inherits name="com.github.apetrelli.gwtintegration.spring.context.GwtIntegrationSpringContext"/>
+  <inherits name="com.github.apetrelli.gwtintegration.util.GwtIntegrationUtil"/>
+  <inherits name="com.github.apetrelli.gwtintegration.widget.GwtIntegrationWidget"/>
+  <inherits name="com.github.apetrelli.gwtintegration.remotelogging.GwtIntegrationRemoteLogging"/>
+  <inherits name="org.devicemap.examples.gwtcanvasdemo.shared.gwtcanvasdemoShared"/>
+  <inherits name="org.hibernate.validator.HibernateValidator" />
+  <set-property name="compiler.stackMode" value="emulated"/>
+  <!-- Logging Configuration -->
+  <set-property name="gwt.logging.enabled" value="TRUE"/>
+  <set-property name="gwt.logging.logLevel" value="INFO"/>
+  <set-property name="gwt.logging.consoleHandler" value="ENABLED"/>
+  <set-property name="gwt.logging.developmentModeHandler" value="ENABLED"/>
+  <set-property name="gwt.logging.firebugHandler" value="ENABLED"/>
+  <set-property name="gwt.logging.hasWidgetsHandler" value="DISABLED"/>
+  <set-property name="gwt.logging.popupHandler" value="DISABLED"/>
+  <set-property name="gwt.logging.systemHandler" value="ENABLED"/>
+  <set-property name="gwt.logging.simpleRemoteHandler" value="DISABLED"/>
+
+  <!-- Configuration for Super Dev Mode -->
+  <add-linker name="xsiframe"/>
+  <set-configuration-property name="devModeRedirectEnabled" value="true"/>
+
+  <!--UiBinder Configuration -->
+  <set-configuration-property name="UiBinder.useSafeHtmlTemplates" value="true"/>
+
+  <set-property name="compiler.emulatedStack" value="true" />
+  <set-configuration-property name="compiler.emulatedStack.recordLineNumbers" value="true" />
+  <set-configuration-property name="compiler.emulatedStack.recordFileNames" value="true" />
+  <replace-with
+    class="org.devicemap.examples.gwtcanvasdemo.module.client.ClientFactoryImpl">
+    <when-type-is class="org.devicemap.examples.gwtcanvasdemo.module.client.ClientFactory" />
+  </replace-with>
+  <source path="client" />
+  <source path="shared"/>
+  <public path="public"/>
+  <entry-point class="org.devicemap.examples.gwtcanvasdemo.module.client.gwtcanvasdemo" />
+
+  <!-- Specify the Validator for the Validation bootstrap to use. -->
+  <replace-with
+    class="org.devicemap.examples.gwtcanvasdemo.module.client.validation.ValidatorFactory">
+    <when-type-is class="javax.validation.ValidatorFactory" />
+  </replace-with>
+</module>

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/META-INF/spring/applicationContext.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/META-INF/spring/applicationContext.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/META-INF/spring/applicationContext.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/META-INF/spring/applicationContext.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<beans xmlns="http://www.springframework.org/schema/beans"
+	xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context"
+	xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:sec="http://www.springframework.org/schema/security"
+	xmlns:datajpa="http://www.springframework.org/schema/data/jpa"
+	xsi:schemaLocation="http://www.springframework.org/schema/aop
+                      http://www.springframework.org/schema/aop/spring-aop-3.1.xsd
+                      http://www.springframework.org/schema/beans
+                      http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
+                      http://www.springframework.org/schema/context
+                      http://www.springframework.org/schema/context/spring-context-3.1.xsd
+                      http://www.springframework.org/schema/jee
+                      http://www.springframework.org/schema/jee/spring-jee-3.1.xsd
+                      http://www.springframework.org/schema/tx
+                      http://www.springframework.org/schema/tx/spring-tx-3.1.xsd
+                      http://www.springframework.org/schema/security 
+                      http://www.springframework.org/schema/security/spring-security-3.1.xsd
+                      http://www.springframework.org/schema/data/jpa
+                      http://www.springframework.org/schema/data/jpa/spring-jpa.xsd">
+	<bean id="resourceBundleLocator"
+		class="com.github.apetrelli.gwtintegration.hibernate.validator.NoFallbackResourceBundleLocator">
+		<constructor-arg value="ValidationMessages" />
+	</bean>
+	<bean id="messageInterpolator"
+		class="org.hibernate.validator.messageinterpolation.ResourceBundleMessageInterpolator">
+		<constructor-arg ref="resourceBundleLocator" />
+	</bean>
+	<bean id="validator"
+		class="org.springframework.validation.beanvalidation.LocalValidatorFactoryBean">
+		<property name="messageInterpolator" ref="messageInterpolator" />
+	</bean>
+
+</beans>

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/log4j.properties
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/log4j.properties?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/log4j.properties (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/resources/log4j.properties Sun Jun 19 19:31:04 2016
@@ -0,0 +1,7 @@
+log4j.rootLogger=error, stdout
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+
+# Print the date in ISO 8601 format
+log4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c - %m%n

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/spring/database.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/spring/database.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/spring/database.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/spring/database.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<beans xmlns="http://www.springframework.org/schema/beans"
+  xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context"
+  xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.0.xsd         http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd         http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd         http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.0.xsd         http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.0.xsd">
+	<bean
+		class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"
+		id="entityManagerFactory">
+		<!-- <property name="persistenceUnitName" value="persistenceUnit"/> -->
+		<property name="dataSource" ref="dataSource" />
+		<property name="packagesToScan">
+			<array>
+				<value>org.devicemap.examples.gwtcanvasdemo.model.domain</value>
+			</array>
+		</property>
+		<property name="persistenceProviderClass" value="org.hibernate.ejb.HibernatePersistence" />
+		<property name="jpaPropertyMap">
+			<map>
+				<!-- value="create" to build a new database on each run; value="update" 
+					to modify an existing database; value="create-drop" means the same as "create" 
+					but also drops tables when Hibernate closes; value="validate" makes no changes 
+					to the database -->
+				<entry key="hibernate.hbm2ddl.auto" value="update" />
+				<entry key="hibernate.format_sql" value="true" />
+				<entry key="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect" />
+				<entry key="hibernate.ejb.naming_strategy" value="org.hibernate.cfg.ImprovedNamingStrategy" />
+				<entry key="hibernate.connection.charSet" value="UTF-8" />
+				<entry key="javax.persistence.validation.factory" value-ref="validator" />
+			</map>
+		</property>
+	</bean>
+    <bean class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close" id="dataSource">
+        <property name="driverClassName" value="org.hsqldb.jdbc.JDBCDriver"/>
+        <property name="url" value="jdbc:hsqldb:mem:gwt"/>
+        <property name="username" value="sa"/>
+        <property name="password" value=""/>
+        <property name="testOnBorrow" value="true"/>
+        <property name="testOnReturn" value="true"/>
+        <property name="testWhileIdle" value="true"/>
+        <property name="timeBetweenEvictionRunsMillis" value="1800000"/>
+        <property name="numTestsPerEvictionRun" value="3"/>
+        <property name="minEvictableIdleTimeMillis" value="1800000"/>
+        <property name="validationQuery" value="SELECT 1 FROM INFORMATION_SCHEMA.SYSTEM_USERS"/>
+    </bean>
+</beans>

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/web.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/web.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/WEB-INF/web.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,144 @@
+<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
+<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	version="2.5"
+	xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+
+
+	<display-name>gwt-web</display-name>
+
+	<description>Sample GWT application</description>
+
+
+	<!-- Enable escaping of form submission contents -->
+	<context-param>
+		<param-name>defaultHtmlEscape</param-name>
+		<param-value>true</param-value>
+	</context-param>
+
+	<context-param>
+		<param-name>contextConfigLocation</param-name>
+		<param-value>
+		classpath*:META-INF/spring/applicationContext*.xml
+		classpath*:META-INF/spring/security*.xml
+		WEB-INF/spring/database.xml
+		</param-value>
+	</context-param>
+	<listener>
+		<display-name>hibernate-init</display-name>
+		<listener-class>com.github.apetrelli.gwtintegration.hibernate.entitymanager.web.HibernateInitContextListener</listener-class>
+	</listener>
+	<listener>
+		<display-name>application-context-holder</display-name>
+		<listener-class>com.github.apetrelli.gwtintegration.spring.web.SpringWebApplicationContextHolderListener</listener-class>
+	</listener>
+	<listener>
+		<display-name>session-locale-holder</display-name>
+		<listener-class>com.github.apetrelli.gwtintegration.spring.web.SessionLocaleHolderListener</listener-class>
+	</listener>
+	<listener>
+		<display-name>slf4j-bridge-install</display-name>
+		<listener-class>com.github.apetrelli.gwtintegration.remotelogging.server.Slf4jBridgeInstallListener</listener-class>
+	</listener>
+	<filter>
+		<filter-name>gwtCacheControl</filter-name>
+		<filter-class>com.github.apetrelli.gwtintegration.web.servlet.GwtCacheControlFilter</filter-class>
+	</filter>
+	<filter>
+		<filter-name>springSecurityFilterChain</filter-name>
+		<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
+	</filter>
+	<filter>
+		<filter-name>RequestContextFilter</filter-name>
+		<filter-class>com.github.apetrelli.gwtintegration.spring.web.RequestContextFilter</filter-class>
+	</filter>
+
+	<filter>
+		<filter-name>CharacterEncodingFilter</filter-name>
+		<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
+		<init-param>
+			<param-name>encoding</param-name>
+			<param-value>UTF-8</param-value>
+		</init-param>
+		<init-param>
+			<param-name>forceEncoding</param-name>
+			<param-value>true</param-value>
+		</init-param>
+	</filter>
+
+	<filter>
+		<filter-name>HttpMethodFilter</filter-name>
+		<filter-class>org.springframework.web.filter.HiddenHttpMethodFilter</filter-class>
+	</filter>
+
+	<filter>
+		<filter-name>Spring OpenEntityManagerInViewFilter</filter-name>
+		<filter-class>org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter</filter-class>
+	</filter>
+
+	<filter-mapping>
+		<filter-name>gwtCacheControl</filter-name>
+		<url-pattern>/gwt-web/gwt-web.nocache.js</url-pattern>
+	</filter-mapping>
+	<filter-mapping>
+		<filter-name>RequestContextFilter</filter-name>
+		<url-pattern>/*</url-pattern>
+	</filter-mapping>
+	<filter-mapping>
+		<filter-name>Spring OpenEntityManagerInViewFilter</filter-name>
+		<url-pattern>/*</url-pattern>
+	</filter-mapping>
+	<filter-mapping>
+		<filter-name>springSecurityFilterChain</filter-name>
+		<url-pattern>/*</url-pattern>
+	</filter-mapping>
+	<filter-mapping>
+		<filter-name>CharacterEncodingFilter</filter-name>
+		<url-pattern>/*</url-pattern>
+	</filter-mapping>
+
+	<filter-mapping>
+		<filter-name>HttpMethodFilter</filter-name>
+		<url-pattern>/*</url-pattern>
+	</filter-mapping>
+
+	<!-- Creates the Spring Container shared by all Servlets and Filters -->
+	<listener>
+		<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
+	</listener>
+
+	<servlet>
+		<servlet-name>requestFactory</servlet-name>
+		<servlet-class>com.github.apetrelli.gwtintegration.spring.security.SecureRequestFactoryServlet</servlet-class>
+		<load-on-startup>1</load-on-startup>
+	</servlet>
+	<servlet>
+	    <servlet-name>remoteLogging</servlet-name>
+	    <servlet-class>com.github.apetrelli.gwtintegration.remotelogging.server.RemoteLoggingServiceImpl</servlet-class>
+	    <init-param>
+	    	<param-name>SYMBOL_MAPS_DIR</param-name>
+	    	<param-value>/WEB-INF/deploy/gwt/symbolMaps</param-value>
+	    </init-param>
+	</servlet>
+
+	<servlet-mapping>
+		<servlet-name>requestFactory</servlet-name>
+		<url-pattern>/gwtRequest</url-pattern>
+	</servlet-mapping>
+	<servlet-mapping>
+		<servlet-name>remoteLogging</servlet-name>
+		<url-pattern>/gwt/remote_logging</url-pattern>
+	</servlet-mapping>
+
+	<!-- session config -->
+	<session-config>
+		<session-timeout>30</session-timeout>
+	</session-config>
+
+	<!-- file upload parameters -->
+
+	<error-page>
+		<error-code>500</error-code>
+		<location>/error500.html</location>
+	</error-page>
+
+</web-app>

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/error500.html
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/error500.html?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/error500.html (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/error500.html Sun Jun 19 19:31:04 2016
@@ -0,0 +1,9 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<html>
+	<head>
+	    <!-- forward to the GWT Application -->
+	    <body>
+			An error occurred.    
+	    </body>
+	</HEAD>
+</HTML>
\ No newline at end of file

Added: devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/index.jsp
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/index.jsp?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/index.jsp (added)
+++ devicemap/trunk/examples/1.0/java/gwt/gwt-web/src/main/webapp/index.jsp Sun Jun 19 19:31:04 2016
@@ -0,0 +1,25 @@
+<%@page import="java.util.Date"%>
+<%@ page language="java" contentType="text/html; charset=UTF-8"
+    pageEncoding="UTF-8"%>
+<%
+  Date now = new Date();
+  response.setDateHeader("Date", now.getTime());
+  // one day old
+  response.setDateHeader("Expires", now.getTime() - 86400000L);
+  response.setHeader( "Pragma", "no-cache" );
+  response.setHeader( "Cache-Control", "no-cache, no-store, must-revalidate" );
+%>
+<!doctype html>
+<html>
+  <head>
+    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
+    <meta http-equiv="x-ua-compatible" content="IE=8">
+    <title>Sample GWT</title>
+    <script type="text/javascript" src="gwt/gwt.nocache.js"></script>
+  </head>
+
+  <body>
+    <iframe src="javascript:''" id="__gwt_historyFrame" tabIndex='-1' style="position:absolute;width:0;height:0;border:0"></iframe>
+
+  </body>
+</html>

Added: devicemap/trunk/examples/1.0/java/gwt/pom.xml
URL: http://svn.apache.org/viewvc/devicemap/trunk/examples/1.0/java/gwt/pom.xml?rev=1749196&view=auto
==============================================================================
--- devicemap/trunk/examples/1.0/java/gwt/pom.xml (added)
+++ devicemap/trunk/examples/1.0/java/gwt/pom.xml Sun Jun 19 19:31:04 2016
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<parent>
+        <artifactId>dmap-java-examples</artifactId>
+        <groupId>org.apache.devicemap.examples</groupId>
+        <version>1.0.0-SNAPSHOT</version>
+    </parent>
+	<groupId>org.apache.devicemap.examples</groupId>
+	<artifactId>gwt</artifactId>
+	<version>1.0.0-SNAPSHOT</version>
+	<packaging>pom</packaging>
+	<name>Sample GWT parent project</name>
+	<description>The container project</description>
+	<properties>
+		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+		<gwt.version>2.6.1</gwt.version>
+		<gwt.integration.version>1.0.0-alpha4</gwt.integration.version>
+	</properties>
+	<build>
+		<plugins>
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-compiler-plugin</artifactId>
+				<configuration>
+					<source>1.6</source>
+					<target>1.6</target>
+					<encoding>${project.build.sourceEncoding}</encoding>
+				</configuration>
+			</plugin>
+		</plugins>
+	</build>
+	<profiles>
+		<profile>
+			<id>generate-archetype</id>
+			<build>
+				<plugins>
+					<plugin>
+						<artifactId>maven-archetype-plugin</artifactId>
+						<version>2.2</version>
+						<configuration>
+							<propertyFile>src/etc/archetype/archetype-values.properties</propertyFile>
+						</configuration>
+						<executions>
+							<execution>
+								<id>create-archetype</id>
+								<goals>
+									<goal>create-from-project</goal>
+								</goals>
+								<phase>generate-resources</phase>
+							</execution>
+						</executions>
+					</plugin>
+					<plugin>
+						<artifactId>maven-antrun-plugin</artifactId>
+						<version>1.7</version>
+						<executions>
+							<execution>
+								<id>rename-files</id>
+								<goals>
+									<goal>run</goal>
+								</goals>
+								<phase>generate-resources</phase>
+								<configuration>
+									<target>
+										<move todir="target/generated-sources/archetype/src/main/resources/archetype-resources">
+											<fileset dir="target/generated-sources/archetype/src/main/resources/archetype-resources">
+												<include name="**/*gwtcanvasdemo*"/>
+											</fileset>
+											<mapper type="regexp" from="^(.*)gwtcanvasdemo(.*)$$" to="\1__moduleName__\2"/>
+										</move>
+										<delete>
+											<fileset dir="target/generated-sources/archetype/src/main/resources/archetype-resources" includes="**/.settings/*"/>
+										</delete>
+										<delete includeemptydirs="true">
+											<fileset dir="target/generated-sources/archetype/src/main/resources/archetype-resources" includes="**/.settings"/>
+										</delete>
+										<delete>
+											<fileset dir="target/generated-sources/archetype/src/main/resources/archetype-resources" includes="**/.project,**/.classpath"/>
+										</delete>
+									</target>
+								</configuration>
+							</execution>
+						</executions>
+					</plugin>
+				</plugins>
+			</build>
+		</profile>
+	</profiles>
+  <modules>
+    <module>gwt-shared</module>
+    <module>gwt-model</module>
+    <module>gwt-web</module>
+  </modules>
+</project>
\ No newline at end of file



Mime
View raw message