Tallan's Blog

Tallan’s Experts Share Their Knowledge on Technology, Trends and Solutions to Business Challenges

Posts Tagged "Java"

Parsing HTML using jsoup library

Richard Krajunus

A quick tutorial on html parsing using the jsoup Java library.

Java EE 6 Overview

Dylan Barrett

For the past year or so I have been working on a web development project using Java.  Like many Java projects, the project I was working on used 3rd party frameworks like Spring and Hibernate rather than utilizing the official Java EE stack.  Many developers have turned to these frameworks because the official Java EE stack had been notoriously cumbersome and difficult to use.  That is starting to change.  Java EE 5 started moving Java EE in a new direction.  Inspired by the ideologies of the 3rd party frameworks, the JCP, the standards community that works on the Java specification, began to make radical changes to the core of Java EE.  These changes have continued in the latest iteration, Java EE 6.
Interested in comparing Java EE 6 to my experiences with Spring and Hibernate, I picked up a book on…

The Unstandard Tag Library: Using Constants Within JSPs

Dylan Barrett

The Unstandard Tag Library is a JSP tag library that was developed as part of the Jakarta Project. Its purpose is to provide a collection of useful tags that people have been requesting for JSTL. The library serves as a place to keep all of these tags until they are officially added to the Standard Tag Library. This article focuses on the use of one of the tags contained within the library, the useConstants tag.
The Problem
While working on a project for a client, I realized that they were using a Java class with constants to define strings used within the application. The idea was to use the constants everywhere in the application where the strings were needed so they could easily be maintained in one location without having to search through the whole application when making a change. This makes…

Java could be a pain to C# developers (Pass by Reference)

In C++ and C#, developers have freedom to modify variables by directly having access to memory location.
In C++,
#include <stdio.h>
void swapnum(int &i, int &j)
int temp = i;
i = j;
j = temp;

int main(void)
int a = 10;
int b = 20;
swapnum(a, b);
printf(“A is %d and B is %d\n”, a, b);
return 0;
In C#,
int a = 1;
modify(ref a); //now a=2
void modify(ref int a)
a = 2;
In Java, however, there’s no such thing as pass by reference. Even the so-called pointers (created by ‘new’ operator) are passed by copy of the reference.
Thus, if you do the following,
String a…