1. Homepage
  2. Programming
  3. CS6300 Software Development Process - Individual Project: txter

CS6300 Software Development Process - Individual Project: txter

Engage in a Conversation
GaTechCS6300Software Development Processtxter

Individual Project: txter CourseNana.COM

Deliverable 4 CourseNana.COM

Project Goals CourseNana.COM

In this project, you will be developing a Java application, txter, using an agile, test-driven development process across multiple deliverables. For this assignment you will use version 19 of the Java Development Kit. You will receive one grade for the entire project, but each deliverable must be completed by its own due date and all deliverables will contribute to the overall project grade. CourseNana.COM

Specification CourseNana.COM

txter is a command-line utility written in Java with the following specification: CourseNana.COM

Summary
txter allows for simple text manipulation of the contents of a file.
Syntax CourseNana.COM

txter [OPTIONS] FILE

Description CourseNana.COM

The program txter performs basic text transformation on the lines of text from an input file. It is invoked as a command-line tool using the syntax described above, after compilation. The program writes the transformed text to the standard output and errors or usage messages to the standard error without modifying the input file. The FILE parameter is required and must be the last parameter as shown above. The options allowed in the program, which are optional, delimited by the left [ and right ] brackets, may be provided in any order and are described as follows: CourseNana.COM

Option CourseNana.COM

-e <string>
-k <string>

Description
Exclude Lines
: Exclude lines containing the given CourseNana.COM

substring. This option is mutually exclusive with -k. CourseNana.COM

Keep Lines: Keep only the lines containing the given substring. This option is mutually exclusive with -e. CourseNana.COM

Option CourseNana.COM

-i CourseNana.COM

-r <target> CourseNana.COM

-d <integer> CourseNana.COM

Order of execution CourseNana.COM

Description CourseNana.COM

Case Insensitive: Applies case insensitive matching when used with "Keep Lines" and "Exclude Lines". This option takes no parameters. CourseNana.COM

Reverse text: A valid target here is either “words” or “text”. Reverse words or text in each line according to the parameter “words” or “text”. The "words" string parameter will reverse the order of words in each line, but leave the characters of the words in the original order. The "text" string parameter will reverse the characters within each line. Spaces should be considered as a word or characters here. CourseNana.COM

Duplicate Lines: Duplicate each line to the file the number of times specified. 0 is minimum and 9 is maximum for <integer>. CourseNana.COM

The last command-line parameter provided is always treated as the filename, as shown in the syntax section, while OPTIONS flags can appear in any order and parsed as they appear from left to right. This means that the following two commands are equivalent when executed on the command line: CourseNana.COM

Example 1 txter -d 1 -k ..? input.txt Example 2 txter -k ..? -d 1 input.txt CourseNana.COM

In the above examples, (Example 1) parses -d first, then -k, and finally input.txt while (Example 2) parses -k first, then -d, and finally input.txt. These two will result in the same output (assuming that the same input.txt is used for both) because the parsing of options is independent of their execution order. The order of execution for each option is given in the diagram below (note that the colors and border lines are there for ease of viewing): CourseNana.COM

The above diagram of the execution order of options can also be described as follows: CourseNana.COM

  1. If -i is present, then -k or -e shall keep or exclude lines containing matched strings with case insensitive manner.If -i is not present, then -k or -e shall keep or exclude lines containing exact matched strings with case sensitive manner. CourseNana.COM

  2. If -r is present, then text in each line shall be reversed according to its parameter. CourseNana.COM

  3. If-dispresent,eachlineshallbeduplicatedby<integer>times. CourseNana.COM

