Placeholder

PRG 421 Week 3 Individual Assignment Iterator Program

$5.00

Description

Write a Java program (non-GUI preferred) to demonstrate the use of Iterator.
The program should allow a user to do the following:
Allow the reading of a collection of animal objects from an external file.
Output on screen the content of a collection of animal objects.
Use Iterator to achieve these goals.
Include a brief documentation (in the code or in a separate document) to explain the input (if any), processing and output of the program.
Submit your assignment using the Assignment Files tab above.
SCREENSHOTS
SOLUTION
PAYMENT
ENTIRE COURSE
The solution includes a zip file.
Attachments [Move over files to preview content of those files]
PRG421_Week_3_Individual_Assignment.zip (131.61 KB)
java code
Animal.java
PRG421Week3.java
Netbeans project
PRG421_Week_3_Iterator
animals.txt
build
classes
.netbeans_automatic_build
.netbeans_update_resources
Animal.class
PRG421Week3.class
build.xml
manifest.mf
nbproject
build-impl.xml
genfiles.properties
private
private.properties
project.properties
project.xml
src
Animal.java
PRG421Week3.java
test
PRG421-Week-3-Individual-Assignment-Screenshot-1.png
PRG421-Week-3-Individual-Assignment-Screenshot.jpg
Preview Animal.java
}
xxxxxx xxxxxx(xxxxxx _xxxx, xxxxxx _xxxxx, xxxxxxx _xxxxxxx) {
xxxxxxx(_xxxx);
xxxxxxxx(_xxxxx);
setCanSwim(_canSwim); }
public String getType() { return type; }
public String getColor() { return color; }
public void setType(String _type) {
xxxx.xxxx = _xxxx;
}
xxxxxx xxxx xxxxxxxx(xxxxxx _xxxxx) {
xxxx.xxxxx = _xxxxx;
}
Preview PRG421Week3.java
xxxxxxx xxxxxx xxxx xxxxxxxxx(xxxxxx x) {
xxxxxxx.xxx(x);
}
private static void editAnimal(Animal a, String type, String color, boolean canSwim) { a.setType(type); a.setColor(color); a.setCanSwim(canSwim); }
private static void deleteAnimal(Animal a) { int index = 0; for (Animal an: animals) { if (an.getCanSwim() == a.getCanSwim() && an.getColor().equals(a.getColor()) && an.getType().equals(a.getType())) { break; } else
xxxxx++;
}
xx (xxxxx < xxxxxxx.xxxx()) xxxxxxx.xxxxxx(xxxxx); } Preview animals.txt Dog,red,true Cat,black,false Monkey,golden,false Duck,white,true xxxx,xxxxx,xxxx xxxxx,xxxxxx,xxxx xxxxx,xxxxx,xxxx Preview Animal.java } xxxxxx xxxxxx(xxxxxx _xxxx, xxxxxx _xxxxx, xxxxxxx _xxxxxxx) { xxxxxxx(_xxxx); xxxxxxxx(_xxxxx); setCanSwim(_canSwim); } public String getType() { return type; } public String getColor() { return color; } public void setType(String _type) { xxxx.xxxx = _xxxx; } xxxxxx xxxx xxxxxxxx(xxxxxx _xxxxx) { xxxx.xxxxx = _xxxxx; } Preview PRG421Week3.java xxxxxxx xxxxxx xxxx xxxxxxxxx(xxxxxx x) { xxxxxxx.xxx(x); } private static void editAnimal(Animal a, String type, String color, boolean canSwim) { a.setType(type); a.setColor(color); a.setCanSwim(canSwim); } private static void deleteAnimal(Animal a) { int index = 0; for (Animal an: animals) { if (an.getCanSwim() == a.getCanSwim() && an.getColor().equals(a.getColor()) && an.getType().equals(a.getType())) { break; } else xxxxx++; } xx (xxxxx < xxxxxxx.xxxx()) xxxxxxx.xxxxxx(xxxxx); } Price: $15 Buy Now Checkout Added to cart Buy More Save More Buy at least TWO items & save up to 30% OFF your ENTIRE order! Rack up instant rebates in your shopping cart. Simply add items to your cart, and see the savings add up. Discounts will automatically be applied on eligible orders. PRG 421 Week 3 Individual Assignment Iterator Program – $15.00 PRG 421 Week 4 Individual Assignment Java Data Base Connectivity – $19.00 PRG 421 Week 5 Individual Assignment Concurrent Programming – $19.00 Add to Cart Checkout Added to cart FLASH SALE $65 $83 Save $18 PRG 421 Entire Course Get Entire Course You May Also Like: PRG 421 Entire Course PRG 421 Week 1 Individual Assignment Singleton Pattern Program PRG 421 Week 2 Individual Assignment ArrayList Program PRG 421 Week 4 Individual Assignment Java Data Base Connectivity PRG 421 Week 5 Individual Assignment Concurrent Programming

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.