UTGB Core 1.0: Developer Guide
Getting Started
Folder structure
Source codes of UTGB Core follows the Maven's standard folder layout:
src/main/java source codes src/main/resources resource folder src/main/webapp web application configuration files (web.xml, context.xml, etc. ) src/test/java test codes src/test/resources resources for testing src/gwt-test gwt-test codes tomcat GWT shell uses this folder to launch GWT-embedded tomcat server. To change the web application configuration, edit tomcat/webapps/ROOT/WEB-INF/web.xml, or tomcat/conf/gwt/localhost/(context path).xml etc. www GWT-compiled javascript codes will be generated into this folder eclipse eclipse program launch files target compiled class files or other generated files will be placed here
Package Structure
org.utgenome.gwt.utgb UTGB Core libraries and track implementations org.utgenome.gwt.utgb.client UTGB Core client-side (browser) codes, which will be compiled into JavaScripts org.utgenome.gwt.utgb.server UTGB Core server-side codes including Servlets. org.utgenome.gwt.web UTGB common libraries org.utgenome.format Data conversion codes org.utgenome.portable [[wiki:Devel/UTGBPortable UTGBPortable]] org.utgenome.util Miscellaneous utilties
Create Your First Track
In the default setting, if you add a RequestHandler? implementation (say, Hello.java) into org.utgenome.gwt.utgb.server.app package, the handler class can be accessed from:
In web mode (running on Tomcat server), this URL will be shortened into: http://(webapp url)/(context path)/hello.action
(see wiki:UTGBCore/RequestDispatcher for details)
Your first task is to extend a servlet that simply returns a test "HelloWorld" with additional messages:
source:trunk/utgb/utgb-core/src/main/java/org/utgenome/gwt/utgb/server/app/HelloWorld.java
Access the following URL after launching GWTShell: http://localhost:8888/org.utgenome.gwt.utgb.UTGBResourceCenter/dispatcher?actionClass=org.utgenome.gwt.utgb.server.app.helloworld