本文整理汇总了PHP中Swift_RecipientList::getTo方法的典型用法代码示例。如果您正苦于以下问题:PHP Swift_RecipientList::getTo方法的具体用法?PHP Swift_RecipientList::getTo怎么用?PHP Swift_RecipientList::getTo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Swift_RecipientList
的用法示例。
在下文中一共展示了Swift_RecipientList::getTo方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testArraysCanBeAdded
public function testArraysCanBeAdded()
{
$list = new Swift_RecipientList();
$list->addTo("a@a");
$list->addTo(array("b@b", "a@a", "c@c"));
$list->addTo(array(new Swift_Address("d@d", "D"), "e@e"), "E");
$this->assertEqual(array("a@a", "b@b", "c@c", "d@d", "e@e"), array_keys($list->getTo()));
}
示例2: getToAddresses
/**
* Get an array of To addresses
* This currently returns an array of Swift_Address objects and may be simplified to an array of strings in later versions
* @return array
*/
public function getToAddresses()
{
return $this->recipients->getTo();
}