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


Java JsonNode.isArrayNode方法代码示例

本文整理汇总了Java中argo.jdom.JsonNode.isArrayNode方法的典型用法代码示例。如果您正苦于以下问题:Java JsonNode.isArrayNode方法的具体用法?Java JsonNode.isArrayNode怎么用?Java JsonNode.isArrayNode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在argo.jdom.JsonNode的用法示例。


在下文中一共展示了JsonNode.isArrayNode方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: parseCompilerSpecificArgs

import argo.jdom.JsonNode; //导入方法依赖的package包/类
@Override
public boolean parseCompilerSpecificArgs(JsonNode node) {
	if (!node.isArrayNode("classpath")) {
		return false;
	}

	List<String> paths = new ArrayList<>();
	JSONUtility.addAllJson(node.getArrayNode("classpath"), new Function<JsonNode, String>(){
		@Override
		public String apply(JsonNode d) {
			return d.getStringValue().toString();
		}
	}, paths);
	// Override current class paths
	classPaths = paths.toArray(classPaths);
	try {
		applyClassPath();
	} catch (MalformedURLException | NoSuchMethodException | SecurityException |
			IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
		getLogger().log(Level.WARNING, "Unable to apply class path.", e);
		return false;
	}

	return true;
}
 
开发者ID:repeats,项目名称:Repeat,代码行数:26,代码来源:JavaNativeCompiler.java

示例2: func_98163_a

import argo.jdom.JsonNode; //导入方法依赖的package包/类
public static McoServer func_98163_a(JsonNode p_98163_0_) {
   McoServer var1 = new McoServer();

   try {
      var1.field_96408_a = Long.parseLong(p_98163_0_.getNumberValue(new Object[]{"id"}));
      var1.field_96406_b = p_98163_0_.getStringValue(new Object[]{"name"});
      var1.field_96407_c = p_98163_0_.getStringValue(new Object[]{"motd"});
      var1.field_96404_d = p_98163_0_.getStringValue(new Object[]{"state"});
      var1.field_96405_e = p_98163_0_.getStringValue(new Object[]{"owner"});
      if(p_98163_0_.isArrayNode(new Object[]{"invited"})) {
         var1.field_96402_f = func_98164_a(p_98163_0_.getArrayNode(new Object[]{"invited"}));
      } else {
         var1.field_96402_f = new ArrayList();
      }

      var1.field_104063_i = Integer.parseInt(p_98163_0_.getNumberValue(new Object[]{"daysLeft"}));
      var1.field_96403_g = p_98163_0_.getStringValue(new Object[]{"ip"});
      var1.field_98166_h = p_98163_0_.getBooleanValue(new Object[]{"expired"}).booleanValue();
      var1.field_110729_i = Integer.parseInt(p_98163_0_.getNumberValue(new Object[]{"difficulty"}));
      var1.field_110728_j = Integer.parseInt(p_98163_0_.getNumberValue(new Object[]{"gameMode"}));
   } catch (IllegalArgumentException var3) {
      ;
   }

   return var1;
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:27,代码来源:McoServer.java

示例3: verifyMessageContent

import argo.jdom.JsonNode; //导入方法依赖的package包/类
@Override
protected boolean verifyMessageContent(JsonNode content) {
	return content.isStringValue("device") &&
			content.isStringValue("action") &&
			content.isArrayNode("parameters") &&
			content.getStringValue("device").equals(DEVICE_NAME);
}
 
开发者ID:repeats,项目名称:Repeat,代码行数:8,代码来源:SharedMemoryProcessor.java

示例4: verifyMessageContent

import argo.jdom.JsonNode; //导入方法依赖的package包/类
@Override
protected boolean verifyMessageContent(JsonNode content) {
	return content.isStringValue("device") &&
			content.getStringValue("device").startsWith("system") &&
			content.isStringValue("action") &&
			content.isArrayNode("parameters");
}
 
开发者ID:repeats,项目名称:Repeat,代码行数:8,代码来源:SystemRequestProcessor.java

示例5: verifyMessageContent

import argo.jdom.JsonNode; //导入方法依赖的package包/类
@Override
protected boolean verifyMessageContent(JsonNode content) {
	return content.isStringValue("device") &&
			(content.getStringValue("device").equals("mouse") ||
				content.getStringValue("device").equals("keyboard")) &&
			content.isStringValue("action") &&
			content.isArrayNode("parameters");
}
 
开发者ID:repeats,项目名称:Repeat,代码行数:9,代码来源:ControllerRequestProcessor.java

示例6: func_98163_a

import argo.jdom.JsonNode; //导入方法依赖的package包/类
public static McoServer func_98163_a(JsonNode par0JsonNode)
{
    McoServer mcoserver = new McoServer();

    try
    {
        mcoserver.field_96408_a = Long.parseLong(par0JsonNode.getNumberValue(new Object[] {"id"}));
        mcoserver.field_96406_b = par0JsonNode.getStringValue(new Object[] {"name"});
        mcoserver.field_96407_c = par0JsonNode.getStringValue(new Object[] {"motd"});
        mcoserver.field_96404_d = par0JsonNode.getStringValue(new Object[] {"state"});
        mcoserver.field_96405_e = par0JsonNode.getStringValue(new Object[] {"owner"});

        if (par0JsonNode.isArrayNode(new Object[] {"invited"}))
        {
            mcoserver.field_96402_f = func_98164_a(par0JsonNode.getArrayNode(new Object[] {"invited"}));
        }
        else
        {
            mcoserver.field_96402_f = new ArrayList();
        }

        mcoserver.field_104063_i = Integer.parseInt(par0JsonNode.getNumberValue(new Object[] {"daysLeft"}));
        mcoserver.field_96403_g = par0JsonNode.getStringValue(new Object[] {"ip"});
        mcoserver.field_98166_h = par0JsonNode.getBooleanValue(new Object[] {"expired"}).booleanValue();
        mcoserver.field_110729_i = Integer.parseInt(par0JsonNode.getNumberValue(new Object[] {"difficulty"}));
        mcoserver.field_110728_j = Integer.parseInt(par0JsonNode.getNumberValue(new Object[] {"gameMode"}));
    }
    catch (IllegalArgumentException illegalargumentexception)
    {
        ;
    }

    return mcoserver;
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:35,代码来源:McoServer.java

示例7: verifyMessageContent

import argo.jdom.JsonNode; //导入方法依赖的package包/类
@Override
protected boolean verifyMessageContent(JsonNode content) {
	return content.isStringValue("task_action") &&
			content.isArrayNode("parameters");
}
 
开发者ID:repeats,项目名称:Repeat,代码行数:6,代码来源:TaskProcessor.java


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