Get data for GroupingView
grid = new Ext.grid.GridPanel({
id: getGridArea,
ds: createStore,
cm: this.columnModelFile(),
view: new Ext.grid.GroupingView({
forceFit:true,
groupTextTpl: '{text}|{[ values.rs[0].data["state"] ]} ({[values.rs.length]} {[values.rs.length > 1 ? "Devices" : "Device"]})'
}),
// viewConfig: {
// forceFit:true
// },
sm: selectionModel,
width: 500,
height: 250,
//title: 'Firmware File List',
collapsible: false,
animCollapse: true,
bbar: pagingTool
});
Tuesday, 18 November 2008
Monday, 10 November 2008
[Restlet with Spring DM]
How you can create restlet with Spring DM
1. need update 6 files
- web.xml
- applicationContext-osgi.xml
- applicationContext.xml
- MANIFEST.MF
- TestApplication.java
- TestDefaultResource.java
2. main point
use "org.restlet.component" as context-param
in web.xml add below line
3.
[context-param]
[param-name]org.restlet.component[/param-name]
[param-value]component[/param-value]
[/context-param]
4. "component is from "applicationContext.xml" file
[bean id="component" class="org.restlet.ext.spring.SpringComponent" ]
[property name="defaultTarget" ref="application" /]
[/bean]
5. "application" is from same file "applicationContext.xml" file
[bean id="application" class="applicationPackage.TestApplication"][/bean]
6. TestApplication.java
import TestDefaultResouce;
import org.restlet.Application;
import org.restlet.Context;
import org.restlet.Restlet;
import org.restlet.Router;
public class EamApplication extends Application {
public EamApplication() {
super();
// TODO Auto-generated constructor stub
}
public EamApplication(Context context) {
super(context);
}
@Override
public Restlet createRoot() {
Router router = new Router(getContext());
router.attachDefault(TestDefaultResouce.class);
return router;
}
}
7. TestDefaultResouce.java
import org.restlet.Context;
import org.restlet.data.MediaType;
import org.restlet.data.Request;
import org.restlet.data.Response;
import org.restlet.resource.Representation;
import org.restlet.resource.Resource;
import org.restlet.resource.StringRepresentation;
import org.restlet.resource.Variant;
public class EamDefaultResouce extends Resource {
public EamDefaultResouce() {
super();
// TODO Auto-generated constructor stub
}
public EamDefaultResouce(Context context, Request request, Response response) {
super(context, request, response);
getVariants().add(new Variant(MediaType.TEXT_PLAIN));
}
@Override
public Representation getRepresentation(Variant variant){
Representation representation = new StringRepresentation("index page", MediaType.TEXT_PLAIN);
return representation;
}
}
1. need update 6 files
- web.xml
- applicationContext-osgi.xml
- applicationContext.xml
- MANIFEST.MF
- TestApplication.java
- TestDefaultResource.java
2. main point
use "org.restlet.component" as context-param
in web.xml add below line
3.
[context-param]
[param-name]org.restlet.component[/param-name]
[param-value]component[/param-value]
[/context-param]
4. "component is from "applicationContext.xml" file
[bean id="component" class="org.restlet.ext.spring.SpringComponent" ]
[property name="defaultTarget" ref="application" /]
[/bean]
5. "application" is from same file "applicationContext.xml" file
[bean id="application" class="applicationPackage.TestApplication"][/bean]
6. TestApplication.java
import TestDefaultResouce;
import org.restlet.Application;
import org.restlet.Context;
import org.restlet.Restlet;
import org.restlet.Router;
public class EamApplication extends Application {
public EamApplication() {
super();
// TODO Auto-generated constructor stub
}
public EamApplication(Context context) {
super(context);
}
@Override
public Restlet createRoot() {
Router router = new Router(getContext());
router.attachDefault(TestDefaultResouce.class);
return router;
}
}
7. TestDefaultResouce.java
import org.restlet.Context;
import org.restlet.data.MediaType;
import org.restlet.data.Request;
import org.restlet.data.Response;
import org.restlet.resource.Representation;
import org.restlet.resource.Resource;
import org.restlet.resource.StringRepresentation;
import org.restlet.resource.Variant;
public class EamDefaultResouce extends Resource {
public EamDefaultResouce() {
super();
// TODO Auto-generated constructor stub
}
public EamDefaultResouce(Context context, Request request, Response response) {
super(context, request, response);
getVariants().add(new Variant(MediaType.TEXT_PLAIN));
}
@Override
public Representation getRepresentation(Variant variant){
Representation representation = new StringRepresentation("index page", MediaType.TEXT_PLAIN);
return representation;
}
}
Thursday, 6 November 2008
[Error - Rest] com.noelios.restlet.Engine createHelper
====== Error message (Rest) ======
com.noelios.restlet.Engine createHelper
No available server connector supports the required protocols
==== Solution ======
need "com.noelios.restlet.ext.jetty_6.1.jar" file
org.mortbay.jetty.ajp.jar
org.mortbay.jetty.https.jar
org.mortbay.jetty.jar
org.mortbay.jetty.util.jar
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/Connector
=== Solution ===
need "org.mortbay.jetty.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/component/LifeCycle
=== Solution ===
need "org.mortbay.jetty.util.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/ajp/Ajp13SocketConnector
=== Solution ===
need "org.mortbay.jetty.ajp.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/security/SslSelectChannelConnector
=== Solution ===
need "org.mortbay.jetty.https.jar" file
com.noelios.restlet.Engine createHelper
No available server connector supports the required protocols
==== Solution ======
need "com.noelios.restlet.ext.jetty_6.1.jar" file
org.mortbay.jetty.ajp.jar
org.mortbay.jetty.https.jar
org.mortbay.jetty.jar
org.mortbay.jetty.util.jar
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/Connector
=== Solution ===
need "org.mortbay.jetty.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/component/LifeCycle
=== Solution ===
need "org.mortbay.jetty.util.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/ajp/Ajp13SocketConnector
=== Solution ===
need "org.mortbay.jetty.ajp.jar" file
=== You might see other error message ====
Exception in thread "main" java.lang.NoClassDefFoundError: org/mortbay/jetty/security/SslSelectChannelConnector
=== Solution ===
need "org.mortbay.jetty.https.jar" file
Monday, 3 November 2008
[Error] NoClassDefFoundError org/apache/commons/codec/DecoderException
==== Error Message ====
NoClassDefFoundError org/apache/commons/codec/DecoderException
==== Solution =====
You need org.apache.commons.codec.jar file
NoClassDefFoundError org/apache/commons/codec/DecoderException
==== Solution =====
You need org.apache.commons.codec.jar file
[Error] java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
=== Error MEssage ===
java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
== Solution ===
you need "commons-logging.jar" file
java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
== Solution ===
you need "commons-logging.jar" file
Sunday, 2 November 2008
[Erro] Axis2 - Eclipse
=== Error message =====
The Axis2 facets cannot be installed since the Axis2 runtime location has not been set. Please go to the Web Services preference page and set the Axis2 runtime
==== Solution ====
Eclipse
Window > Preferences > Web Services > Axis2 Preferences > Axis2 Runtime
Setup Axis2 location and check "Axis2 runtime loaded successfully!!!"
The Axis2 facets cannot be installed since the Axis2 runtime location has not been set. Please go to the Web Services preference page and set the Axis2 runtime
==== Solution ====
Eclipse
Window > Preferences > Web Services > Axis2 Preferences > Axis2 Runtime
Setup Axis2 location and check "Axis2 runtime loaded successfully!!!"
Subscribe to:
Posts (Atom)