Quantcast
Channel: //CodeNewfie » Programming
Viewing all articles
Browse latest Browse all 3

Twitter’D

$
0
0

For my Web Applications class (Comp 3715) we had to create a web application that would be useful in real world scenarios or that did something interesting or unique.

My project was Twitter’d (A play on the word Maitre’D), a web app for managing reservations in a hotel / restauraunt scenario. The unique feature (and reason behind the use of the word twitter in the name) is that using a premade twitter account for the applications, twitter users could use an @Mention to the account to make reservations easily! The host could then use the web application, which is meant to be used locally or on an intranet, to approve these requests over twitter or to make reservations manually. The application would also tweet each time a reservation was made, stating the number of reservations that were remaining in total to inform people whether or not they were booked for the night or still available.

(Click below for technical details and to download the project files)

The project is built using Java and the jetty library. (Not my choice as I despise most things Java. It was never a language built for efficiency and the idea of using it as a web server appalls me. Using Jetty was a requirement for the course. *eye roll*) It utilizes a custom web server and servlet container with each function of the application (such as making a reservation, viewing a reservation, etc) being a separate servlet. Theres no database requirement for storing reservations as it just makes use of DOM and an XML file to store reservation data.

The client side uses pretty basic Javascript and HTML with ajax functionality to get the request and reservation information from the server.

The twitter functionality uses the twitter4j library and originally caught me off guard. Since I’m not a frequent twitter api user or application developer I had not known twitter had switched from basic authentication methods to OAuth authentication with tokens.

Features that I wish I could have added but didn’t have time include:

  • A configuration page, as it stands all configuration has to be done in the code.
  • A calender based reservation interface, right now you can only make reservations in general and would have to cancel them for each new day.
  • A web interface for customers to make reservation requests.
  • A login authentication system. Right now everyone who visits is thought to be the host / Maitre’D (Whoops :P )
  • Real-time twitter request loading on the view requests page, right now you have to refresh the page,
  • Removing approved or denied twitter requests from the request list.

My project is available for download here. The file and directory structure follows the WAR web application archive and there is an included read-me file which may help with configuring your twitter account with the app as I didn’t provide a configuration page. (Sorry)


Viewing all articles
Browse latest Browse all 3

Latest Images

Trending Articles





Latest Images