identities[$_id]; } else { return $this->identities; } } function getIncomingServer($_id = -1) { if($_id != -1) { return $this->ic_server[$_id]; } else { return $this->ic_server; } } function getOutgoingServer($_id = -1) { if($_id != -1) { return $this->og_server[$_id]; } else { return $this->og_server; } } function getPreferences() { return $this->preferences; } function getUserEMailAddresses() { $identities = $this->getIdentity(); if(count($identities) == 0) { return false; } $userEMailAdresses = array(); foreach($identities as $identity) { $userEMailAdresses[$identity->emailAddress] = $identity->realName; } return $userEMailAdresses; } function setIdentity($_identityObject, $_id = -1) { if(is_a($_identityObject, 'ea_identity')) { if($_id != -1) { $this->identities[$_id] = $_identityObject; } else { $this->identities[] = $_identityObject; } return true; } return false; } function setIncomingServer($_serverObject, $_id = -1) { if(is_a($_serverObject, 'defaultimap')) { if($_id != -1) { $this->ic_server[$_id] = $_serverObject; } else { $this->ic_server[] = $_serverObject; } return true; } return false; } function setOutgoingServer($_serverObject, $_id = -1) { if(is_a($_serverObject, 'defaultsmtp')) { if($_id != -1) { $this->og_server[$_id] = $_serverObject; } else { $this->og_server[] = $_serverObject; } return true; } return false; } function setPreferences($_preferences) { $this->preferences = $_preferences; return true; } } ?>