public ExceptionDrivenStringBuilder append(int i) { try { length = NumberToChars.toChars(i, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 11); return append(i); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 11); return append(i); } return this; }
public ExceptionDrivenStringBuilder append(Date date) { try { length = DateIso8601.formatToChars(date, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 28); return append(date); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 28); return append(date); } return this; }
@Override public CharTreeNode<V> append(char b) { increase(b + 1); if (nodes[b] == null) nodes[b] = new SingleCharTreeNode<V>(); return this; }
@Override public void append(Date d) { int l = DateIso8601.formatToChars(d, buffer, 0); append(buffer, 0, l); }
public V findEnds(char[] chars, int offset, int length) { CharTreeNode<V> node = root; int l = chars.length - 1; for (int i = offset; i < offset + length && node != null && node.value == null; i++) { node = node.next(chars[l - i]); } return node == null ? null : node.value; }
public static int stringSizeOfWithMinus(int i) { if (i < 0) { if (i == Integer.MIN_VALUE) return 11; return stringSizeOf(-i) + 1; } return stringSizeOf(i); }
public ExceptionDrivenStringBuilder append(long i) { try { length = NumberToChars.toChars(i, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 20); return append(i); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 20); return append(i); } return this; }
public ExceptionDrivenStringBuilder append(Date date) { try { length = DateIso8601.formatToChars(date, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 28); return append(date); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 28); return append(date); } return this; }
@Override public CharTreeNode<V> append(char b) { increase(b + 1); if (nodes[b] == null) nodes[b] = new SingleCharTreeNode<V>(); return this; }
public ExceptionDrivenStringBuilder append(long i) { try { length = NumberToChars.toChars(i, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 20); return append(i); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 20); return append(i); } return this; }
public ExceptionDrivenStringBuilder append(int i) { try { length = NumberToChars.toChars(i, buffer, length); } catch (ArrayIndexOutOfBoundsException ex) { ensureCapacity(length + 11); return append(i); } catch (IndexOutOfBoundsException ex) { ensureCapacity(length + 11); return append(i); } return this; }