Question: Please help me do this assignment! Thank you! Part 2 The questions in this part of the assignment will be graded. Question 1: Twitter (100

Please help me do this assignment! Thank you!

Please help me do this assignment! Thank you! Part 2 The questionsin this part of the assignment will be graded. Question 1: Twitter(100 points) For this question, you will write two classes to createa new data type that will model information extracted from twitter. Your

Part 2 The questions in this part of the assignment will be graded. Question 1: Twitter (100 points) For this question, you will write two classes to create a new data type that will model information extracted from twitter. Your code for this question will go in two .java files We strongly recommend that you complete all the warm-up questions before starting this problem. Note that in addition to the required methods below, you are free to add as many other private methods as you want (a) Tweet Class Tweet.java stores information and behaviours about a tweet. A tweet is a message sent using the social network Twitter. For this assignment, the tweets are defined as messages from 1 to 15 words (after ommiting stop words). The Tweet class stores information about a tweet: the user who tweeted it, the date of the tweet, the time of the tweet, and the actual tweet message The Tweet class should contain the following private attributes A String userAccount; This attribute stores the user id A String date; A String time; A String message; This attribute stores the date on which the tweet was tweeted This attribute stores the time on which the tweet was tweeted This attribute stores the tweeted message The Tweet class should also contain a private static attribute An HashSet stopwords This attribute stores the set of stop-words. A stop word is a commonly used word that is ignored by search engines2 Regarding the behaviour of the class, Tweet must implement the following methods A constructor that takes as inputs four Strings. The Strings correspond to: i) the user account ii) the date on which the tweet was posted. The format of the date is YYYY-MM-DI iii) the time on which the tweet was posted. The format of time is HH:MM:SS and iv) the message of the tweet. Please notice that your arguments must respect the previous order. The constructor does not have to check the format of the inputs A private static checkMessage method which takes as input a String indicating the tweet message. This method will check if the String received as a parameter represents a valid message or not. This method must return true if the length of the message is less than or equal to 15 words and greater than or equal to 1 word (excluding the stopWords). If the HashSet stopWords is equal to null, checkMessage must thrown a NullPointerException indicating that the HashSet has not been initialized Here a couple of hints

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!