Creating a Java Emitter Template (JET) is no easy feat, but if you have the right infrastructure set up it’s not that difficult.
This article is based on the Java Code Generator plug-in for Eclipse.
(weiterlesen …)
Archiv für September 2008
In Three steps to your Java Emitter template
Samstag, 13. September 2008Wrongfully assigned IP address
Samstag, 6. September 2008If you have no internet connection that may have many causes. I recently had a wrongfully assigned IP address. The computer accesses the internet through a router that assigns an IP address form 192.168.1.0/24 address range.
The first thing if the connection to the internet fails is to check the connection to the router with a ping. In my case this failed. Executing the ifconfig showed why:
ifconfig -a
The assigned IP was not in the defined range by the router. In fact it was a public IP (this might be a sign that someone unauthorised tried to gain access). It seems the IP was defined static since a restart of the system or the router had no effect.
Here is the solution:
sudo ifconfig eth0 down
sudo ifconfig eth0 up
eth0 is the network interface with the wrong IP. If you are on another distribution than Ubuntu you may not need the sudo to bring the interface down and up again.
How to debug a Java Emitter template
Dienstag, 2. September 2008This is a tricky task. The generation of a piece of code – let’s assume that it is a Java class – is based on a java emitter template that defines with literal constants and JSP like syntax the code of the resulting class. To create a source file a Java generator class is generated from the template. This generator class produces dour output Java source file.
(weiterlesen …)