/*
 * Requires: jquery, profile.js, phones.js, address.js, section.js
 */
var Investors = {};

function Investor(id, name, edit) {
	this.name = name;
	this.id = id;
	this.edit = edit;
}
Investor.prototype = {
	info: function() {
		var self = this;
		if (this.edit) {
			if (Profiles[this.getId()] && Profiles[this.getId()].setUpdate) {}
			else Profiles[this.getId()] = this;
			
			Phones[this.getId()] = new Contact('phone', this.getId());
			Addresses[this.getId()] = new Contact('address', this.getId());
		}
		else Profiles[this.getId()] = this;
		
		Sections[this.getId() + 'contact'] = new Section('contact', this.getId());
		Emails[this.getId()] = new Email(this.getId());
	}
};
Investor.prototype = jQuery.extend(Investor.prototype, Profile.prototype);