PHP Interface Sulu\Bundle\ContactBundle\Contact\ContactManagerInterface

Afficher le fichier Open project: sulu/sulu Interface Usage Examples

Méthodes publiques

Méthode Description
addAddress ( $entity, Address $address, boolean $isMain ) adds an address to the entity.
getAddressRelations ( $entity ) : mixed Returns a collection of relations to get addresses.
getById ( $id, $locale ) : mixed Returns an api entity.
getByIds ( $ids, $locale ) : mixed Returns api entities.
removeAddressRelation ( $entity, $address ) : mixed removes the address relation from a contact and also deletes the address if it has no more relations.
setMainEmail ( $entity ) : mixed sets main email, based on emails that are set on entity.
setMainFax ( $entity ) : mixed sets main fax, based on faxes that are set on entity.
setMainForCollection ( $arrayCollection ) sets the first element to main, if none is set.
setMainPhone ( $entity ) : mixed sets main phone, based on phones that are set on entity.
setMainUrl ( $entity ) : mixed sets main url, based on urls that are set on entity.
unsetMain ( $arrayCollection ) : boolean unsets main of all elements of an ArrayCollection | PersistanceCollection.

Method Details

addAddress() public méthode

adds an address to the entity.
public addAddress ( $entity, Address $address, boolean $isMain )
$entity The entity to add the address to
$address Sulu\Bundle\ContactBundle\Entity\Address The address to be added
$isMain boolean Defines if the address is the main Address of the contact

getAddressRelations() public méthode

Returns a collection of relations to get addresses.
public getAddressRelations ( $entity ) : mixed
$entity
Résultat mixed

getById() public méthode

Returns an api entity.
public getById ( $id, $locale ) : mixed
$id
$locale
Résultat mixed

getByIds() public méthode

Returns api entities.
public getByIds ( $ids, $locale ) : mixed
$ids
$locale
Résultat mixed

removeAddressRelation() public méthode

removes the address relation from a contact and also deletes the address if it has no more relations.
public removeAddressRelation ( $entity, $address ) : mixed
$entity
$address
Résultat mixed

setMainEmail() public méthode

sets main email, based on emails that are set on entity.
public setMainEmail ( $entity ) : mixed
$entity
Résultat mixed

setMainFax() public méthode

sets main fax, based on faxes that are set on entity.
public setMainFax ( $entity ) : mixed
$entity
Résultat mixed

setMainForCollection() public méthode

sets the first element to main, if none is set.
public setMainForCollection ( $arrayCollection )
$arrayCollection

setMainPhone() public méthode

sets main phone, based on phones that are set on entity.
public setMainPhone ( $entity ) : mixed
$entity
Résultat mixed

setMainUrl() public méthode

sets main url, based on urls that are set on entity.
public setMainUrl ( $entity ) : mixed
$entity
Résultat mixed

unsetMain() public méthode

unsets main of all elements of an ArrayCollection | PersistanceCollection.
public unsetMain ( $arrayCollection ) : boolean
$arrayCollection
Résultat boolean returns true if a element was unset