Example usage for org.apache.commons.lang.builder StandardToStringStyle setFieldNameValueSeparator

List of usage examples for org.apache.commons.lang.builder StandardToStringStyle setFieldNameValueSeparator

Introduction

In this page you can find the example usage for org.apache.commons.lang.builder StandardToStringStyle setFieldNameValueSeparator.

Prototype

public void setFieldNameValueSeparator(String fieldNameValueSeparator) 

Source Link

Document

Sets the field name value separator text.

null is accepted, but will be converted to an empty String.

Usage

From source file:com.krminc.phr.domain.clinical.CcrProblem.java

@Override
public String toString() {
    final StandardToStringStyle style = new StandardToStringStyle();
    style.setNullText("---NULL---");
    style.setFieldSeparator(";\n");
    style.setArrayStart("{{{");
    style.setArrayEnd("}}}");
    style.setArraySeparator("|");
    style.setFieldNameValueSeparator(":");
    return (new ReflectionToStringBuilder(this, style) {

        protected boolean accept(Field f) {
            return super.accept(f) && !f.getName().equals("ccrDocument");
        }//  w w w  .j  a v  a  2s . com
    }).toString();
}

From source file:com.krminc.phr.domain.clinical.CcrActor.java

@Override
public String toString() {
    final StandardToStringStyle style = new StandardToStringStyle();
    style.setNullText("---NULL---");
    style.setFieldSeparator(";\n");
    style.setArrayStart("{{{");
    style.setArrayEnd("}}}");
    style.setArraySeparator("|");
    style.setFieldNameValueSeparator(":");
    return ToStringBuilder.reflectionToString(this, style);
}

From source file:com.krminc.phr.domain.clinical.CcrDocument.java

@Override
public String toString() {
    final StandardToStringStyle style = new StandardToStringStyle();
    style.setNullText("---NULL---");
    style.setFieldSeparator(";\n");
    style.setArrayStart("{{{");
    style.setArrayEnd("}}}");
    style.setArraySeparator("|");
    style.setFieldNameValueSeparator(":");
    return (new ReflectionToStringBuilder(this, style) {

        protected boolean accept(Field f) {
            return super.accept(f) && !f.getName().equals("body");
        }//from w  w  w  .j  a  v a  2  s  . c  o m
    }).toString();
}