Java Utililty Methods Zero Format

List of utility methods to do Zero Format

Description

The list of methods to do Zero Format are organized into topic(s).

Method

voidzeroMatrix(int M, int N, double mat[][])
zero Matrix
for (int i = M - 1; i >= 0; i--) {
    for (int j = N - 1; j >= 0; j--)
        mat[i][j] = 0.0D;
Object[]zeroObjects()
zero Objects
return EMPTY_OBJECT_ARRAY;
Boolean[]ZeroOneStringToBooleanArray(String data)
Zero One String To Boolean Array
char[] zeroOneChars = data.trim().replace(" ", "").toCharArray();
Boolean[] booleanResult = new Boolean[zeroOneChars.length];
int i = 0;
for (char bit : zeroOneChars) {
    booleanResult[i] = (bit == '1');
    ++i;
return booleanResult;
...
floatzeroOrderBessel(float num)
zero Order Bessel
float d = 0;
float ds = 1;
float s = 1;
do {
    d += 2;
    ds *= num * num / (d * d);
    s += ds;
} while (ds > (s * 1e-6f));
...
StringzeroOrMore(String... patterns)
zero Or More
return _group("*", patterns);
voidzeroOut(byte[] array)
Overwrites a byte array with zeros
for (int i = 0; i < array.length; i++)
    array[i] = 0;
voidZeroPoleFilter(float In[], int In_idx, float ZeroCoef[], float PoleCoef[], int PoleCoef_idx, int lengthInOut, int orderCoef, float Out[], int Out_idx)
Zero Pole Filter
AllZeroFilter(In, In_idx, ZeroCoef, lengthInOut, orderCoef, Out, Out_idx);
AllPoleFilter(Out, Out_idx, PoleCoef, PoleCoef_idx, lengthInOut, orderCoef);
StringzeroPrefix(String str, int width)
zero Prefix
return prefix(str, '0', width);
StringzeroPrepend(long num, int digits)
Return the string prepended with 0s.
final String hash = Long.toString(num);
if (hash.length() >= digits) {
    return hash;
} else {
    final int zeroCount = digits - hash.length();
    final StringBuilder buffer = new StringBuilder(digits).append(BLOCK_OF_ZEROS, 0, zeroCount)
            .append(hash);
    return buffer.toString();
...
String[]ZeroRemover(String[] a)
Zero Remover
if (NeedRemove(a)) {
    for (int i = 0; i < a.length; i++) {
        String aString = a[i];
        aString = aString.substring(0, aString.length() - 1);
        if (aString.endsWith("."))
            aString = aString.substring(0, aString.length() - 1);
        a[i] = aString;
} else
    return a;
if (NeedRemove(a)) {
    for (int i = 0; i < a.length; i++) {
        String aString = a[i];
        aString = aString.substring(0, aString.length() - 1);
        if (aString.endsWith("."))
            aString = aString.substring(0, aString.length() - 1);
        a[i] = aString;
} else
    return a;
if (NeedRemove(a)) {
    for (int i = 0; i < a.length; i++) {
        String aString = a[i];
        aString = aString.substring(0, aString.length() - 1);
        if (aString.endsWith("."))
            aString = aString.substring(0, aString.length() - 1);
        a[i] = aString;
} else
    return a;
return a;