💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
# 组件源码 ``` /** * <b>方法描述:</b> 字符串非空 <br/> * <b>创建者:</b> admin <br/> * <b>创建时间:</b> 2018-04-13 10:43:32 <br/> * * @param list * 入参|字符列表|{@link com.ylink.ide.trade.runtime.context.JavaList} * @param isNull * 出参|是否非空|{@link boolean} * @return 0 失败<br/> * 1 成功<br/> */ @Component(label = "字符串非空", style = "判断型", type = "同步组件", comment = "字符串非空检查,列表中中全部不为空,反回true,如果存在一个为空,反回false;其中null、空格、空串都视为空", version = "1.0.0", deprecated = false, author = "admin", date = "2018-04-13 10:43:32") @InParams(param = { @Param(name = "list", comment = "字符列表", type = com.ylink.ide.trade.runtime.context.JavaList.class) }) @OutParams(param = { @Param(name = "isNull", comment = "是否非空", type = boolean.class) }) @Returns(returns = { @Return(id = "0", desp = "失败"), @Return(id = "1", desp = "成功") }) public static ResultBase P_hasEmpty(JavaList list) { if (list == null || list.isEmpty()) { return ResultBase.newFailureResult("TPTS1016", "集合为空"); } for (int i = 0; i < list.size(); i++) { String s = (String) list.get(i); if (StringUtil.isBlank(s)) return ResultBase.newFailureResult("TPTS1017", "第" + i + "个字符串为空"); } return ResultBase.newSuccessResult(true); } ``` # 交易中组件使用方式 ![](https://img.kancloud.cn/b7/b2/b7b20b2ed07517dfc7612950e4f3c8d8_1868x890.png) # 参数说明及示例 ## 入口参数 字符列表:字符串列表,示例: `["dssad","","123"]` ## 出口参数 是否非空:判断字符串列表中是否存在空值(null、空格、空串),示例: `__INNER__["result"]`