From c7af99a876d1bb4ab8694ea65d883909482cf780 Mon Sep 17 00:00:00 2001 From: Benjamin Date: Sat, 26 Feb 2022 13:27:00 +0100 Subject: [PATCH] =?UTF-8?q?Cr=C3=A9ation=20r=C3=A8gle=20de=20lecture=20Hel?= =?UTF-8?q?loRule.java?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../protocol/rules/HelloRule.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 app/src/main/java/lightcontainer/protocol/rules/HelloRule.java diff --git a/app/src/main/java/lightcontainer/protocol/rules/HelloRule.java b/app/src/main/java/lightcontainer/protocol/rules/HelloRule.java new file mode 100644 index 0000000..6edb27d --- /dev/null +++ b/app/src/main/java/lightcontainer/protocol/rules/HelloRule.java @@ -0,0 +1,18 @@ +package lightcontainer.protocol.rules; + +import lightcontainer.protocol.ProtocolReader; + +public class HelloRule extends ProtocolReader { + private static final String PATTERN = "^HELLO ([A-Za-z0-9]{5,20}) ([0-9]{1,5})\r\n$"; + + public HelloRule() { + super(PATTERN); + } + + + @Override + protected void onExecuted(String[] data) { + + } + +}