Reputation: 34815
Is there a way to report log messages in a Client-side GWT applications for development purposes (in Standard GWT libraries i.e. No external libraries)?
i.e. like the Logger that can be used to output log messages to catalina.out when developing things for say Tomcat.
Upvotes: 6
Views: 11270
Reputation: 1051
Just a quick example..
Add this line in *.gwt.xml file. Its in parent package of your client side source. The top most package..
<inherits name="com.google.gwt.logging.Logging"/>
Add this in .java file, lets say in the onModuleLoad() method
public void onModuleLoad() {
Logger logger = Logger.getLogger("NameOfYourLogger");
logger.log(Level.SEVERE, "this message should get logged");
Upvotes: 3
Reputation: 4444
Take a look to the gwt-log project. Seems that's you're looking for.
http://code.google.com/p/gwt-log/
Upvotes: 7