/**
 * Constructor method for the view.  The view serves as the communication channel 
 * between widgets and as a wrapper for the entire UI.
 * 
 * @param {Object} config The view configuration object has the following format:<br/>
 * 	{<br/>
 * 		&nbsp;&nbsp;parent : "contentwrapper"<br/>
 * 	}
 * @constructor
 */
HD.REO.View = function(config) {
	this.config = config || {};
	this.observers = [];
};

/**
 * Rider's Edge Online common CSS class names.
 */
HD.REO.View.CSS_CLASSES = {
	SEARCH : "hdReoSearch",
	LIST : "hdReoList",
	DETAIL : "hdReoDetail",
	ENROLL : "hdReoEnroll",
	SUMMARY : "hdReoSummary",
	CONFIRMATION : "hdReoConfirmation",
	OPEN : "hdReoOpen",
	WAITLIST : "hdReoWaitlist",
	FULL : "hdReoFull",
	DEALER_VIEW : "hdDealerView",
	MSF_VIEW : "hdMsfView",
	DWP_DEALER_VIEW : "hdDWPDealerView",
	NON_DWP_DEALER_VIEW : "hdNonDWPDealerView",
	DEALER_LOCATOR_VIEW : "hdDealerLocationView"
};

HD.REO.View.prototype = {
	/**
	 * Add class name to the parent element.
	 * 
	 * @param {String} classs The class name to add
	 */
	addClass : function(classs) {
		HD.util.Dom.addClass(this.config.parent, classs);
	},
	
	/**
	 * Remove class name from the parent element.
	 * 
	 * @param {String} classs The class name to remove
	 */
	removeClass : function(classs) {
		HD.util.Dom.removeClass(this.config.parent, classs);
	}
};

HD.util.Common.extend(HD.REO.View, [HD.util.Observable]);