Win a copy of Head First Android this week in the Android forum!

Vilmantas Baranauskas

Ranch Hand
+ Follow
since Dec 20, 2006
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Vilmantas Baranauskas

If feature required change in 20 files, then all of these files should be committed with a single commit and single message, e.g (in subversion).:
svn commit -m "Fixed bug #4657."

This allows you to revert or merge this complete commit easily.

Long time ago I've read very good article explaining why commit-per-change is better than commit-per-file but I cannot find it.
Disclaimer: I've never used GIT and do not plan to use it in the foreseeable future, but...

You may consider changing your habit of committing random changes very often. Try to develop and commit on "per-feature" basis and write useful comments on commit.

By "per-feature" I mean, fixed bug #xzy, commit, implemented this-and-that, commit, refactored this-old-code, commit.

When you commit per-feature, then commit log files become more meaningful and your working style becomes more clear as well.
When compiling a java class, version number is included in each *.class file:

major version: 48 = Java SE 1.4.2
major version: 49 = Java SE 5
major version: 50 = Java SE 6

Your classes have been compiled on java 5, and you try to run them on Java <=1.4.
13 years ago
My favorite tools to create and parse XMLs are Velocity and Digester.

Velocity provides very nice overview over complete resulting XML.

Digester allows to easily reconstruct quite complicated object structures.
13 years ago
If your services talk only XML, i.e. return XML documents containing data, then the connection between catalog to basket is not necessary.

E.g. returns:

and returns:

The would return something like this:

And would accept putting any resource into it, e.g.

Such services are easy to implement, no connections are necessary between them and they are reusable from a third party app.

Now you only need GUI to use them. If you build GUI on the top of the same URLs then of course you will need to link from one to another. But your GUI may be a completely different URL where you simply use these 2 services.
[ July 08, 2008: Message edited by: Vilmantas Baranauskas ]
13 years ago

I'am using Axis (not Axis2) v1.4. Is there a way to read http request headers from implementation of my service. If yes, how?

Thank you,
13 years ago
If you are using BufferedReader to read incoming data, then you may write "\n" character to indicate end of line/word so readLine() returns a string as soon as it encounters this "\n".

And, you would probably want to use "UTF-8" instead of "US-ASCII" for converting strings to bytes and back again.
13 years ago
You could take the one from apache's commons collections:

13 years ago
Some suggestions to improve/simplify your code:

Use fileslist[i].endsWith(".pdf") instead of


instead of

13 years ago
Try adding this to CSS:

Or add it directly to your form in HTML:
My personal favorite method to do this is:


// or, depending on situation


I trust people from Jakarta commons lang to optimize this.
13 years ago
In your example "this" refers to your input field. "this.value" refers to the value of your input field.
Try this code:
13 years ago