int ePos = -1; if (conversionCharacter == 'g') { sx = eFormatString(x, 'e').trim(); ePos = sx.indexOf('e'); } else { sx = eFormatString(x, 'E').trim(); ePos = sx.indexOf('E'); sy = fFormatString(x).trim(); else sy = sx.substring(0, ePos); } else { if (expon >= -4 && expon < precision) ret = fFormatString(x).trim(); else ret = sx; ca5 = applyFloatPadding(ca4, false); precision = savePrecision; return new String(ca5);
break; if (i0 + p < ca1.length - 1) { carry = checkForCarry(ca1, i0 + p + 1); if (carry) carry = startSymbolicCarry(ca1, i0 + p, i0); if (carry) { ca2 = new char[i0 + p + 1];
noDigits = true; } else ca4 = eFormatDigits(x, eChar); ca5 = applyFloatPadding(ca4, false); return new String(ca5);
break; if (i0 + p < ca1.length - 1) { carry = checkForCarry(ca1, i0 + p + 1); if (carry) carry = startSymbolicCarry(ca1, i0 + p, i0); if (carry) { ca2 = new char[i0 + p + 1];
else i = p + n1In; carry = checkForCarry(ca3, i); if (carry) carry = startSymbolicCarry(ca3, i - 1, 0);
else i = p + n1In; carry = checkForCarry(ca3, i); if (carry) carry = startSymbolicCarry(ca3, i - 1, 0);
int ePos = -1; if (conversionCharacter == 'g') { sx = eFormatString(x, 'e').trim(); ePos = sx.indexOf('e'); } else { sx = eFormatString(x, 'E').trim(); ePos = sx.indexOf('E'); sy = fFormatString(x).trim(); else sy = sx.substring(0, ePos); } else { if (expon >= -4 && expon < precision) ret = fFormatString(x).trim(); else ret = sx; ca5 = applyFloatPadding(ca4, false); precision = savePrecision; return new String(ca5);
String unCS = this.nonControl(fmtArg, 0); if (unCS != null) { sFmt = new ConversionSpecification(); sFmt.setLiteral(unCS); vFmt.addElement(sFmt); sFmt = new ConversionSpecification(fmtArg.substring(cPos, ePos)); vFmt.addElement(sFmt); unCS = this.nonControl(fmtArg, ePos); if (unCS != null) { sFmt = new ConversionSpecification(); sFmt.setLiteral(unCS); vFmt.addElement(sFmt);
String unCS = this.nonControl(fmtArg, 0); if (unCS != null) { sFmt = new ConversionSpecification(); sFmt.setLiteral(unCS); vFmt.addElement(sFmt); sFmt = new ConversionSpecification(fmtArg.substring(cPos, ePos)); vFmt.addElement(sFmt); unCS = this.nonControl(fmtArg, ePos); if (unCS != null) { sFmt = new ConversionSpecification(); sFmt.setLiteral(unCS); vFmt.addElement(sFmt);
while (e.hasMoreElements()) { cs = (ConversionSpecification) e.nextElement(); c = cs.getConversionCharacter(); if (c == '\0') sb.append(cs.getLiteral()); else if (c == '%') sb.append("%"); else { if (cs.isPositionalSpecification()) { i = cs.getArgumentPosition() - 1; if (cs.isPositionalFieldWidth()) { int ifw = cs.getArgumentPositionForFieldWidth() - 1; cs.setFieldWidthWithArg(((Integer) o[ifw]).intValue()); if (cs.isPositionalPrecision()) { int ipr = cs.getArgumentPositionForPrecision() - 1; cs.setPrecisionWithArg(((Integer) o[ipr]).intValue()); if (cs.isVariableFieldWidth()) { cs.setFieldWidthWithArg(((Integer) o[i]).intValue()); i++; if (cs.isVariablePrecision()) { cs.setPrecisionWithArg(((Integer) o[i]).intValue()); i++; sb.append(cs.internalsprintf(((Byte) o[i]).byteValue())); else if (o[i] instanceof Short) sb.append(cs.internalsprintf(((Short) o[i]).shortValue()));
while (e.hasMoreElements()) { cs = (ConversionSpecification) e.nextElement(); c = cs.getConversionCharacter(); if (c == '\0') sb.append(cs.getLiteral()); else if (c == '%') sb.append("%"); else { if (cs.isPositionalSpecification()) { i = cs.getArgumentPosition() - 1; if (cs.isPositionalFieldWidth()) { int ifw = cs.getArgumentPositionForFieldWidth() - 1; cs.setFieldWidthWithArg(((Integer) o[ifw]).intValue()); if (cs.isPositionalPrecision()) { int ipr = cs.getArgumentPositionForPrecision() - 1; cs.setPrecisionWithArg(((Integer) o[ipr]).intValue()); if (cs.isVariableFieldWidth()) { cs.setFieldWidthWithArg(((Integer) o[i]).intValue()); i++; if (cs.isVariablePrecision()) { cs.setPrecisionWithArg(((Integer) o[i]).intValue()); i++; sb.append(cs.internalsprintf(((Byte) o[i]).byteValue())); else if (o[i] instanceof Short) sb.append(cs.internalsprintf(((Short) o[i]).shortValue()));
noDigits = true; } else ca4 = eFormatDigits(x, eChar); ca5 = applyFloatPadding(ca4, false); return new String(ca5);
noDigits = true; } else ca6 = fFormatDigits(x); ca7 = applyFloatPadding(ca6, false); return new String(ca7);
noDigits = true; } else ca6 = fFormatDigits(x); ca7 = applyFloatPadding(ca6, false); return new String(ca7);
/** * Format method for the e or E conversion character. * * @param x * the double to format. * @return the formatted String. */ private String printEFormat(double x) { if (conversionCharacter == 'e') return eFormatString(x, 'e'); else return eFormatString(x, 'E'); }
/** * Format method for the e or E conversion character. * * @param x * the double to format. * @return the formatted String. */ private String printEFormat(double x) { if (conversionCharacter == 'e') return eFormatString(x, 'e'); else return eFormatString(x, 'E'); }
/** * Format method for the f conversion character. * * @param x * the double to format. * @return the formatted String. */ private String printFFormat(double x) { return fFormatString(x); }
/** * Format method for the f conversion character. * * @param x * the double to format. * @return the formatted String. */ private String printFFormat(double x) { return fFormatString(x); }