Java Code Examples for org.apache.commons.lang3.builder.ToStringStyle

The following examples show how to use org.apache.commons.lang3.builder.ToStringStyle. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: supplierShop   Source File: StoreSpecGoodsPrice.java    License: MIT License 6 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("itemId", getItemId())
        .append("goodsId", getGoodsId())
        .append("key", getKey())
        .append("keyName", getKeyName())
        .append("price", getPrice())
        .append("marketPrice", getMarketPrice())
        .append("storeCount", getStoreCount())
        .append("barCode", getBarCode())
        .append("sku", getSku())
        .append("specImg", getSpecImg())
        .append("promId", getPromId())
        .append("promType", getPromType())
        .toString();
}
 
Example 2
Source Project: NutzSite   Source File: Task.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("name", getName())
            .append("jobClass", getJobClass())
            .append("note", getNote())
            .append("cron", getCron())
            .append("data", getData())
            .append("exeAt", getExeAt())
            .append("exeResult", getExeResult())
            .append("status", isStatus())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
}
 
Example 3
Source Project: LuckyFrameWeb   Source File: Job.java    License: GNU Affero General Public License v3.0 6 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("jobId", getJobId())
        .append("jobName", getJobName())
        .append("jobGroup", getJobGroup())
        .append("methodName", getMethodName())
        .append("methodParams", getMethodParams())
        .append("cronExpression", getCronExpression())
        .append("nextValidTime", getNextValidTime())
        .append("misfirePolicy", getMisfirePolicy())
        .append("status", getStatus())
        .append("createBy", getCreateBy())
        .append("createTime", getCreateTime())
        .append("updateBy", getUpdateBy())
        .append("updateTime", getUpdateTime())
        .append("remark", getRemark())
        .toString();
}
 
Example 4
public String toString() {
     return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
         .append("stepId", getStepId())
         .append("caseId", getCaseId())
         .append("projectId", getProjectId())
         .append("stepSerialNumber", getStepSerialNumber())
         .append("stepPath", getStepPath())
         .append("stepOperation", getStepOperation())
         .append("stepParameters", getStepParameters())
         .append("action", getAction())
         .append("expectedResult", getExpectedResult())
         .append("stepType", getStepType())
         .append("extend", getExtend())
.append("stepRemark", getStepRemark())
         .append("createBy", getCreateBy())
         .append("createTime", getCreateTime())
         .append("updateBy", getUpdateBy())
         .append("updateTime", getUpdateTime())
         .toString();
 }
 
Example 5
Source Project: hbase   Source File: RegionReplicaInfo.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
  return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
    .append("row", Bytes.toStringBinary(row))
    .append("regionInfo", regionInfo)
    .append("regionState", regionState)
    .append("serverName", serverName)
    .append("seqNum", seqNum)
    .append("transitioningOnServerName", targetServerName)
    .append("merge*", mergeRegionInfo)
    .append("split*", splitRegionInfo)
    .toString();
}
 
Example 6
Source Project: hadoop-ozone   Source File: BenchmarkBlockDataToString.java    License: Apache License 2.0 5 votes vote down vote up
@Benchmark
public void usingToStringBuilder(
    BenchmarkBlockDataToString state, Blackhole sink) {
  for (int i = 0; i < state.count; i++) {
    BlockData item = state.data.get(i);
    String str = new ToStringBuilder(item, ToStringStyle.NO_CLASS_NAME_STYLE,
        new StringBuffer(capacity))
        .append("blockId", item.getBlockID().toString())
        .append("size", item.getSize())
        .toString();
    sink.consume(str);
    Preconditions.checkArgument(str.equals(state.values.get(i)));
  }
}
 
Example 7
Source Project: wurmloch-crdt   Source File: PNCounter.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
            .appendSuper(super.toString())
            .append("pEntries", pEntries)
            .append("nEntries", nEntries)
            .toString();
}
 
Example 8
Source Project: obevo   Source File: ExtraIndexInfo.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
            .append("tableName", tableName)
            .append("indexName", indexName)
            .append("constraint", constraint)
            .append("clustered", clustered)
            .toString();
}
 
