Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

For this assignment, you are to design and implement a Java class named Enigma that simulates this three-ring model of an Enigma machine. You may

For this assignment, you are to design and implement a Java class named Enigma that simulates this three-ring model of an Enigma machine. You may assume that all Enigma models have the same outer rotor, as shown in the above diagram. That is, the outer rotor consists of the 26 capital letters and the '#' symbol (representing a space) in the following clockwise order: #BDFHJLNPRTVXZACEGIKMOQSUWY. Since the middle and inner rotors are interchangeable, their contents and alignment relative to the outer rotor must be specified when constructing an Enigma model. For example, the initial settings of the inner and middle rotors in the above diagram are #GNUAHOVBIPWCJQXDKRYELSZFMT and #EJOTYCHMRWAFKPUZDINSXBGLQV, respectively. Using an Enigma object, it should be possible to both encode and decode text messages, with the appropriate rotation of the rotors occurring after each character encoding/decoding.

You should also design and implement a client program. For users who do not want to specify their own rotor settings, have a default option that uses the setting shown in the diagram. In addition, create an option that makes it simple for the user to specify the rotor settings on an Enigma model, and encode or decode text.

SPECIFIC TASKS

Using the outlines provided as a starting point:

Complete all method stubs in the Enigma class (Enigma.java). You are welcome to add additional methods as needed to facilitate procedural decomposition Implement a user-friendly client program (EnigmaClient.java) Provide user instructions fully explaining how to use your program for making your program user-friendly Fully demonstrate the proper functioning of your program by providing samples input/output

Design and implementation guidelines:

Javadoc comment all class files and methods Handle exceptions as appropriate and include @throws documentation in Javadoc comments Structured code - use methods to eliminate redundancy and break large methods into smaller, logical sub problems

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

Database Application Development And Design

Authors: Michael V. Mannino

1st Edition

0072463678, 978-0072463675

More Books

Students also viewed these Databases questions