public class Misc
extends java.lang.Object
Constructor and Description |
---|
Misc() |
Modifier and Type | Method and Description |
---|---|
static long |
applyTax(long lCents,
float fTax)
Apply tax rate as a percentage to an amount in cents
|
static long |
copyFile(java.lang.String sIn,
java.lang.String sOut) |
static java.sql.Connection |
DBCxn(java.lang.String sHost,
java.lang.String sUID,
java.lang.String sPwd,
java.lang.String sDB) |
static void |
main(java.lang.String[] argv) |
static java.lang.String |
mangleToPath(long lID)
Derive a relative path from 2-digit segments of a number
|
static long |
parseCents(java.lang.String sAmt)
Produce display-able text from a currency value represented as cents
|
static java.lang.String |
txtCents(long lCents)
Overload with implicit "false" value for bDollarSign
|
static java.lang.String |
txtCents(long lCents,
boolean bDollarSign)
Produce display-able text from a currency value represented as cents
|
static java.lang.String |
version() |
public static java.lang.String version()
public static void main(java.lang.String[] argv)
public static java.lang.String txtCents(long lCents, boolean bDollarSign)
lCents
- the currency value in centsbDollarSign
- whether or not to prepend the dollar signpublic static java.lang.String txtCents(long lCents)
public static long parseCents(java.lang.String sAmt)
sAmt
- the currency amount as textpublic static long applyTax(long lCents, float fTax)
lCents
- the currency value in centsfTax
- the tax rate as a floating point valuepublic static java.lang.String mangleToPath(long lID)
lID
- the number to derive the path frompublic static long copyFile(java.lang.String sIn, java.lang.String sOut)
public static java.sql.Connection DBCxn(java.lang.String sHost, java.lang.String sUID, java.lang.String sPwd, java.lang.String sDB)