Calling a method (I think?)
I'm still a bit new on the terminology. Here is what I have:
publicvoid CalcEngine ()
{
int dis = Integer.parseInt (iDis.getText ());
int rpm = Integer.parseInt (iRPM.getText ());
int ve = Integer.parseInt (iVE.getText ());
int cfm = ((dis * rpm) / 3456) * (ve) / 100;
double lbs = (((dis * rpm) / 3456) * (ve)) * 0.069 / 100;
BigDecimal bd =new BigDecimal (lbs);
bd = bd.setScale (1,BigDecimal.ROUND_UP);
lbs = bd.doubleValue ();
String tcfm = Integer.toString (cfm);
String tlbs = Double.toString (lbs);
oCFM.setText (tcfm);
oLBS.setText (tlbs);
}
I have an event that I want to call what I posted above, but I'm not quite sure how to do it nor do I know if I'm doing it right or if it's possible. I figure it is, but here is an example of what I'm trying to do:
privatevoid iVEFocusLost (java.awt.event.FocusEvent evt)
{
new CalcEngine ();
}
What would be the correct method to doing this?

