java/sql-dk/src/info/globalcode/sql/dk/formatting/TabularFormatter.java
branchv_0
changeset 167 84aaa91642bf
parent 155 eb3676c6929b
child 169 4e131a0b521a
equal deleted inserted replaced
166:5488c2dcf680 167:84aaa91642bf
    21 import static info.globalcode.sql.dk.ColorfulPrintWriter.*;
    21 import static info.globalcode.sql.dk.ColorfulPrintWriter.*;
    22 import static info.globalcode.sql.dk.Functions.lpad;
    22 import static info.globalcode.sql.dk.Functions.lpad;
    23 import static info.globalcode.sql.dk.Functions.rpad;
    23 import static info.globalcode.sql.dk.Functions.rpad;
    24 import static info.globalcode.sql.dk.Functions.repeat;
    24 import static info.globalcode.sql.dk.Functions.repeat;
    25 import java.util.List;
    25 import java.util.List;
       
    26 import java.util.Scanner;
    26 
    27 
    27 /**
    28 /**
    28  * <p>Prints human-readable output – tables of result sets and text messages with update counts.</p>
    29  * <p>Prints human-readable output – tables of result sets and text messages with update counts.</p>
    29  *
    30  *
    30  * <p>Longer values might break the table – overflow the cells – see alternative tabular formatters
    31  * <p>Longer values might break the table – overflow the cells – see alternative tabular formatters
   273 			out.print(TerminalColor.Cyan, valuePart);
   274 			out.print(TerminalColor.Cyan, valuePart);
   274 			if (i < valueParts.length - 1) {
   275 			if (i < valueParts.length - 1) {
   275 				out.print(TerminalColor.Red, "↲");
   276 				out.print(TerminalColor.Red, "↲");
   276 			}
   277 			}
   277 		}
   278 		}
       
   279 
       
   280 		if (valueString.endsWith("\n")) {
       
   281 			out.print(TerminalColor.Red, "↲");
       
   282 		}
   278 	}
   283 	}
   279 }
   284 }