October 25, 2003

Creating Container-managed Entity Beans with JBoss

n Entity Bean is an Enterprise JavaBean (EJB) that represents a persistent object in a relational database. JBoss provides two methods of entity bean persistence, Bean Managed Persistence (BMP) and

Create a Statically Initialized List of Objects

A group of objects can be organized into arrays or collections. Arrays are nice because you can statically initialize them, but collections have far more functionality. Using this tip you

A Better Version of Bubble Sort

This version of bubble sort stops when there are no more exchanges and it also sorts a smaller range each time. void bubbleSort3(int x[], int n) { bool exchanges; do

Format Color for HTML

This function, which converts a color value into a string suitable for HTML, formats an RGB color value, palette index, or system color constant. You accomplish this by breaking out

Copy One Array to Another Without Using Loops or Conditions

Here’s the code the usage of arraycopy: public class testarrcopy{ public static void main(String arg[]) { //Array of any object can be user defined object String source[] ={“one”,”two”,”thr”,”four”,”five”,”six”,”sev”,”eight”,”nine”,”ten”}; //Array of

Change-proof Your Flat-file Processing with XML

very new enterprise system built today has to integrate with and support existing systems. Since the earliest days of programming, passing data between systems via flat files has been a

Time Conversion GMT to Current Time and Back

When you’re working in several time zones, you need to save date values in a common format?the most obvious one being GMT. The following stored procedures store datetime in GMT