Notes CourseNana.COM

  • ●  To keep this application simple, all errors shall result in the display of the standard usage message. This is shown in the syntax section above as well as in the files provided to you which are linked in later sections. CourseNana.COM

  • ●  If options are repeated, only their last occurrence is applied. The Examples section below shows a case of repeated options. CourseNana.COM

  • ●  An empty input file shall produce an empty output. The Examples section below shows a case of an empty input file. CourseNana.COM

  • ●  You shall assume that the command line parameter strings will not contain newline characters (\r, \n, \r\n) as the behavior of the program would be platform dependent and may result in error during grading. Therefore there should be no test cases using these values as option parameters. Additionally, you may assume that your application will be called with valid String[] args. CourseNana.COM

  • ●  Specifying option -e with an empty string as the string parameter shall exclude all lines, resulting in an empty output. CourseNana.COM

  • ●  Specifying option -k with an empty string as the string parameter shall keep all lines. CourseNana.COM

  • ●  IMPORTANT: You are expected to infer the expected program behavior using the gradescope provided information alone. Submitting an implementation that prints out the instructor-provided test inputs is unfair to your classmates and will result in a significant grade penalty. CourseNana.COM

    Program errors CourseNana.COM

  • ●  The last line of a non-empty input file must be terminated by a newline. If the non-empty input file does not terminate in a newline, the program shall generate an error. CourseNana.COM

  • ●  All parameters of program options are required and shall result in an error if omitted. This means that parsing an option that should include parameters but doesn't should result in an error. The Examples section below shows a case of missing option parameters. CourseNana.COM

  • ●  Specifying option parameters with the wrong type shall result in an error. CourseNana.COM

  • ●  Specifying option -i without -e or -k shall result in an error. CourseNana.COM

  • ●  Specifying option -i with parameters shall result in an error. CourseNana.COM

  • ●  Specifying options -e and -k simultaneously shall result in an error. CourseNana.COM

  • ●  Specifying option -r with a parameter outside of the allowed values ("words", 3 CourseNana.COM

"text") shall result in an error.
● Specifying option
-d with an integer outside of the inclusive range 0 to 9 as the CourseNana.COM

duplication parameter shall result in an error. CourseNana.COM

Examples of Usage CourseNana.COM

The examples described here can also be seen in JUnit 5 form on the MainTest.java file provided to you in D1. In the following, "" represents a newline character. CourseNana.COM

Example 1 CourseNana.COM

 txter -e test sample.txt
 input sample.txt
stdout
stderr

Example 2 CourseNana.COM

txter -i sample.txt
input sample.txt
stdout
stderr

Example 3 CourseNana.COM

txter -e Bird sample.txt
input sample.txt
stdout
stderr

Dog goes "woof".Cat goes "meow".Bird goes "tweet". CourseNana.COM

Dog goes "woof".Cat goes "meow". CourseNana.COM

nothing sent to stderr
nothing sent to stdout
nothing sent to stderr

Hello, world!↵ ↵
How are you? CourseNana.COM

nothing sent to stdout

Usage: txter [ -i | -k substring | -e substring | -r target | -d num ] FILE CourseNana.COM

Example 4 CourseNana.COM

txter -k Mouse sample.txt
input sample.txt
stdout
stderr

Example 5 CourseNana.COM

Dog goes "woof".Cat goes "meow".Bird goes "tweet". CourseNana.COM

nothing sent to stdout
nothing sent to stderr
txter -r words sample.txt
input sample.txt
stdout
stderr

Example 6 CourseNana.COM

Baby Shark , doo - doo, doo-doo, doo-doo doo-doo doo-doo, doo, - doo , Shark Baby CourseNana.COM

nothing sent to stderr

txter -r text sample.txt
!syas siht tahw wonk reven lliw uoY
CourseNana.COM

input sample.txt
stdout
stderr

...tiaw ho
You will never know what this says! CourseNana.COM

oh wait...
nothing sent to stderr CourseNana.COM

Example 7 CourseNana.COM

txter -d 8 -d 2 sample.txt
Baby Shark, doo-doo, doo-doo, doo-doo
CourseNana.COM

input sample.txt

stdout CourseNana.COM

stderr CourseNana.COM

Example 8 CourseNana.COM

Mommy Shark, doo-doo, doo-doo, doo-doo CourseNana.COM

Baby Shark, doo-doo, doo-doo, doo-dooBaby Shark, doo-doo, doo-doo, doo-dooBaby Shark, doo-doo, doo-doo, doo-dooMommy Shark, doo-doo, doo-doo, doo-dooMommy Shark, doo-doo, doo-doo, doo-dooMommy Shark, doo-doo, doo-doo, doo-doo CourseNana.COM

nothing sent to stderr
txter -r words -d 1 -k cat -i sample.txt
input sample.txt
stdout
stderr

Dog goes "woof".Cat goes "meow".Bird goes "tweet". CourseNana.COM

"meow". goes Cat"meow". goes Cat CourseNana.COM

