Coverage Summary for Class: BorderStyle (it.polimi.ingsw.gc14.View.TUI)
| Class |
Class, %
|
Method, %
|
Line, %
|
| BorderStyle |
100%
(1/1)
|
100%
(14/14)
|
100%
(22/22)
|
package it.polimi.ingsw.gc14.View.TUI;
/**
* Defines the available border styles used to render {@link AsciiTable}
* instances in the text-based user interface.
*
* <p>Each style stores the characters needed to draw table corners,
* horizontal and vertical lines, and junctions.
*/
@SuppressWarnings("ALL")
public enum BorderStyle {
/**
* Rounded Unicode border style.
*/
ROUNDED("╭","╮","╰","╯","─","│","├","┤","┬","┴","┼","├","┤","┼");
/** Corner (tl/tr/bl/br), line (h/v), outer junction (ml/mr/mt/mb/x), and separator junction (sl/sr/sx) characters. */
private final String tl,tr,bl,br,h,v,ml,mr,mt,mb,x,sl,sr,sx;
BorderStyle(String tl,String tr,String bl,String br,
String h, String v, String ml,String mr,
String mt,String mb,String x,
String sl,String sr,String sx) {
this.tl = tl; this.tr = tr;
this.bl = bl; this.br = br;
this.h = h; this.v = v;
this.ml = ml; this.mr = mr;
this.mt = mt; this.mb = mb;
this.x = x;
this.sl = sl; this.sr = sr;
this.sx = sx;
}
/**
* @return the top-left corner character.
*/
public String tl() { return tl; }
/**
* @return the top-right corner character.
*/
public String tr() { return tr; }
/**
* @return the bottom-left corner character.
*/
public String bl() { return bl; }
/**
* @return the bottom-right corner character.
*/
public String br() { return br; }
/**
* @return the horizontal line character.
*/
public String h() { return h; }
/**
* @return the vertical line character.
*/
public String v() { return v; }
/**
* @return the top-middle junction character.
*/
public String mt() { return mt; }
/**
* @return the bottom-middle junction character.
*/
public String mb() { return mb; }
/**
* @return the separator-left junction character.
*/
public String sl() { return sl; }
/**
* @return the separator-right junction character.
*/
public String sr() { return sr; }
/**
* @return the separator center junction character.
*/
public String sx() { return sx; }
}