本文整理了Java中com.jayway.jsonpath.Configuration.containsOption()
方法的一些代码示例,展示了Configuration.containsOption()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Configuration.containsOption()
方法的具体详情如下:
包路径:com.jayway.jsonpath.Configuration
类名称:Configuration
方法名:containsOption
[英]Check if this configuration contains the given option
[中]检查此配置是否包含给定选项
代码示例来源:origin: json-path/JsonPath
private <T> T resultByConfiguration(Object jsonObject, Configuration configuration, EvaluationContext evaluationContext) {
if(configuration.containsOption(AS_PATH_LIST)){
return (T)evaluationContext.getPathList();
} else {
return (T) jsonObject;
}
}
}
代码示例来源:origin: json-path/JsonPath
boolean optAsPathList = configuration.containsOption(AS_PATH_LIST);
boolean optAlwaysReturnList = configuration.containsOption(Option.ALWAYS_RETURN_LIST);
boolean optSuppressExceptions = configuration.containsOption(Option.SUPPRESS_EXCEPTIONS);
代码示例来源:origin: com.jayway.jsonpath/json-path
private <T> T resultByConfiguration(Object jsonObject, Configuration configuration, EvaluationContext evaluationContext) {
if(configuration.containsOption(AS_PATH_LIST)){
return (T)evaluationContext.getPathList();
} else {
return (T) jsonObject;
}
}
}
代码示例来源:origin: com.jayway.jsonpath/json-path
boolean optAsPathList = configuration.containsOption(AS_PATH_LIST);
boolean optAlwaysReturnList = configuration.containsOption(Option.ALWAYS_RETURN_LIST);
boolean optSuppressExceptions = configuration.containsOption(Option.SUPPRESS_EXCEPTIONS);
代码示例来源:origin: com.github.lafa.jsonpath/json-path
private <T> T resultByConfiguration(Object jsonObject, Configuration configuration, EvaluationContext evaluationContext) {
if(configuration.containsOption(AS_PATH_LIST)){
return (T)evaluationContext.getPathList();
} else {
return (T) jsonObject;
}
}
代码示例来源:origin: com.github.lafa.jsonpath/json-path
boolean optAsPathList = configuration.containsOption(AS_PATH_LIST);
boolean optAlwaysReturnList = configuration.containsOption(Option.ALWAYS_RETURN_LIST);
boolean optSuppressExceptions = configuration.containsOption(Option.SUPPRESS_EXCEPTIONS);
内容来源于网络,如有侵权,请联系作者删除!