当前位置: 首页>>代码示例>>Java>>正文


Java BorderSpecification类代码示例

本文整理汇总了Java中org.springframework.shell.table.BorderSpecification的典型用法代码示例。如果您正苦于以下问题:Java BorderSpecification类的具体用法?Java BorderSpecification怎么用?Java BorderSpecification使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


BorderSpecification类属于org.springframework.shell.table包,在下文中一共展示了BorderSpecification类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: applyStyleNoHeader

import org.springframework.shell.table.BorderSpecification; //导入依赖的package包/类
/**
 * Customize the given TableBuilder with almost same way than
 * {@link #applyStyle(TableBuilder)} but do not use any header styling.
 *
 * @param builder the table builder to use
 * @return the configured table builder
 */
public static TableBuilder applyStyleNoHeader(TableBuilder builder) {
	builder.addOutlineBorder(BorderStyle.fancy_double)
			.paintBorder(BorderStyle.air, BorderSpecification.INNER_VERTICAL).fromTopLeft().toBottomRight()
			.paintBorder(BorderStyle.fancy_light, BorderSpecification.INNER_VERTICAL).fromTopLeft()
			.toBottomRight();
	return Tables.configureKeyValueRendering(builder, " = ");
}
 
开发者ID:spring-cloud,项目名称:spring-cloud-skipper,代码行数:15,代码来源:TableUtils.java

示例2: applyStyle

import org.springframework.shell.table.BorderSpecification; //导入依赖的package包/类
/**
 * Customize the given TableBuilder with the following common features
 * (these choices can always be overridden by applying later customizations) :<ul>
 *     <li>double border around the whole table and first row</li>
 *     <li>vertical space (air) borders, single line separators between rows</li>
 *     <li>first row is assumed to be a header and is centered horizontally and vertically</li>
 *     <li>cells containing Map values are rendered as {@literal key = value} lines, trying to align on equal signs</li>
 * </ul>
 */
public static TableBuilder applyStyle(TableBuilder builder) {
	builder.addOutlineBorder(BorderStyle.fancy_double)
			.paintBorder(BorderStyle.air, BorderSpecification.INNER_VERTICAL)
			.fromTopLeft().toBottomRight()
			.paintBorder(BorderStyle.fancy_light, BorderSpecification.INNER_VERTICAL)
			.fromTopLeft().toBottomRight()
			.addHeaderBorder(BorderStyle.fancy_double)
			.on(CellMatchers.row(0))
			.addAligner(SimpleVerticalAligner.middle)
			.addAligner(SimpleHorizontalAligner.center)
	;
	return Tables.configureKeyValueRendering(builder, " = ");
}
 
开发者ID:spring-cloud,项目名称:spring-cloud-dashboard,代码行数:23,代码来源:DataFlowTables.java

示例3: applyStyle

import org.springframework.shell.table.BorderSpecification; //导入依赖的package包/类
/**
 * Customize the given TableBuilder with the following common features (these choices can
 * always be overridden by applying later customizations) :
 * <ul>
 * <li>double border around the whole table and first row</li>
 * <li>vertical space (air) borders, single line separators between rows</li>
 * <li>first row is assumed to be a header and is centered horizontally and
 * vertically</li>
 * <li>cells containing Map values are rendered as {@literal key = value} lines, trying to
 * align on equal signs</li>
 * </ul>
 *
 * @param builder the table builder to use
 * @return the configured table builder
 */
public static TableBuilder applyStyle(TableBuilder builder) {
	builder.addOutlineBorder(BorderStyle.fancy_double)
			.paintBorder(BorderStyle.air, BorderSpecification.INNER_VERTICAL).fromTopLeft().toBottomRight()
			.paintBorder(BorderStyle.fancy_light, BorderSpecification.INNER_VERTICAL).fromTopLeft()
			.toBottomRight()
			.addHeaderBorder(BorderStyle.fancy_double).on(CellMatchers.row(0))
			.addAligner(SimpleVerticalAligner.middle).addAligner(SimpleHorizontalAligner.center);
	return Tables.configureKeyValueRendering(builder, " = ");
}
 
开发者ID:spring-cloud,项目名称:spring-cloud-skipper,代码行数:25,代码来源:TableUtils.java

示例4: applyStyle

import org.springframework.shell.table.BorderSpecification; //导入依赖的package包/类
/**
 * Customize the given TableBuilder with the following common features (these choices
 * can always be overridden by applying later customizations) :
 * <ul>
 * <li>double border around the whole table and first row</li>
 * <li>vertical space (air) borders, single line separators between rows</li>
 * <li>first row is assumed to be a header and is centered horizontally and
 * vertically</li>
 * <li>cells containing Map values are rendered as {@literal key = value} lines,
 * trying to align on equal signs</li>
 * </ul>
 *
 * @param builder the table builder to use
 * @return the configured table builder
 */
public static TableBuilder applyStyle(TableBuilder builder) {
	builder.addOutlineBorder(BorderStyle.fancy_double)
			.paintBorder(BorderStyle.air, BorderSpecification.INNER_VERTICAL).fromTopLeft().toBottomRight()
			.paintBorder(BorderStyle.fancy_light, BorderSpecification.INNER_VERTICAL).fromTopLeft().toBottomRight()
			.addHeaderBorder(BorderStyle.fancy_double).on(CellMatchers.row(0))
			.addAligner(SimpleVerticalAligner.middle).addAligner(SimpleHorizontalAligner.center);
	return Tables.configureKeyValueRendering(builder, " = ");
}
 
开发者ID:spring-cloud,项目名称:spring-cloud-dataflow,代码行数:24,代码来源:DataFlowTables.java


注:本文中的org.springframework.shell.table.BorderSpecification类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。