From ee4d94defe7cc7f36f87aebf2e9efed38ba93a40 Mon Sep 17 00:00:00 2001 From: 懒羊羊 <15939171744@163.com> Date: 星期二, 14 十一月 2023 16:44:18 +0800 Subject: [PATCH] 优化 --- guns-vip-main/src/main/java/cn/stylefeng/guns/opcua/cert/MethodName.java | 33 ++++++++++++++++++++++++++------- 1 files changed, 26 insertions(+), 7 deletions(-) diff --git a/guns-vip-main/src/main/java/cn/stylefeng/guns/opcua/cert/MethodName.java b/guns-vip-main/src/main/java/cn/stylefeng/guns/opcua/cert/MethodName.java index 7320044..2c5d0ff 100644 --- a/guns-vip-main/src/main/java/cn/stylefeng/guns/opcua/cert/MethodName.java +++ b/guns-vip-main/src/main/java/cn/stylefeng/guns/opcua/cert/MethodName.java @@ -1,16 +1,35 @@ package cn.stylefeng.guns.opcua.cert; +import cn.stylefeng.guns.opcua.client.ClientHandler; +import cn.stylefeng.guns.opcua.entity.NodeEntity; import lombok.extern.slf4j.Slf4j; @Slf4j -public class MethodName { - public void a(String name){ - log.info("str={},鍝嶅簲鏂规硶:{}", name,"A"); +public class MethodName {/* + public void a(String Nodee){ + log.info("str={},鍝嶅簲鏂规硶:{}", Nodee,Nodee); } - public void b(String name){ - log.info("str={},鍝嶅簲鏂规硶:{}", name,"B"); + public void c(String Nodee){ + try { + NodeEntity node = NodeEntity.builder().index(2).identifier("my.device.x2") + .value("99").type("int").build(); + ClientHandler clientHandler=new ClientHandler(); + String out=clientHandler.write(node); + log.info(out); + } catch (Exception e) { + e.printStackTrace(); + } } - public void c(String name){ - log.info("str={},鍝嶅簲鏂规硶:{}", name,"C"); + public void b(String Nodee){ + log.info("str={},鍝嶅簲鏂规硶:{}", Nodee,Nodee); + }*/ + public void a(String param1, String param2) { + log.info("str={},鍝嶅簲鏂规硶:{}", param1,param2); + } + public void b(String param1, String param2) { + log.info("str={},鍝嶅簲鏂规硶:{}", param1,param2); + } + public void c(String param1, String param2) { + log.info("str={},鍝嶅簲鏂规硶:{}", param1,param2); } } -- Gitblit v1.9.3