From ea42bcc63b493a1f21bb25a7a8dfa03667b46ecd Mon Sep 17 00:00:00 2001 From: delvh Date: Sat, 19 Oct 2019 10:14:46 +0200 Subject: [PATCH] Formatted Chat file Formatted Getters and Setters --- src/main/java/envoy/client/Chat.java | 36 +++++++--------------------- 1 file changed, 9 insertions(+), 27 deletions(-) diff --git a/src/main/java/envoy/client/Chat.java b/src/main/java/envoy/client/Chat.java index 2d8c519..a38c3bb 100644 --- a/src/main/java/envoy/client/Chat.java +++ b/src/main/java/envoy/client/Chat.java @@ -18,41 +18,23 @@ public class Chat { messageList = new ArrayList(); } - public void setUserID(long givenUserID) { - chatPartnerID = givenUserID; - } + public void setUserID(long givenUserID) { chatPartnerID = givenUserID;} - public long getUserID() { - return chatPartnerID; - } + public long getUserID() { return chatPartnerID;} - public int getSize() { - return chatModel.getSize(); - } + public int getSize() { return chatModel.getSize();} - public void addMessage(String message) { - chatModel.addElement(message); - } + public void addMessage(String message) { chatModel.addElement(message);} - public String getMessageAt(int index) { - return (String) chatModel.getElementAt(index); - } + public String getMessageAt(int index) { return (String) chatModel.getElementAt(index);} @SuppressWarnings("unchecked") - public DefaultListModel getModel() { - return chatModel; - } + public DefaultListModel getModel() { return chatModel;} - public int getListSize() { - return messageList.size(); - } + public int getListSize() { return messageList.size();} - public void addMessageElement(Message message) { - messageList.add(message); - } + public void addMessageElement(Message message) { messageList.add(message);} - public Message getMessageElement(int index) { - return messageList.get(index); - } + public Message getMessageElement(int index) { return messageList.get(index);} }