¥class
GovernmentEntry extends CityEntry {
¥ String name, address, phone, city,
state, government;
¥ GovernmentEntry(String n, String a,
String p, String c, String s, String g) {
¥ this.name = n;
¥ this.address = a;
¥ this.phone = p;
¥ this.city = c;
¥ this.state = s;
¥ this.government = g;
¥ }
¥ String getName() {
return this.name; }
¥ public String toString() {
¥ return "Government[" +
this.name + "," + this.address + "," + this.phone +
¥ "," +
this.city + "," + this.state + "," + this.government +
"]";
¥ }
¥}
¥class
Residential Entry extends CityEntry {
¥ String name, address, phone, city;
¥ ResidentialEntry(String n, String a,
String p) {
¥ this.name = n;
¥ this.address = a;
¥ this.phone = p;
¥ }
¥ String getName() {
return this.name; }
¥ public String toString() {
¥ return "Residential[" +
this.name + "," + this.address + "," + this.phone + "]";
¥ }
¥}
¥