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


Java JsonStreamContext类代码示例

本文整理汇总了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();
}
 
开发者ID:xushjie1987,项目名称:es-hadoop-v2.2.0,代码行数:19,代码来源:JacksonJsonParser.java

示例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();
        }
    }
}
 
开发者ID:xushjie1987,项目名称:es-hadoop-v2.2.0,代码行数:19,代码来源:BackportedJacksonMappingIterator.java

示例3: getOutputContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getOutputContext()
{
  return this.delegate.getOutputContext();
}
 
开发者ID:zhangjianying,项目名称:12306-android-Decompile,代码行数:5,代码来源:JsonGeneratorDelegate.java

示例4: getParsingContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
  return this._parsingContext;
}
 
开发者ID:zhangjianying,项目名称:12306-android-Decompile,代码行数:5,代码来源:TokenBuffer.java

示例5: getParsingContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
  return this.delegate.getParsingContext();
}
 
开发者ID:zhangjianying,项目名称:12306-android-Decompile,代码行数:5,代码来源:JsonParserDelegate.java

示例6: getParsingContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public JsonStreamContext getParsingContext()
{
  return this._nodeCursor;
}
 
开发者ID:zhangjianying,项目名称:12306-android-Decompile,代码行数:5,代码来源:TreeTraversingParser.java

示例7: getOutputContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@Override
public JsonStreamContext getOutputContext() {
    return delegate.getOutputContext();
}
 
开发者ID:r00li,项目名称:RHome,代码行数:5,代码来源:JsonGeneratorDelegate.java

示例8: getParsingContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
public abstract JsonStreamContext getParsingContext(); 
开发者ID:zhangjianying,项目名称:12306-android-Decompile,代码行数:2,代码来源:JsonParserMinimalBase.java

示例9: getParsingContext

import org.codehaus.jackson.JsonStreamContext; //导入依赖的package包/类
@Override public JsonStreamContext getParsingContext() {throw new UnsupportedOperationException("Not required for tests.");} 
开发者ID:lotaris,项目名称:jee-rest,代码行数:2,代码来源:JsonRootWrapperDeserializerUnitTest.java


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