Hi, All.
Recently I've implemented some part of my thoughts for framework
improvements.
To the class com.mvp4g.util.Mvp4gGenerator to the initiating
ClassSourceFileComposerFactory
I added next line:
classFactory.addImport
("com.google.gwt.user.client.rpc.ServiceDefTarget");
To the class com.mvp4g.util.config.loader.ServicesLoader I changed
next variable declaration
static final String[] REQUIRED_ATTRIBUTES = { "name", "class",
"path" };
To the class com.mvp4g.util.Mvp4gConfigurationFileReader method
writeServices() a added next things
// override path to Async service if path
attribute present
if (null != service.getProperty("path")
&& !"".equals(service.getProperty("path"))) {
sourceWriter.println();
sourceWriter.println("// override path to Async service");
sourceWriter.print("((ServiceDefTarget)");
sourceWriter.print(name);
sourceWriter.print(")");
sourceWriter.print(".setServiceEntryPoint(");
sourceWriter.print("\"");
sourceWriter.print(service.getProperty("path"));
sourceWriter.print("\"");
sourceWriter.println(");");
sourceWriter.println();
}
Above changes provide ability to set following configuration
attributes to "services configuration"
<service name="simpleService" class="SimpleService" path="/gwt-
rpc/SimpleService" />
where declaration of the attribute "path" performs overriding of the
RPC service location. This more convenient if your services located on
different paths from your module. If you leave this attribute services
will have default configuration.
Thats all.
On Aug 19, 6:47 pm, webdizz <
webd...@gmail.com> wrote:
> 2009/8/19 plcoirier <
plcoir...@gmail.com>