Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can you please help me to solve this java program - Write a custom exception, throw it and handle it Create an Eclipse Project called

can you please help me to solve this java program

image text in transcribed

- Write a custom exception, throw it and handle it Create an Eclipse Project called JavaProgram. Write a class called MyMobileNetworkChecker that will attempt to verify the network of your mobile phone and throw an exception using exception handling if the make entered does not match. Create a custom exception class called NotMyNetworkException. Write a static method within the MyMobileNetworkChecker class called checkMyMobileNetwork(String inputNetwork) that declares (throws) the custom NotMyNetworkException exception. Implement the checkMyMobileNetwork method so that it matches the string entered with your network name (e.g. Vodafone, Three etc.), if it succeeds output a message to verify the network passed is correct, if the string passed is checked and it is NOT the same as your make of phone throw a NotMyNetworkException using the keyword throw. Test the calling of the checkMyMobileNetwork method in the main (test the passing of the incorrect phone make to the method so that the exception is thrown). Fully Javadoc the project including the method. Jar the project and test the running of the project from the jarfile. Required activities and marking guideline: - Implement the custom exception (extends Exception) - Implement the check make method with throws keyword - Handle the custom exception in the main - Test the custom exception is thrown\caught - Javadoc the class (especially the method) - Jar the project and run the Jarfile

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2015 Porto Portugal September 7 11 2015 Proceedings Part 3 Lnai 9286

Authors: Albert Bifet ,Michael May ,Bianca Zadrozny ,Ricard Gavalda ,Dino Pedreschi ,Francesco Bonchi ,Jaime Cardoso ,Myra Spiliopoulou

1st Edition

ISBN: 3319234609, 978-3319234601

More Books

Students also viewed these Databases questions