Example 9
Source Project: jadira   Source File: JPackage.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
	
	ToStringBuilder builder = new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE);
	builder.append("name", this.getName());
	
	return builder.toString();
}
 
Example 10
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("planCaseId", getPlanCaseId())
        .append("caseId", getCaseId())
        .append("planId", getPlanId())
        .append("priority", getPriority())
        .toString();
}
 
Example 11
Source Project: weixin-java-tools   Source File: WxCpUserServiceImplTest.java    License: Apache License 2.0 5 votes vote down vote up
@Test
public void testListSimpleByDepartment() throws Exception {
  List<WxCpUser> users = this.wxCpService.getUserService().listSimpleByDepartment(1, true, 0);
  assertNotEquals(users.size(), 0);
  for (WxCpUser user : users) {
    System.out.println(ToStringBuilder.reflectionToString(user, ToStringStyle.MULTI_LINE_STYLE));
  }
}
 
Example 12
Source Project: secure-data-service   Source File: MongoSearchRepository.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public Iterable<Entity> findAll(String collectionName, NeutralQuery neutralQuery) {
    LOG.info(">>>MongoSearchRepository.findAll()");
    LOG.info("   collectionName: " + collectionName);
    LOG.info("   neutralQuery: " + ToStringBuilder.reflectionToString(neutralQuery, ToStringStyle.MULTI_LINE_STYLE));
    //return ReadConverter.fromSearchJson(queryForSearch(getQuery(neutralQuery, false)));
    String qry = getQuery(neutralQuery, false);
    queryForSearch(qry);
    LOG.info("<<<MongoSearchRepository.findAll()");
    return null;
}
 
Example 13
Source Project: sailfish-core   Source File: ReportTable.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
    ToStringBuilder builder = new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE);

    builder.append("name", name);
    builder.append("header", header);
    builder.append("rows", rows);

    return builder.toString();
}
 
Example 14
Source Project: iaf   Source File: ReceiverBase.java    License: Apache License 2.0 5 votes vote down vote up
/**
 *  Returns a toString of this class by introspection and the toString() value of its listener.
 *
 * @return Description of the Return Value
 */
@Override
public String toString() {
	String result = super.toString();
	ToStringBuilder ts=new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE);
	ts.append("name", getName() );
	result += ts.toString();
	result+=" listener ["+(listener==null ? "-none-" : listener.toString())+"]";
	return result;
}
 
Example 15
Source Project: supplierShop   Source File: SysLogininfor.java    License: MIT License 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("infoId", getInfoId())
        .append("loginName", getLoginName())
        .append("ipaddr", getIpaddr())
        .append("loginLocation", getLoginLocation())
        .append("browser", getBrowser())
        .append("os", getOs())
        .append("status", getStatus())
        .append("msg", getMsg())
        .append("loginTime", getLoginTime())
        .toString();
}
 
Example 16
Source Project: async-gamequery-lib   Source File: CocPlayerBasicInfo.java    License: MIT License 5 votes vote down vote up
protected ToStringBuilder superStringBuilder() {
    return new ToStringBuilder(this, ToStringStyle.NO_CLASS_NAME_STYLE)
            .append("name", getName())
            .append("tag", getTag())
            .append("role", getRole())
            .append("trophies", getTrophies())
            .append("expLevel", getExpLevel());
}
 
Example 17
Source Project: wurmloch-crdt   Source File: TwoPSet.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
            .appendSuper(super.toString())
            .append("crdtId", getCrdtId())
            .append("element", element)
            .toString();
}
 
Example 18
Source Project: jadira   Source File: ClasspathResolver.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {

	ToStringBuilder builder = new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE);
	builder.append(getDriverData().toArray());

	return builder.toString();
}
 
Example 19
Source Project: Bats   Source File: StreamingContainerManager.java    License: Apache License 2.0 5 votes vote down vote up
/**
 * @return String
 */
@Override
public String toString()
{
  return new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE)
    .append("containerId", this.containerId)
    .append("host", this.host)
    .append("memoryMB", this.memoryMB)
    .toString();
}
 
Example 20
Source Project: seed   Source File: FastjsonTest.java    License: Apache License 2.0 5 votes vote down vote up
/**
 * 测试json解析为子类对象时,是否会解析包含的父类属性
 */
