Create a testing java program

Assignment Help JAVA Programming
Reference no: EM13766727

One of the key features of Java OOP is to use external class files without knowing much of the implementations. The attached RandomSeq.class file contains the implementation of a RandomSeq class which contain two methods:

String RandomSeq.getRandomSeq(long arg0) -will return a String of randomly generated DNA sequence of any length passed in as a parameter, and void RandomSeq.formatSeq(int arg0) - will print out a formatted DNA sequence with specified length for each line as shown below

1 GACTTGCCAGTTTAATAATGTCACATAATCAGATACGTAGATTCGCTTAT

51 ATGCCCGGCCCACTGACGGAGGGGCCCGGGGGTCCAGCCCATGGGGCAGA

101 GGGACACTCTGAACGCTCGCGCAGGTACGTGTGGTAAACCGATATCGCGC

151 TTCTACTGACTCTCCCACTCAACGAAGACAAGACTTTGGCCACTCACCCG

201 GCATTACTATAGCTCGGTGCAGGGAGTCCTCAGCCCCGCGATGGATATTA

251 GGCTGGCCCCTAACCTGCGAGGACATTCAAAGTAGGTTTTGACCGGCATT

301 GCAAGGTCACTGAGGAGAATTTATGATAGCCGCCCATACC

The RandomSeq class also has two properties (id and seq) which has the set/get methods of setSeqID(String arg0), setSeq(String arg0), and getSeqID(), getSeq().

Please note, when a DNA sequence String was generated using the getRandomSeq() method, the sequence need to be assigned to the object using the setSeq(String arg0) method. After that, the formatSeq() method can be used to print out the formatted sequence.

Please create a testing Java program to use this RandomSeq class to create a random DNA sequence and then print it out in a formatted fashion with a specified length for each line.

Note: if you use NotePad to create your project, you can simply copy the RandomSeq.class attached file into the same folder of your testing Java program. If you use Eclipse or NetBeans, you probably need to create an external class folder for your project and then import the RandomSeq.class file into the class folder.

Here is how to add the RandomSeq.class file to your project in NetBeans and Eclipse: (assume the RandomSeq.class file is saved into C:\BIFS618)

NetBeans: Create the project first, and then right click on the Libraries from the Projects window, and select Add JAR/Folder to open the window. Browse to the folder contains the .class file (c:\BIFS618), click open. Now the folder is added to the Libraries, and you can create a RandomSeq object directly in your project.

Eclipse: Create the project first, and then right click on the project to select properties. In the properties window, select Libraries tab, and click on Add External Class Folder to select the folder contains the RandomSeq class file and click OK. Now you can use the RandomSeq class directly in your project.

Verified Expert

The solution file is implemented in netbeans and Random Seq class has two methods are String RandomSeq.getRandomSeq(long arg0) which return a String of randomly generated DNA sequence of any length passed in as a parameter, and void RandomSeq.formatSeq(int arg0) will print out a formatted DNA sequence with specified length. The RandomSeq class also has two properties (id and seq) which has the set/get methods of setSeqID(String arg0), setSeq(String arg0), and getSeqID(), getSeq(). We created test Java program to use this RandomSeq class to create a random DNA sequence and then print it out in a formatted fashion with a specified length for each line. The screen shot of this program is attached with solution.

Reference no: EM13766727

Questions Cloud

Analytics-management science or model challenge in the real : The last section of the report should discuss the future opportunities and challenges of solving the problem. What will help solutions improve? What limitations remain?
Do the legal principles apply to vehicles : Do the legal principles apply to vehicles such as bicycles, rowboat, motor homes, trains or airplanes
Compare similarities between maisel jay and sherman cindy : Compare and Contrast, noting the similarities and differences, between 3 photographer Maisel, Jay, Sherman, Cindy and Uelsmann, Jerry.
How a juvenile corrections officer can be verbal : Write a 1,750- word paper describing how a Juvenile corrections officer can be verbal and nonverbal communication can affect communication in the following areas: Public announcement to the press
Create a testing java program : Please create a testing Java program to use this RandomSeq class to create a random DNA sequence and then print it out in a formatted fashion with a specified length for each line.
Future applications of biotechnology : Evaluate current or future applications of biotechnology in the fields of medicine or agriculture.
Identify what the cause of the communication error : Identify what the cause of the communication error may have been. What could be a possible solution to the problem?
Thoroughness-professionalism-substance and persuasiveness : Your answer to this question will be evaluated based on the thoroughness, professionalism, substance, and persuasiveness of your argument.
Do you agree or disagree with the authors conclusion : Locate and review a professional, peer reviewed journal article(s) or case study(s) (minimum article length 7 pages) relating to a business law topic. Do you agree or disagree with the author's conclusion and why or why not

Reviews

inf766727

8/22/2019 2:50:56 AM

Nice work delivered to me I have asked the work to be delivered to me quickly. Programming is clearly done and I am happy that I have explained it in the class. I got full grads in the assignment. Thanks to the team.

inf766727

8/22/2019 2:46:15 AM

I need the programming to be 100% correct because the professor will check it in the class and asked us to present it in the class. Put all the code in sequence and provide me correct code file.

Write a Review

JAVA Programming Questions & Answers

  Implement a class quiz

Implement a class Quiz that implements the Measurable interface.

  Writing a program that parses

The programming project involves writing a program that parses, using recursive descent, a GUI definition language defined in an input file and generates the GUI that it defines.

  Uses a loop to populate a one-dimensional array

Write the following program that creates and uses a loop to populate a one-dimensional array that holds the even numbers between 1 and 12; creates and uses a loop to populate a second one-dimensional array that holds the odd numbers between 1 and 12;..

  Write a void method that takes as a parameter

Write a Point class. A Point should have the subsequent - Write a void method that takes as a parameter an array of Lines and prints out the location of each intersection. The intersection of any two lines should only be printed once

  Implement a client program

Implement a client program with a main method to demonstrate the evolution of the sales tax rates in the 50 US states over the last 10 years. Declare a two-dimensional array of values representing the sales tax rates. Dimension 1 represents the st..

  Write a program that reads in a text file and then computes

Write a program that reads in a text file and then computes and prints a table of letter frequencies. For example, if the file is the text of "A Tale of Two Cities", found in the file at data/tales.txt , the program will print

  We developed a stringlog adt it represents a log that holds

we developed a stringlog adt. it represents a log that holds objects of class string. suppose that instead of

  Function that finds the smallest item in an arraybag

Write me a function that finds the smallest item in an ArrayBag (by reference) and returns true if the arrayBag is not empty and false otherwise.

  What secret does soraya tell amir

What secret does soraya tell amir and how does amir react to this information

  Write a program that reads in a list of numbers from a file

write a program that reads in a list of numbers from a file and adds up all those numbers. You may hard code in the name of the file, allowing the user to input the filename is not required

  Create a class called numberset

You need to create a class called NumberSet.  It needs an empty default constructor and an overloaded constructor that takes an integer argument and creates a vector with that many random numbers in it.  So... if I created

  Write down a java program which prints out all 92 solutions

write a java program which prints out all 92 solutions of the 8-queen problem but modify the program to display only

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd