package com.veggie.src.java.controllers.transaction;

import java.util.*;

import com.veggie.src.java.form.Form;
import com.veggie.src.java.notification.Notification;

public class RespondToRequestController {

	//Instance Variables


	//Methods
	public Form activate() {
		return null;
	}

 	public void respondToNotification(Notification notif) {
    //TO DO
  }

}

@@ -100,20 +100,17 @@
 va.form.
-Form
+*
 ;%0Aimport
@@ -143,28 +143,56 @@
 ication.
-Notification
+*;%0Aimport com.veggie.src.java.database.*
 ;%0A%0Apubli
@@ -255,135 +255,929 @@
 les%0A
-%0A%0A%09//Methods%0A%09public Form activate() %7B%0A%09%09return null;%0A%09%7D%0A%0A %09public void respondToNotification(Notification notif) %7B%0A    //TO DO
+%09private Notification notification;%0A%09private Form respondForm;%0A%09private TransactionDatabaseManager manager;%0A%0A%09//Methods%0A%09public RespondToRequestController() %7B%0A%09%09AbstractFormBuilder builder = AbstractFormBuilderFactory.getInstance().createFormBuilder();%0A%09%09builder.addField(%22Request ID%22);%0A%09%09builder.addField(%22Response%22);%0A%09%09respondForm = builder.getResult();%0A%09%09manager = AbstractDatabaseManagerFactory.getInstance().createTransactionDatabaseManager();%0A%09%7D%0A%09%0A%09public Form activate() %7B%0A%09%09return respondForm;%0A%09%7D%0A%09%0A%09public Notification submitForm(Form form) %7B%0A%09%09respondForm = form;%0A%09%09notification = AbstractNotificationFactory.getInstance().createConfirmNotification(%22Proceed with request response?%22);%0A%09%09return notification;%0A%09%7D%0A%0A %09public void respondToNotification(Notification notif) %7B%0A    if (notif.ok()) %7B%0A%09%09%09List%3CString%3E formData = respondForm.getData();%0A%09%09%09manager.finalizeTransaction(Integer.parseInt(formData.get(0)));%0A%09%09%7D
 %0A  %7D

Implement RespondToRequestController