The document provides an overview and agenda for the Google Web Toolkit (GWT) 2.2 presentation. It includes demos of new tools like GWT Designer, and discusses new features such as SafeHTML wrappers, the Application framework including RequestFactory and Activities/Places, Cell Widgets, GWT Canvas, and built-in logging. It also summarizes the different options for making RPC calls in GWT and provides examples of using the new RequestFactory for data-oriented services.
Easing offline web application development with GWTArnaud Tournier
At this current time, HTML5 APIs are mature enough so that the web browser can now be a very good platform for applications that were before only implemented as native applications : offline applications with locally stored data, embedded SQL engines, etc. Although there are many good Javascript frameworks out there, the Java language allows to build, maintain, debug and work with ease on really big applications (> 100,000 LOC).
You'll discover in this presentation all the tools we assembled to make an application available with its data 100% of the time, even without internet!
Softshake 2013: Introduction to NoSQL with CouchbaseTugdual Grall
This presentation was delivered during Softshake 2013. Learn why RDBMS are not enought and why NoSQL help developers to scale their applications and provide agility.
Javascript Frameworks Comparison - Angular, Knockout, Ember and BackboneDeepu S Nath
Introduction and Comparison of polpular JS Frameworks Knockout, Ember, Angular and Backbone. The presentation descrobes How and when to select each framework.
Егор Шитиков, Magento microservice evangelist и developer, 11 ноября выступил на Magento Meetup Online #11 с темой «Magento NodeJS Microservices».
Егор подробно рассказал о микросервисах, strangler application и shared-database-per-microservices-and-monolith паттернах. Кроме того, часть его доклада была посвящена KnexJS как Query Builder.
LinkedIn Егора Шитикова: https://www.linkedin.com/in/yehorshytikov/
Facebook Егора Шитикова: https://www.facebook.com/yehor.shytikov
---
Yehor Shytikov, Magento microservice evangelist and developer, spoke at Magento Meetup Online # 11 on November 11 with the topic “Magento NodeJS Microservices”.
Yehor explained more about microservices, strangler application and shared-database-per-microservices-and-monolithic patterns. Besides, the part of his talk was devoted to KnexJS as a Query Builder.
Magecom: https://magecom.net/careers/
Facebook: https://www.facebook.com/magecomcompany
Instagram: https://www.instagram.com/magecomcompany/
VocBench is a web-based platform for the collaborative maintenance of multilingual thesauri. VocBench is an open source project, developed in the context of a collaboration between the Food and Agricultural Organization of the UN (FAO) and the University of Rome Tor Vergata. VocBench is currently used for the maintenance of AGROVOC, EUROVOC, GEMET, the thesaurus of the Italian Senate, the Unified Astronomy Thesaurus of Harvard University, as well as other thesauri.
VocBench has a strong focus on collaboration, supported by workflow management for content validation and publication. Dedicated user roles provide a clean separation of competencies, addressing different specificities ranging from management aspects to vertical competencies in content editing, such as conceptualization versus terminology editing. Extensive support for scheme management allows editors to fully exploit the possibilities of the SKOS model, as well as to fulfill its integrity constraints.
VocBench has been open source software since version 2 -- open to a large community of users and institutions supporting its development with their feedback and ideas. During the webinar, Dr. Caracciolo and Dr. Stellato will demonstrate the main features of VocBench from the point of view of users and system administrators, and explain in what way you may join the project.
A presentation I delivered to the Richmond JUG on the evolution of HTML through XHTML to HTML5 and some of the technologies that support implementation now, before a specification is reached by the WHATWG/W3C
Charla presentada en el Simposio Sudamericano de Plone 2009 donde se presentan distintos enfoques para integrar Plone con otras aplicaciones y frameworks desde las capas: modelo y vista por medio de contentmirror y deliverance respectivamente.
Having problems with Android application compatibility? You're not alone.
From the very beginning of the Android platform, developers always had to cope with a very difficult target: developing on a moving platform, a very fast moving one.
Release after release, features and goodies piled up, but, to a minor extent, so did API differentiation. This talk will step through how platform releases can risk jeopardizing professional development of Android applications, analyzing how to keep consistent UI patterns and implementation, and ending with the biggest release since 1.0: Honeycomb.
Wakanda: a new end-to-end JavaScript platform - JSConf Berlin 2009Alexandre Morgaut
Wakanda is an exciting project including a server, a studio, and some useful Web tools. It helps you creating web apps that integrate nicely with a backend and a native REST and JavaScript database.
It makes REST and Entity Model, a very intuitive way to build applications. We'll see a quick but detailed rundown about its architecture: its database engine, SquirrelFish, a data provider, Ajax framework adapters (YUI, ExtJS, jQuery, ...), and a full development environment. I'll expose part of its client and server-side APIs (JSON-RPC, data services), and some innovating features like JavaScript remote debugging, or unit testing on JavaScript and HTTP using Wakanda Studio and Firefox extensions.
The slides I used while giving an introduction to Ember.JS at Codecamp Cluj Napoca in November 2016.
It is a gist for all the things ember provide and why it enables teams to deliver products without blocking them in the past, as far as approaches and technology goes.
Taking Your GWT App to Tablets with GXT 4.0David Chandler
Sencha GXT builds on the open source GWT compiler to enable Java developers to build complex desktop-like user interfaces that run in the browser. In GXT 4.0, the core widgets have been updated to include touch functionality such as draggable borders, tree expand / collapse, LiveGrid scrolling, and long press to hover. In addition, you can add new gesture recognizers such as pinch and rotate to your apps. In this presentation, we look at the ins and outs of JavaScript touch event handling for GWT developers, touch support in GXT 4.0 widgets, how to eliminate the 300ms click delay in mobile browsers, and how to work with GXT’s new gesture recognizers. In addition, we look at some of the lessons learned by the GXT team while building GXT 4.0 and demo some debugging strategies for GWT apps on touch devices.
StORM: a lightweight ORM for Android SQLiteDavid Chandler
Android’s bundled SQLite database is powerful, but requires a lot of hand-coded SQL to get started. Using an ORM can simplify database development for many applications, and the Android ecosystem already has several to choose from. stORM is a lightweight DAO generator that aims for a streamlined developer experience (only two annotations required) and solid performance (preferring code generation over reflection). stORM is extensible, minimally intrusive, and offers built-in CSV backup / restore capabilities to facilitate database version upgrades. Along with stORM itself, Chandler presents techniques for writing and debugging an Android annotation processor that can be used with Eclipse, IntelliJ, or Android Studio.
Easing offline web application development with GWTArnaud Tournier
At this current time, HTML5 APIs are mature enough so that the web browser can now be a very good platform for applications that were before only implemented as native applications : offline applications with locally stored data, embedded SQL engines, etc. Although there are many good Javascript frameworks out there, the Java language allows to build, maintain, debug and work with ease on really big applications (> 100,000 LOC).
You'll discover in this presentation all the tools we assembled to make an application available with its data 100% of the time, even without internet!
Softshake 2013: Introduction to NoSQL with CouchbaseTugdual Grall
This presentation was delivered during Softshake 2013. Learn why RDBMS are not enought and why NoSQL help developers to scale their applications and provide agility.
Javascript Frameworks Comparison - Angular, Knockout, Ember and BackboneDeepu S Nath
Introduction and Comparison of polpular JS Frameworks Knockout, Ember, Angular and Backbone. The presentation descrobes How and when to select each framework.
Егор Шитиков, Magento microservice evangelist и developer, 11 ноября выступил на Magento Meetup Online #11 с темой «Magento NodeJS Microservices».
Егор подробно рассказал о микросервисах, strangler application и shared-database-per-microservices-and-monolith паттернах. Кроме того, часть его доклада была посвящена KnexJS как Query Builder.
LinkedIn Егора Шитикова: https://www.linkedin.com/in/yehorshytikov/
Facebook Егора Шитикова: https://www.facebook.com/yehor.shytikov
---
Yehor Shytikov, Magento microservice evangelist and developer, spoke at Magento Meetup Online # 11 on November 11 with the topic “Magento NodeJS Microservices”.
Yehor explained more about microservices, strangler application and shared-database-per-microservices-and-monolithic patterns. Besides, the part of his talk was devoted to KnexJS as a Query Builder.
Magecom: https://magecom.net/careers/
Facebook: https://www.facebook.com/magecomcompany
Instagram: https://www.instagram.com/magecomcompany/
VocBench is a web-based platform for the collaborative maintenance of multilingual thesauri. VocBench is an open source project, developed in the context of a collaboration between the Food and Agricultural Organization of the UN (FAO) and the University of Rome Tor Vergata. VocBench is currently used for the maintenance of AGROVOC, EUROVOC, GEMET, the thesaurus of the Italian Senate, the Unified Astronomy Thesaurus of Harvard University, as well as other thesauri.
VocBench has a strong focus on collaboration, supported by workflow management for content validation and publication. Dedicated user roles provide a clean separation of competencies, addressing different specificities ranging from management aspects to vertical competencies in content editing, such as conceptualization versus terminology editing. Extensive support for scheme management allows editors to fully exploit the possibilities of the SKOS model, as well as to fulfill its integrity constraints.
VocBench has been open source software since version 2 -- open to a large community of users and institutions supporting its development with their feedback and ideas. During the webinar, Dr. Caracciolo and Dr. Stellato will demonstrate the main features of VocBench from the point of view of users and system administrators, and explain in what way you may join the project.
A presentation I delivered to the Richmond JUG on the evolution of HTML through XHTML to HTML5 and some of the technologies that support implementation now, before a specification is reached by the WHATWG/W3C
Charla presentada en el Simposio Sudamericano de Plone 2009 donde se presentan distintos enfoques para integrar Plone con otras aplicaciones y frameworks desde las capas: modelo y vista por medio de contentmirror y deliverance respectivamente.
Having problems with Android application compatibility? You're not alone.
From the very beginning of the Android platform, developers always had to cope with a very difficult target: developing on a moving platform, a very fast moving one.
Release after release, features and goodies piled up, but, to a minor extent, so did API differentiation. This talk will step through how platform releases can risk jeopardizing professional development of Android applications, analyzing how to keep consistent UI patterns and implementation, and ending with the biggest release since 1.0: Honeycomb.
Wakanda: a new end-to-end JavaScript platform - JSConf Berlin 2009Alexandre Morgaut
Wakanda is an exciting project including a server, a studio, and some useful Web tools. It helps you creating web apps that integrate nicely with a backend and a native REST and JavaScript database.
It makes REST and Entity Model, a very intuitive way to build applications. We'll see a quick but detailed rundown about its architecture: its database engine, SquirrelFish, a data provider, Ajax framework adapters (YUI, ExtJS, jQuery, ...), and a full development environment. I'll expose part of its client and server-side APIs (JSON-RPC, data services), and some innovating features like JavaScript remote debugging, or unit testing on JavaScript and HTTP using Wakanda Studio and Firefox extensions.
The slides I used while giving an introduction to Ember.JS at Codecamp Cluj Napoca in November 2016.
It is a gist for all the things ember provide and why it enables teams to deliver products without blocking them in the past, as far as approaches and technology goes.
Taking Your GWT App to Tablets with GXT 4.0David Chandler
Sencha GXT builds on the open source GWT compiler to enable Java developers to build complex desktop-like user interfaces that run in the browser. In GXT 4.0, the core widgets have been updated to include touch functionality such as draggable borders, tree expand / collapse, LiveGrid scrolling, and long press to hover. In addition, you can add new gesture recognizers such as pinch and rotate to your apps. In this presentation, we look at the ins and outs of JavaScript touch event handling for GWT developers, touch support in GXT 4.0 widgets, how to eliminate the 300ms click delay in mobile browsers, and how to work with GXT’s new gesture recognizers. In addition, we look at some of the lessons learned by the GXT team while building GXT 4.0 and demo some debugging strategies for GWT apps on touch devices.
StORM: a lightweight ORM for Android SQLiteDavid Chandler
Android’s bundled SQLite database is powerful, but requires a lot of hand-coded SQL to get started. Using an ORM can simplify database development for many applications, and the Android ecosystem already has several to choose from. stORM is a lightweight DAO generator that aims for a streamlined developer experience (only two annotations required) and solid performance (preferring code generation over reflection). stORM is extensible, minimally intrusive, and offers built-in CSV backup / restore capabilities to facilitate database version upgrades. Along with stORM itself, Chandler presents techniques for writing and debugging an Android annotation processor that can be used with Eclipse, IntelliJ, or Android Studio.
Presentation from GWT.create 2015 on how to easily build a REST API that can be consumed via GWT or native mobile clients. Presentation video here: http://gwtcreate.com/videos/#rpc-jersey-resty-gwt
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Ramesh Iyer
In today's fast-changing business world, Companies that adapt and embrace new ideas often need help to keep up with the competition. However, fostering a culture of innovation takes much work. It takes vision, leadership and willingness to take risks in the right proportion. Sachin Dev Duggal, co-founder of Builder.ai, has perfected the art of this balance, creating a company culture where creativity and growth are nurtured at each stage.
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
GraphRAG is All You need? LLM & Knowledge GraphGuy Korland
Guy Korland, CEO and Co-founder of FalkorDB, will review two articles on the integration of language models with knowledge graphs.
1. Unifying Large Language Models and Knowledge Graphs: A Roadmap.
https://arxiv.org/abs/2306.08302
2. Microsoft Research's GraphRAG paper and a review paper on various uses of knowledge graphs:
https://www.microsoft.com/en-us/research/blog/graphrag-unlocking-llm-discovery-on-narrative-private-data/
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
9. GWT Quickstart
> svn checkout https://google-web-toolkit.googlecode.com/
svn/trunk/samples/expenses expenses
> cd expenses/src/main/webapp
> mvn -f ../../../pom.xml gwt:run (dev mode)
(note: most projects can use mvn gwt:run in the dir containing pom.xml--this
one is special because it loads test data from a .txt file in src/main/webapp)
1.Browse to http://127.0.0.1:8888/LoadExpensesDB.html?
gwt.codesvr=127.0.0.1:9997
2.Click Generate Data button
3.Browse to Expenses.html to run the app
To create an Eclipse project:
1.Install Sonatype m2eclipse and m2extras
2.File | Import | Existing maven project, select expenses/
pom.xml
Monday, March 21, 2011 9
18. What’s new in 2.2?
SafeHTML wrappers
Application framework
- RequestFactory
- Activities and Places
Cell Widgets and Editor framework
GWT Canvas
Built-in logging
Monday, March 21, 2011 18
19. Four flavors of RPC
1. RequestBuilder + JSONParser (see RESTY-GWT)
2. RequestBuilder + XMLParser
3. GWT-RPC (easiest)
4. RequestFactory (new in 2.1)
Monday, March 21, 2011 19
20. GWT-RPC
@RemoteServiceRelativePath("greet")
public interface GreetingService extends RemoteService {
String greetServer(String name) throws IllegalArgumentException;
}
public interface GreetingServiceAsync {
void greetServer(String input, AsyncCallback<String> callback)
throws IllegalArgumentException;
}
public class GreetingServiceImpl extends RemoteServiceServlet implements
GreetingService
{
public String greetServer(String input) throws IllegalArgumentException {
...
}
}
Monday, March 21, 2011 20
21. Simple, powerful GWT-RPC
Send / receive Plain Old Java Objects (POJO)
- Easy: interface, async, & implementation
- Versioned to help keep client & server in sync
- Even smaller than JSON
- Supports polymorphism
- No JavaScript hijacking risk (JSON attack)
- Easy to find all calls to given service in IDE
Monday, March 21, 2011 21
22. GWT 2.1 RequestFactory
Newer alternative to GWT-RPC
Designed for data-oriented services
- Higher level of abstraction than GWT-RPC
- Foundation for future caching / batching
Even faster than GWT-RPC
- JSON-based == very fast (no serialization /
deserialization required)
- Tracks changes on the client and sends only diffs
Monday, March 21, 2011 22
23. RequestFactory
The entity / DTO problem
EntityProxy / ValueProxy
Service stub interfaces extend RequestContext
AppRequestFactory extends RequestFactory
GWT.create(MyAppRequestFactory.class)
Monday, March 21, 2011 23
24. EntityProxy
@Entity
public class ItemList extends DatastoreObject
{
private String name;
private Key<AppUser> owner;
private ListType listType;
@Embedded
private List<ListItem> items; // value type
...
}
@ProxyFor(ItemList.class)
public interface ItemListProxy extends DatastoreObjectProxy
{
// TODO enums work!
public enum ListType {NOTES, TODO}
String getName();
void setName(String name);
List<ListItemProxy> getItems();
AppUserProxy getOwner(); // NOT Key
...
}
Monday, March 21, 2011 24
25. DatastoreObject
package com.listwidget.domain;
public class DatastoreObject
{
@Id
private Long id;
private Integer version = 0;
@PrePersist
void onPersist()
{
this.version++;
}
...
}
package com.listwidget.shared.proxy;
public interface DatastoreObjectProxy extends EntityProxy
{
Long getId();
Integer getVersion();
}
Monday, March 21, 2011 25
26. ValueProxy
public class ListItem // POJO
{
private String itemText;
private Date dateCreated;
public Date getDateCreated()
{
return dateCreated;
}
}
@ProxyFor(value = ListItem.class)
public interface ListItemProxy extends ValueProxy
{
String getItemText();
void setItemText(String itemText);
Date getDateCreated();
}
Monday, March 21, 2011 26
27. Making a RequestFactory
public interface ListwidgetRequestFactory extends RequestFactory
{
@Service(value = ItemListDao.class, locator = DaoServiceLocator.class)
interface ItemListRequestContext extends RequestContext
{
Request<List<ItemListProxy>> listAll();
Request<Void> save(ItemListProxy list);
Request<ItemListProxy> saveAndReturn(ItemListProxy newList);
}
ItemListRequestContext itemListRequest();
}
private final ListwidgetRequestFactory rf =
GWT.create(ListwidgetRequestFactory.class);
Monday, March 21, 2011 27
28. Using RequestFactory
@Override
public void persistList(String listName)
{
final ListwidgetRequestFactory rf = this.clientFactory
.getRequestFactory();
ItemListRequestContext reqCtx = rf.itemListRequest();
final ItemListProxy newList = reqCtx.create(ItemListProxy.class);
newList.setName(listName);
newList.setListType(ListType.TODO);
reqCtx.saveAndReturn(newList).fire(new Receiver<ItemListProxy>()
{
@Override
public void onSuccess(final ItemListProxy savedList)
{
// Refresh table
listDataProvider.getData();
}
});
}
Monday, March 21, 2011 28
29. Using RequestFactory
@Override
public void update(int index, ItemListProxy obj, final String newName)
{
ItemListRequestContext reqCtx = clientFactory.getRequestFactory()
.itemListRequest();
ItemListProxy editable = reqCtx.edit(obj);
editable.setName(newName);
reqCtx.save(editable).fire(new Receiver<Void>()
{
@Override
public void onSuccess(Void response)
{
eventBus.fireEvent(new MessageEvent(newName + " updated",
MessageType.INFO));
}
});
}
Monday, March 21, 2011 29
30. Using RequestFactory
private void getData()
{
// To retrieve relations and value types, use .with()
Request<List<ItemListProxy>> findAllReq = rf.itemListRequest()
.listAll().with("owner");
// Receiver specifies return type
findAllReq.fire(new Receiver<List<ItemListProxy>>()
{
@Override
Text
public void onSuccess(List<ItemListProxy> response)
{
updateRowData(0, response);
}
});
}
Monday, March 21, 2011 30
31. Using RequestFactory
editList = reqCtx.edit(editList);
List<ListItemProxy> items = editList.getItems();
// must initialize collections
if (items == null)
{
editList.setItems(new ArrayList<ListItemProxy>());
}
editList.getItems().add(newItem);
reqCtx.save(editList).with("items").to(new Receiver<Void>()
{
@Override
public void onSuccess(Void response)
{
itemsProvider.setList(editList.getItems());
itemsProvider.refresh();
}
}).fire();
Monday, March 21, 2011 31
32. GWT MVP - Concepts
View
- Interface + implementation
- Interface enables testing without GWTTestCase
- Typically expensive to construct so make reusable
Presenter
- No Widgets, just business logic
- Middle man between service layer and views
Monday, March 21, 2011 32
33. GWT MVP - Concepts
Place
- Place represents bookmarkable state of an activity
- PlaceController makes back button / bookmarks
work like users expect
- PlaceTokenizers map to / from String tokens on URL
Monday, March 21, 2011 33
34. Demo
third_party/java_src/gwt/svn/trunk/samples/
expenses
Monday, March 21, 2011 34
35. Place
public class EditListPlace extends Place
{
private String token;
public EditListPlace(String token)
{
this.token = token;
}
public String getToken()
{
return token;
}
public static class Tokenizer implements PlaceTokenizer<EditListPlace>
{
public EditListPlace getPlace(String token)
{
return new EditListPlace(token);
}
public String getToken(EditListPlace place)
{
return place.getToken();
}
}
}
Monday, March 21, 2011 35
36. PlaceHistoryMapper
/**
* PlaceHistoryMapper interface is used to attach all places which the
* PlaceHistoryHandler should be aware of. This is done via the @WithTokenizers
* annotation or by extending PlaceHistoryMapperWithFactory and creating a
* separate TokenizerFactory.
*/
@WithTokenizers({ ListsPlace.Tokenizer.class, EditListPlace.Tokenizer.class })
public interface AppPlaceHistoryMapper extends PlaceHistoryMapper
{
}
Monday, March 21, 2011 36
37. Hello Places
// Start PlaceHistoryHandler with our PlaceHistoryMapper
PlaceHistoryMapper historyMapper = clientFactory.getHistoryMapper();
PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(hisoryMapper);
historyHandler.register(placeController, eventBus, defaultPlace);
// Goes to place represented on URL or default place
historyHandler.handleCurrentHistory();
Monday, March 21, 2011 37
41. Activities
Activity, ActivityManager are not required!
ActivityManager
- Owns a region of the window
- Choose what to do with it on place change
Activity (“wake up, set up, show up”)
- Started by ActivityManager
- Provides a widget to display, asynchronously
- Can refuse to relinquish screen
Monday, March 21, 2011 41
48. Activities and Places wiring
// Start ActivityManager for the nav (west) panel with our WestActivityMapper
ActivityMapper westActivityMapper = new WestActivityMapper(clientFactory);
ActivityManager westActivityManager =
new ActivityManager(westActivityMapper, eventBus);
westActivityManager.setDisplay(westPanel);
// Start ActivityManager for the main (center) panel with our CenterActivityMapper
ActivityMapper centerActivityMapper = new CenterActivityMapper(clientFactory);
ActivityManager centerActivityManager =
new ActivityManager(centerActivityMapper, eventBus);
centerActivityManager.setDisplay(centerPanel);
// Start PlaceHistoryHandler with our PlaceHistoryMapper
PlaceHistoryMapper historyMapper = GWT.create(AppPlaceHistoryMapper.class);
PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper);
historyHandler.register(placeController, eventBus, defaultPlace);
RootPanel.get().add(dockLayoutPanel);
// Goes to place represented on URL or default place
historyHandler.handleCurrentHistory();
Monday, March 21, 2011 48
49. Cell Widgets
Fast, lightweight table rendering
Data binding with
DataProviders, ValueUpdaters
Scrolling and paging controls
Sortable columns, adjustable width
TextBox, IntegerBox, ValueBox<T>
Monday, March 21, 2011 49
51. Editable Column
// Editable column for list name
nameColumn = new Column<ItemListProxy,String>(new EditTextCell())
{
@Override
public String getValue(ItemListProxy list)
{
return list.getName();
}
};
Monday, March 21, 2011 51
52. Custom Column type
// Note Flyweight pattern: only one instance of HyperlinkCell passed to the Column
Column<ItemListProxy, Hyperlink> linkColumn =
new Column<ItemListProxy, Hyperlink>(new HyperlinkCell())
{
@Override
public Hyperlink getValue(ItemListProxy list)
{
String proxyToken =
clientFactory.getRequestFactory().getHistoryToken(list.stableId());
String historyToken =
clientFactory.getHistoryMapper().getToken(new EditListPlace(proxyToken));
Hyperlink h = new Hyperlink(list.getName(),historyToken);
return h;
}
};
Monday, March 21, 2011 52
53. Populating a CellTable
public static class MyDataProvider extends
AsyncDataProvider<ItemListProxy>
{
@Override
protected void onRangeChanged(HasData<ItemListProxy> display)
{
// To retrieve relations and value types, use .with()
Request<List<ItemListProxy>> findAllReq = rf.itemListRequest()
.listAll().with("owner");
// Receiver specifies return type
findAllReq.fire(new Receiver<List<ItemListProxy>>()
{
@Override
public void onSuccess(List<ItemListProxy> response)
{
updateRowData(0, response);
}
});
}
}
this.myDataProvider = new MyDataProvider(requestFactory);
Monday, March 21, 2011 53
54. Updating with a CellTable
public class NameFieldUpdater implements FieldUpdater<ItemListProxy, String>
{
@Override
public void update(int index, ItemListProxy obj, final String newName)
{
ItemListRequestContext reqCtx = clientFactory.getRequestFactory()
.itemListRequest();
ItemListProxy editable = reqCtx.edit(obj);
editable.setName(newName);
reqCtx.save(editable).fire(new Receiver<Void>()
{
@Override
public void onSuccess(Void response)
{
eventBus.fireEvent(new MessageEvent(newName + " updated",
MessageType.INFO));
}
});
}
};
// Make list name field editable
display.getNameColumn().setFieldUpdater(new NameFieldUpdater());
Monday, March 21, 2011 54
55. GWT Canvas
http://gwtcanvasdemo.appspot.com
Monday, March 21, 2011 55
56. GWT Logging
GWT now has java.util.Logging emulation
Configure in your .gwt.xml
Easily enable remote logging, too
Monday, March 21, 2011 56
57. GWT speak
“Very productive environment for Java
developers, but there is a learning curve”
“UI layout and styling is a challenge”
“GWT has enabled our team to run much faster
than we could otherwise”
“Would be impossible to write our app without
GWT”
Monday, March 21, 2011 57
58. New GWT book
http://code.google.com/webtoolkit/books.html
Monday, March 21, 2011 58
59. Thank you!
Where to get it:
http://code.google.com/webtoolkit/
Wiki, issue tracker, source:
http://code.google.com/p/google-web-toolkit/
Official GWT blog:
http://google-web-toolkit.blogspot.com/
Twitter:
@googledevtools
59
Monday, March 21, 2011 59