nothing sent to stderr

Deliverables Summary CourseNana.COM

This part of the document is provided to help you track where you are in the individual project. This section will be updated in future deliverables. CourseNana.COM

Deliverable 1 Provided CourseNana.COM

txter specification (linked in this document above)
Skeleton of the main class for
txter (linked below)
JUnit 5 example tests and skeleton of test class to submit (
linked below) JUnit 5 library (linked below) CourseNana.COM

Expected CourseNana.COM

Part I (Category partition)
catpart.txt: TSL file you created
CourseNana.COM

catpart.txt.tsl: test specifications generated by the TSLgenerator tool when CourseNana.COM

run on your TSL file Part II (JUnit tests) CourseNana.COM

MyMainTest.java: JUnit tests derived from your category partition test frames CourseNana.COM


Deliverable 4 Provided CourseNana.COM

Code and interfaces to use as a starting point for this deliverable Instructor-provided test cases for class txter (through Gradescope) CourseNana.COM

Expected CourseNana.COM

Implementation of class txter that passes all instructor-provided test CourseNana.COM

Deliverable 4: Instructions CourseNana.COM

Your company has received positive feedback for the command-line version of the txter utility. They have therefore decided to provide its functionality through a library and an API, so that additional applications can be built on top of it. Part of your team has already created a Java interface for the API (TxterInterface), which you will be able to download, and a set of tests for it, which you will be able to run on your code through Gradescope. Your job is to develop a class, named Txter, that implements the provided interface and passes the provided tests. CourseNana.COM

To complete this deliverable, you will submit your code (i.e., class Txter and related files) and make sure that it passes all the instructor-provided tests (Gradescope will run them for you and report information about passing and failing tests). To do so, you will have to refactor your code so that it can be invoked using the provided interface. Because the code will be invoked programmatically, rather than from the command line, the use of incorrect parameters should result in an exception, and no error messages should be generated on the console. CourseNana.COM

Grade CourseNana.COM

Your grade for this deliverable will be proportional to the percentage of instructor test cases that pass on your code. For example, if your implementation passes 85 of the 100 provided test cases, your grade for this deliverable will be 85 (this is an example, the actual number of tests may differ). CourseNana.COM

Detailed Steps CourseNana.COM

1. Downloadarchiveindividualproject-d4.tar.gz
2. Unpackthearchiveinthedirectory"IndividualProject"thatyoucreatedin CourseNana.COM

Deliverable 1. Hereafter, we will refer to this directory as <dir>. 3. Afterunpacking,youshouldseethefollowingfiles: CourseNana.COM

  1. <dir>/txter/src/edu/gatech/seclass/txter/
    TxterInterface.java
    This is the interface that you have to implement in the class Txter. Make sure to read the description of the methods and their parameters in the comments before each method, including the details about exceptions that the methods may throw. Given that the core functionality did not change, the methods should be self-explanatory. CourseNana.COM

  2. <dir>/txter/src/edu/gatech/seclass/txter/
    TxterException.java
    The exception to be thrown by your Txter class in case of errors, with a suitable message. The error message does not have any rules, so it can be the usage string or more specific details of why the exception was thrown. They are similar to those used for the command-line version of the utility, with some additional messages and small changes. CourseNana.COM

c. <dir>/txter/test/edu/gatech/seclass/txter/
MyLibTest.java
This is a test class with a single test case for the Txter class, to give you an idea of how a test would look in this context. CourseNana.COM

Get in Touch with Our Experts

WeChat WeChat
Whatsapp WhatsApp
GaTech代写,CS6300代写,Software Development Process代写,txter代写,GaTech代编,CS6300代编,Software Development Process代编,txter代编,GaTech代考,CS6300代考,Software Development Process代考,txter代考,GaTechhelp,CS6300help,Software Development Processhelp,txterhelp,GaTech作业代写,CS6300作业代写,Software Development Process作业代写,txter作业代写,GaTech编程代写,CS6300编程代写,Software Development Process编程代写,txter编程代写,GaTechprogramming help,CS6300programming help,Software Development Processprogramming help,txterprogramming help,GaTechassignment help,CS6300assignment help,Software Development Processassignment help,txterassignment help,GaTechsolution,CS6300solution,Software Development Processsolution,txtersolution,