Toggle menu
862
3.8K
30.2K
279.1K
Catglobe Wiki
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Blacklist addEmails: Difference between revisions

From Catglobe Wiki
Nguyenduyan (talk | contribs)
No edit summary
Nguyenduyan (talk | contribs)
No edit summary
 
Line 29: Line 29:
//Way 1: Each email is an EmailBlacklist object
//Way 1: Each email is an EmailBlacklist object
EmailBlacklist email1 = new EmailBlacklist ("[email protected]", "comment1");
EmailBlacklist email1 = new EmailBlacklist ("[email protected]", "comment1");
EmailBlacklist email2 = new EmailBlacklist ("email28@test.com", "comment2");
EmailBlacklist email2 = new EmailBlacklist ("email2@test.com", "comment2");
array emails = {email1, email2};
array emails = {email1, email2};
Blacklist_addEmails(emails);//2
Blacklist_addEmails(emails);//2

Latest revision as of 04:22, 11 August 2017


Blacklist_addEmails

Add emails to blacklist

Syntax

Blacklist_addEmails(array emails);

Arguments

emails: array. Array of emails.

There are 2 ways of using array emails:

The first way: Each email is an EmailBlacklist object

The second way: Each email is an array with pair of email and comment {email, comment}

Return type

Number. Number of emails added to Blacklist

Example

//Way 1: Each email is an EmailBlacklist object
EmailBlacklist email1 = new EmailBlacklist ("[email protected]", "comment1");
EmailBlacklist email2 = new EmailBlacklist ("[email protected]", "comment2");
array emails = {email1, email2};
Blacklist_addEmails(emails);//2

//Way 2: Each email is an array with pair of email and comment 
array email1 = {"[email protected]", "comment2"};
array email2 = {"[email protected]", "comment2"};
array emails = {email1, email2};
Blacklist_addEmails(emails);//2