Archive for category Projects

Twitter client with Spring Social

Integrating social network activity into (customer) websites and because I have been using the Spring Framework and also Spring MVC and Spring Security for a long time, I decided to take a closer look at the Spring Social project. So I created a small application that should just display the timeline of my Twitter accounts and have the possibility to post something quickly.

Yes, I know my .css skills are incredible. 😉 I was missing an example to “quick and dirty” connect (and so authorise your social app to your account) and getting back the access token for testing the API without using a database or Spring Security on Spring Social samples, so I created a very simple way to connect to a Twitter account:

public class AuthController {
  private OAuth1Operations oauthOperations;
  private OAuthToken requestToken;
  @RequestMapping(value = "/connect", method = RequestMethod.GET)
  public String connect() {
    TwitterConnectionFactory connectionFactory = new TwitterConnectionFactory(CONSUMER_KEY, CONSUMER_SECRET);
    oauthOperations = connectionFactory.getOAuthOperations();
    requestToken = oauthOperations.fetchRequestToken("http://localhost:8080/callback", null);
    String authorizeUrl = oauthOperations.buildAuthorizeUrl(requestToken.getValue(), OAuth1Parameters.NONE);
    return "redirect:" + authorizeUrl;
  @RequestMapping(value = "/callback")
  public @ResponseBody OAuthToken callback(@RequestParam(value = "oauth_token") String oauthToken, @RequestParam(value = "oauth_verifier") String oauthVerifier) {
    OAuthToken accessToken = oauthOperations.exchangeForAccessToken(new AuthorizedRequestToken(requestToken, oauthVerifier), OAuth1Parameters.NONE);
    return accessToken;

, , , , ,

No Comments

Fun project: small role playing game

I always was interested in computer games, so I wanted to create a small role playing game for fun and self-education. In 2007 I started to do this from scratch, so I did not use any existing libraries, just plain Java. I decided to develop a tile-based 2D game engine. It is not finished yet (it is more work than one could expect at first sight if you want to do a good job), I work on it when I have time and feel like it.

Features that work at this time:

  • Walking around using the arrow or “WSAD”-keys
  • Collision detection and “hiding” behind greater items (like trees)
  • Mouse support on the map, left click: select an enemy or pick up items (weapon, shield, armor) to be added to inventory, right click: look at/read items
  • Inventory functionality (to open press “C”), mouse left click: inspecting items (weapon, shield, armor) in detail, mouse middle click: throw items away, mouse right click: equip items
  • Equipped items extend statistics of the player (more health, armor or damage)
  • Entering houses and other teleport events
  • Very basic balancing engine (with items attached, defeating an enemy is easier)
  • Two enemies walking on the map that will attack the player if (really) near, select enemy with a left click of the mouse to fight back, one ememy carries loot
  • Map editor to design new maps and all items on it

In 2007, using Java Web Start was quite a good idea and I did not change that so far.
Link to start: Game

, , ,

No Comments

Really old: job application

After I finished my schooldays, I did not want to create an ordinary job application like everyone else, so I decided to develop something in Java. Perhaps this makes sense if you want to apply for a job as Java Software Engineer. I created an own LookAndFeel to make my job application look custom and added all relevant information like certificates and curriculum vitae.

At the first step I built a CD containing a JRE, my .class-files, autorun-information and a start.bat for Windows and sent this to the companies I wanted to work for. The application was quite successful, so I extended it for following job applications: I added extra detailled information about projects and a possibility to print all information using Apache FOP over the time. With the increasing spread of the internet, I provided it via Java Web Start technology.

The last and latest version is still online (unfortunately only in german): Bewerbung
Because of the printing functionality it is necessary to permit accessing the system when starting up.

, , ,

No Comments


I wanted to test the Java framework Vaadin and to make this more interesting (and perhaps somehow useful), I decided to implement the of the game The Lord of the Rings Online by Turbine and create an armory/arsenal where the user can easily compare characters. I chose Castor XML as XML framework.

Unfortunatelly the is not always accessable and sometimes disabled by Turbine, so that it is not possible to get information from the server. Because of that I recently implemented a method to load “old” data from the local database by enabling the checkbox “Use local database”.
Furthermore the API is also not complete and not able to provide all data (e.g. newer items are often unavailable).

Possible test data:
Server: [DE-RP] Belegaer
Character: Gorothir
Enable checkbox “Use local database” if error occurs (which means that the is not available at this moment).

Link to LOTROArmory

, , , , , ,

No Comments