Package idatt2106.group3.backend.Model
Class Message
- java.lang.Object
-
- idatt2106.group3.backend.Model.Message
-
@Entity public class Message extends java.lang.Object
Entity class for storing information about a message with messageId as primary key
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Chat
getChat()
java.lang.String
getMessage()
long
getMessageId()
java.time.LocalDateTime
getTimeSent()
User
getUser()
void
setChat(Chat chat)
void
setMessage(java.lang.String message)
void
setMessageId(long messageId)
void
setTimeSent(java.time.LocalDateTime timeSent)
void
setUser(User user)
java.lang.String
toString()
-
-
-
Constructor Detail
-
Message
public Message(java.lang.String message, java.time.LocalDateTime timeSent, Chat chat, User user)
-
Message
public Message(java.lang.String message, java.time.LocalDateTime timeSent)
-
Message
public Message(MessageDTO messageDTO, Chat chat, User user)
-
Message
public Message()
-
-
Method Detail
-
getUser
public User getUser()
-
setUser
public void setUser(User user)
-
getChat
public Chat getChat()
-
setChat
public void setChat(Chat chat)
-
getMessageId
public long getMessageId()
-
setMessageId
public void setMessageId(long messageId)
-
getMessage
public java.lang.String getMessage()
-
setMessage
public void setMessage(java.lang.String message)
-
getTimeSent
public java.time.LocalDateTime getTimeSent()
-
setTimeSent
public void setTimeSent(java.time.LocalDateTime timeSent)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-