Platinum Solutions Corporate Website


Business Logic

Selecting HTML Elements by Label

Here's a little trick that I wish every web page with a form would use:

Reverse Engineer JPA Entities with Eclipse 3.3 and MySQL

Introduction

Software developers are typically rather laid back and "chill" people. However, when the conversation turns to programming languages, web frameworks, development tools etc. things can get a little heated. This can be especially true when it comes to their IDE of choice. I have seen some very polite and mellow people turn into a software developer incarnation of Bill O'Reily (Fox News) while defending their choice of IDE.

Speed up Windows XP from CNet Training

Hello all,

This is a tip that has helped me immediately with slow computers. I always followed the routine of eliminating unused programs, tmp files etc and defragging. But CNET shows you how to get your computer rolling again with no hassle.

Try it, you'll like it.

http://speed-up-windows-pc.classes.cnet.com/lesson-1/

Don

“Tech transfer”: Making the transition from school to work

I’ve learned a few lessons since graduating with a computer science degree, and beginning my first job in the tech industry with Platinum Solutions. Here are the five best tips I can offer:

1. Don’t work in a cave

Hibernate Gotcha

I ran into a "gotcha" with Hibernate this past week.

I was working with an Oracle database where there are tables with synthetic (aka surrogate) keys that get their values from sequences -- a fairly common thing, and a situation that Hibernate normally handles well with identity generator class of "sequence" or "native".

But in this case, the Oracle database was using a before-insert trigger to get nextval from the sequence and stuff it into the primary key field before inserting the row into the table.  The rationale for this was to ensure consistent management of the sequence for other code than the Hibernate/Java system that might hit the database.

Agile without "The Agile"

I recently came across this blog, and to sum it up (its rather long); there are a lot of things wrong with what we'll call Formal Agile.  Basically, Formal Agile is, for lack of better term, ritualistic in its various approaches: task cards, sprints, pair programming, XP, test-first development, etc... And here we were thinking that the point of agility was to loosen constraints in a way that still kept us on target.  And contrary to conventional wisdom, its not Waterfall or Agile; there are other options. 

Some Weird Java Behavior

Here's a little Java trivia....

While building some GUI screens for an Eclipse RCP application, I came across what I consider to be strange behavior in the Java language. Instead of trying to explain it, take a look at the below code:

Parent.java
================================================
public abstract class Parent
{
    public Parent()
    {
        setVarAValue();
    }
    public static void main( String args[] )
    {
        Child child = new Child();
        System.out.println( "varA = [" + child.getVarAValue() + "]" );
    }
    
    protected abstract void setVarAValue();
    protected abstract String getVarAValue();
}

class Child extends Parent
{
    private String varA = null;
    public Child()
    {
        super();
    }
    
    public String getVarAValue()
    {
        return varA;
    }

    protected void setVarAValue()
    {
        varA = "a value";
    }
}
================================================

Platinum Solutions Blog Login

User login


Using Rules Engines

The basic idea behind using a rules engine is to simplify business logic in an application (or in some cases provide cross-application business logic).

The effect here is to remove hierarchical dependencies on logic conditionals and allow each condition (and subsequent action) exist on its own.

A simple example without forward chaining characteristics would be:

standard:

if(A){
if(B){
//do something
}
elseif (C){
//do other
}
}
else {
//do something else
}

engine:

if(A and B){
//do something
}
if(A and C){
//do other
}
if(not A){
//do something else
}

Yes, this style of logic can already be done in Java or any other language.