@Test
public void javabeanParse(){
    UserChild uc = new UserChild();
    uc.setId(2);
    uc.setName("玄玉");
    uc.setSex("M");
    String jsonStr = JSON.toJSONString(uc);
    System.out.println("生成了-->" + jsonStr);
    UserChild userChild = JSON.parseObject(jsonStr, UserChild.class);
    System.out.println("解析到-->" + ReflectionToStringBuilder.toString(userChild, ToStringStyle.MULTI_LINE_STYLE));
}
 
Example 21
Source Project: td-ameritrade-client   Source File: FullInstrument.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
  return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
      .appendSuper(super.toString())
      .append("fundamental", fundamental)
      .toString();
}
 
Example 22
Source Project: inception   Source File: KBStatement.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString()
{
    return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
            .append("statementId", statementId)
            .append("instance", instance)
            .append("property", property)
            .append("value", value)
            .append("valueLabel", valueLabel)
            .append("language", language)
            .append("inferred", inferred)
            .append("originalTriples", originalTriples)
            .append("qualifiers", qualifiers).toString();
}
 
Example 23
Source Project: NutzSite   Source File: Dict.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("value", getValue())
            .append("label", getLabel())
            .append("type", getType())
            .append("description", getDescription())
            .append("sort", getSort())
            .append("parentId", getParentId())
            .append("createBy", getCreateBy())
            .append("remarks", getRemarks())
            .toString();
}
 
Example 24
Source Project: RuoYi-Vue   Source File: SysRoleDept.java    License: MIT License 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("roleId", getRoleId())
        .append("deptId", getDeptId())
        .toString();
}
 
Example 25
Source Project: RuoYi-Vue   Source File: SysUserRole.java    License: MIT License 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("userId", getUserId())
        .append("roleId", getRoleId())
        .toString();
}
 
Example 26
Source Project: iaf   Source File: XmlTypeToJsonSchemaConverter.java    License: Apache License 2.0 5 votes vote down vote up
public JsonStructure createJsonSchema(String elementName, String namespace) {
	XSElementDeclaration elementDecl=findElementDeclaration(elementName, namespace);
	if (elementDecl==null && namespace!=null) {
		elementDecl=findElementDeclaration(elementName, null);
	}
	if (elementDecl==null) {
		log.warn("Cannot find declaration for element ["+elementName+"]");
		if (log.isTraceEnabled()) 
			for (XSModel model:models) {
				log.trace("model ["+ToStringBuilder.reflectionToString(model,ToStringStyle.MULTI_LINE_STYLE)+"]");
			}
		return null;
	}
	return createJsonSchema(elementName, elementDecl);
}
 
Example 27
Source Project: ruoyiplus   Source File: SysConfig.java    License: MIT License 5 votes vote down vote up
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("configId", getConfigId())
        .append("configName", getConfigName())
        .append("configKey", getConfigKey())
        .append("configValue", getConfigValue())
        .append("configType", getConfigType())
        .append("createBy", getCreateBy())
        .append("createTime", getCreateTime())
        .append("updateBy", getUpdateBy())
        .append("updateTime", getUpdateTime())
        .append("remark", getRemark())
        .toString();
}
 
Example 28
@Override
public String toString() {
    return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
        .append("userId", getUserId())
        .append("postId", getPostId())
        .toString();
}
 
Example 29
Source Project: td-ameritrade-client   Source File: MutualFundInstrument.java    License: Apache License 2.0 5 votes vote down vote up
@Override
public String toString() {
  return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
      .appendSuper(super.toString())
      .append("type", type)
      .toString();
}
 
Example 30
Source Project: weixin-java-tools   Source File: WxCpUserServiceImplTest.java    License: Apache License 2.0 5 votes vote down vote up
@Test
public void testListByDepartment() throws Exception {
  List<WxCpUser> users = this.wxCpService.getUserService().listByDepartment(1, true, 0);
  assertNotEquals(users.size(), 0);
  for (WxCpUser user : users) {
    System.out.println(ToStringBuilder.reflectionToString(user, ToStringStyle.MULTI_LINE_STYLE));
  }
}