本文整理汇总了Java中org.codehaus.jackson.JsonStreamContext类的典型用法代码示例。如果您正苦于以下问题:Java JsonStreamContext类的具体用法?Java JsonStreamContext怎么用?Java JsonStreamContext使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
JsonStreamContext类属于org.codehaus.jackson包,在下文中一共展示了JsonStreamContext类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: absoluteName
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@Override
public String absoluteName() {
List<String> tree = new ArrayList<String>();
for (JsonStreamContext ctx = parser.getParsingContext(); ctx != null; ctx = ctx.getParent()) {
if (ctx.inObject()) {
tree.add(ctx.getCurrentName());
}
}
StringBuilder sb = new StringBuilder();
for (int index = tree.size(); index > 0; index--) {
sb.append(tree.get(index - 1));
sb.append(".");
}
// remove the last .
sb.setLength(sb.length() - 1);
return sb.toString();
}
示例2: BackportedJacksonMappingIterator
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@SuppressWarnings("unchecked")
protected BackportedJacksonMappingIterator(JavaType type, JsonParser jp, DeserializationContext ctxt, JsonDeserializer<?> deser) {
_type = type;
_parser = jp;
_context = ctxt;
_deserializer = (JsonDeserializer<T>) deser;
/* One more thing: if we are at START_ARRAY (but NOT root-level
* one!), advance to next token (to allow matching END_ARRAY)
*/
if (jp != null && jp.getCurrentToken() == JsonToken.START_ARRAY) {
JsonStreamContext sc = jp.getParsingContext();
// safest way to skip current token is to clear it (so we'll advance soon)
if (!sc.inRoot()) {
jp.clearCurrentToken();
}
}
}
示例3: getOutputContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getOutputContext()
{
return this.delegate.getOutputContext();
}
示例4: getParsingContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
return this._parsingContext;
}
示例5: getParsingContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
return this.delegate.getParsingContext();
}
示例6: getParsingContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
return this._nodeCursor;
}
示例7: getOutputContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@Override
public JsonStreamContext getOutputContext() {
return delegate.getOutputContext();
}
示例8: getParsingContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public abstract JsonStreamContext getParsingContext();
示例9: getParsingContext
import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@Override public JsonStreamContext getParsingContext() {throw new UnsupportedOperationException("Not required for tests.");}