public static final void pad(Buffer buf, char c, int n) { byte b = (byte)c; while ( n-- > 0 ) buf.append(b); } }
public static final void pad(Buffer buf, char c, int n) { byte b = (byte)c; while ( n-- > 0 ) buf.append(b); } }
public void format(Buffer buf, byte c) { // TODO: not clear that any of width, precision, or flags apply here. buf.append(c); }
public static void pad(Buffer buf, char c, int n) { byte b = (byte)c; while ( n-- > 0 ) buf.append(b); } }
public void format(Buffer buf, byte c) { // TODO: not clear that any of width, precision, or flags apply here. buf.append(c); }
public void format(Buffer buf, byte c) { // TODO: not clear that any of width, precision, or flags apply here. buf.append(c); }
public void format(Buffer buf, double x) { // TODO buf.append( String.valueOf( x ) ); }
public void format(Buffer buf, double x) { // TODO buf.append( String.valueOf( x ) ); }
public void format(Buffer buf, double x) { // TODO buf.append( String.valueOf( x ) ); }
/** * Append a {@link LuaValue} to the buffer. * @return {@code this} to allow call chaining */ public final Buffer append( LuaValue val ) { append( val.strvalue() ); return this; }
/** * Append a {@link LuaValue} to the buffer. * @return {@code this} to allow call chaining */ public final Buffer append( LuaValue val ) { append( val.strvalue() ); return this; }
/** * Append a {@link LuaValue} to the buffer. * @return {@code this} to allow call chaining */ public final Buffer append( LuaValue val ) { append( val.strvalue() ); return this; }
/** Convert the list of varargs values to a human readable java String. * @return String value in human readable form such as {1,2}. */ public String tojstring() { Buffer sb = new Buffer(); sb.append( "(" ); for ( int i=1,n=narg(); i<=n; i++ ) { if (i>1) sb.append( "," ); sb.append( arg(i).tojstring() ); } sb.append( ")" ); return sb.tojstring(); }
/** Convert the list of varargs values to a human readable java String. * @return String value in human readable form such as {1,2}. */ public String tojstring() { Buffer sb = new Buffer(); sb.append( "(" ); for ( int i=1,n=narg(); i<=n; i++ ) { if (i>1) sb.append( "," ); sb.append( arg(i).tojstring() ); } sb.append( ")" ); return sb.tojstring(); }
/** Convert the list of varargs values to a human readable java String. * @return String value in human readable form such as {1,2}. */ public String tojstring() { Buffer sb = new Buffer(); sb.append( "(" ); for ( int i=1,n=narg(); i<=n; i++ ) { if (i>1) sb.append( "," ); sb.append( arg(i).tojstring() ); } sb.append( ")" ); return sb.tojstring(); }
public void format(Buffer buf, LuaString s) { int nullindex = s.indexOf( (byte)'\0', 0 ); if ( nullindex != -1 ) s = s.substring( 0, nullindex ); buf.append(s); }
public void format(Buffer buf, LuaString s) { int nullindex = s.indexOf( (byte)'\0', 0 ); if ( nullindex != -1 ) s = s.substring( 0, nullindex ); buf.append(s); }
public void format(Buffer buf, LuaString s) { int nullindex = s.indexOf( (byte)'\0', 0 ); if ( nullindex != -1 ) s = s.substring( 0, nullindex ); buf.append(s); }
/** Concatenate the contents of a table efficiently, using {@link Buffer} * * @param sep {@link LuaString} separater to apply between elements * @param i the first element index * @param j the last element index, inclusive * @return {@link LuaString} value of the concatenation */ public LuaValue concat(LuaString sep, int i, int j) { Buffer sb = new Buffer (); if ( i<=j ) { sb.append( get(i).checkstring() ); while ( ++i<=j ) { sb.append( sep ); sb.append( get(i).checkstring() ); } } return sb.tostring(); }
/** Concatenate the contents of a table efficiently, using {@link Buffer} * * @param sep {@link LuaString} separater to apply between elements * @param i the first element index * @param j the last element index, inclusive * @return {@link LuaString} value of the concatenation */ public LuaValue concat(LuaString sep, int i, int j) { Buffer sb = new Buffer (); if ( i<=j ) { sb.append( get(i).checkstring() ); while ( ++i<=j ) { sb.append( sep ); sb.append( get(i).checkstring() ); } } return sb.tostring(); }