本文整理了Java中com.redhat.lightblue.util.JsonUtils.toString()
方法的一些代码示例,展示了JsonUtils.toString()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JsonUtils.toString()
方法的具体详情如下:
包路径:com.redhat.lightblue.util.JsonUtils
类名称:JsonUtils
方法名:toString
暂无
代码示例来源:origin: com.redhat.lightblue/lightblue-core-util
/**
* Pretty print a json doc
*/
public static void prettyPrint(StringBuilder bld, JsonNode node) {
toString(bld, node, 0, true);
}
代码示例来源:origin: com.redhat.lightblue/util
/**
* Pretty print a json doc
*/
public static void prettyPrint(StringBuilder bld, JsonNode node) {
toString(bld, node, 0, true);
}
代码示例来源:origin: lightblue-platform/lightblue-core
/**
* Pretty print a json doc
*/
public static void prettyPrint(StringBuilder bld, JsonNode node) {
toString(bld, node, 0, true);
}
代码示例来源:origin: lightblue-platform/lightblue-core
private static boolean arrayToString(StringBuilder bld,
ArrayNode node,
int depth,
boolean newLine) {
if (newLine) {
indent(bld, depth);
newLine = false;
}
bld.append("[");
boolean first = true;
for (Iterator<JsonNode> itr = node.elements();
itr.hasNext();) {
if (first) {
first = false;
} else {
bld.append(',');
}
newLine = toString(bld, itr.next(), depth + 1, newLine);
}
if (newLine) {
indent(bld, depth);
}
bld.append(']');
return false;
}
代码示例来源:origin: com.redhat.lightblue/lightblue-core-util
private static boolean arrayToString(StringBuilder bld,
ArrayNode node,
int depth,
boolean newLine) {
if (newLine) {
indent(bld, depth);
newLine = false;
}
bld.append("[");
boolean first = true;
for (Iterator<JsonNode> itr = node.elements();
itr.hasNext();) {
if (first) {
first = false;
} else {
bld.append(',');
}
newLine = toString(bld, itr.next(), depth + 1, newLine);
}
if (newLine) {
indent(bld, depth);
}
bld.append(']');
return false;
}
代码示例来源:origin: com.redhat.lightblue/util
private static boolean arrayToString(StringBuilder bld,
ArrayNode node,
int depth,
boolean newLine) {
if (newLine) {
indent(bld, depth);
newLine = false;
}
bld.append("[");
boolean first = true;
for (Iterator<JsonNode> itr = node.elements();
itr.hasNext();) {
if (first) {
first = false;
} else {
bld.append(',');
}
newLine = toString(bld, itr.next(), depth + 1, newLine);
}
if (newLine) {
indent(bld, depth);
}
bld.append(']');
return false;
}
代码示例来源:origin: com.redhat.lightblue/util
bld.append('\"');
bld.append(':');
newLine = toString(bld, entry.getValue(), depth + 1, false);
if (newLine) {
indent(bld, depth);
代码示例来源:origin: com.redhat.lightblue/lightblue-core-util
bld.append('\"');
bld.append(':');
newLine = toString(bld, entry.getValue(), depth + 1, false);
if (newLine) {
indent(bld, depth);
代码示例来源:origin: lightblue-platform/lightblue-core
bld.append('\"');
bld.append(':');
newLine = toString(bld, entry.getValue(), depth + 1, false);
if (newLine) {
indent(bld, depth);
内容来源于网络,如有侵权,请联系作者删除!