[quote user="clever_anthony"]I could not understand why a box requires baseX, baseY etc but no Z are defined. A box which has an X and Y, why it needs a baseX and topX? So that's why I want to see an example to learn how to use those parameters.[/quote]
The top/bottom faces of the box primitive aren't required to be the same size (i.e. it's a rectangular frustum). If you're not creating something like a truncated pyramid, then baseX/topX and baseY/topY will be the same value. The height (z) is defined by baseOrigin/topOrigin. So your snippet looks good other than vectorX/vectorY which I think you want to define as follows:
DVector3d vectorX = new DVector3d(1, 0, 0);
DVector3d vectorY = new DVector3d(0, 1, 0);
HTH
-B