Email methods syntax: Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (Automatically generated page update)
(Automatically generated page update)
 
(4 intermediate revisions by 2 users not shown)
Line 2: Line 2:
     replaced, so any manual edits will be lost. You've been warned. -->
     replaced, so any manual edits will be lost. You've been warned. -->
{{Template:Syntax list header|class=Email}}
{{Template:Syntax list header|class=Email}}
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">email</span><span class="literal">:[[AddBCC (Email subroutine)|AddBCC]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">email</span><span class="literal">:[[AddBCC (Email subroutine)|AddBCC]]</span><span class="literal">(</span> <span class="term" title="String">name</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">nickname</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddCC (Email subroutine)|AddCC]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddCC (Email subroutine)|AddCC]]</span><span class="literal">(</span> <span class="term" title="String">name</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">nickname</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddHeader (Email subroutine)|AddHeader]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="term" title="String">string</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddHeader (Email subroutine)|AddHeader]]</span><span class="literal">(</span> <span class="term" title="String">header</span><span class="comma">,</span> <span class="term" title="String">value</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddPart (Email subroutine)|AddPart]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Type=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Name=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Encoding=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span>     -
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddPart (Email subroutine)|AddPart]]</span><span class="literal">(</span> <span class="term" title="String">content</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Type=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Name=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Encoding=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span>   -
               <span class="squareb">[</span><span class="literal" title="String">Disposition=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Description=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
               <span class="squareb">[</span><span class="literal" title="String">Disposition=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Description=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddRecipient (Email subroutine)|AddRecipient]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[AddRecipient (Email subroutine)|AddRecipient]]</span><span class="literal">(</span> <span class="term" title="String">name</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">nickname</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentString</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Domain (Email property)|Domain]]</span>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentString</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Domain (Email property)|Domain]]</span>
<span class="term">email</span><span class="literal">:[[Domain (Email property)|Domain]]</span> <span class="literal">= </span><span class="term">newString</span></p>
<span class="term">email</span><span class="literal">:[[Domain (Email property)|Domain]]</span> <span class="literal">= </span><span class="term">newString</span></p>
Line 14: Line 14:
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentString</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Host (Email property)|Host]]</span>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentString</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Host (Email property)|Host]]</span>
<span class="term">email</span><span class="literal">:[[Host (Email property)|Host]]</span> <span class="literal">= </span><span class="term">newString</span></p>
<span class="term">email</span><span class="literal">:[[Host (Email property)|Host]]</span> <span class="literal">= </span><span class="term">newString</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%number</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">email</span><span class="literal">:[[Mail (Email function)|Mail]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="String">Port=</span><span class="squareb">]</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Number">CancelOnError=</span><span class="squareb">]</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%rc</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">email</span><span class="literal">:[[Mail (Email function)|Mail]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="String">Port=</span><span class="squareb">]</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="squareb">[</span><span class="literal" title="Number">CancelOnError=</span><span class="squareb">]</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span>              -
                    <span class="squareb">[</span><span class="literal" title="String">Userid=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Password=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%email</span><span class="literal"> =</span> <span class="squareb">[</span><span class="literal">%(Email):</span><span class="squareb">]</span><span class="literal">[[New (Email constructor)|New]]</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%email</span><span class="literal"> =</span> <span class="squareb">[</span><span class="literal">%(Email):</span><span class="squareb">]</span><span class="literal">[[New (Email constructor)|New]]</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentPort</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Port (Email property)|Port]]</span>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentPort</span><span class="literal"> =</span> <span class="term">email</span><span class="literal">:[[Port (Email property)|Port]]</span>
<span class="term">email</span><span class="literal">:[[Port (Email property)|Port]]</span> <span class="literal">= </span><span class="term">newPort</span></p>
<span class="term">email</span><span class="literal">:[[Port (Email property)|Port]]</span> <span class="literal">= </span><span class="term">newPort</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[Sender (Email subroutine)|Sender]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="squareb">[</span><span class="term">%number</span><span class="literal"> =</span><span class="squareb">]</span> <span class="term">email</span><span class="literal">:[[RemoveRecipient (Email function)|RemoveRecipient]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[SetBody (Email subroutine)|SetBody]]</span><span class="literal">(</span> <span class="term" title="String">string</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Type=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Name=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Encoding=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[Sender (Email subroutine)|Sender]]</span><span class="literal">(</span> <span class="term" title="String">name</span><span class="comma">,</span> <span class="squareb">[</span><span class="term" title="String">nickname</span><span class="squareb">]</span><span class="literal">)</span></p>
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">email</span><span class="literal">:[[SetBody (Email subroutine)|SetBody]]</span><span class="literal">(</span> <span class="term" title="String">content</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Type=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Name=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Encoding=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="literal">)</span></p>

Latest revision as of 18:39, 14 October 2016

The syntax for each of the Email class methods is shown below.

Square brackets indicate optional elements of the method invocation. See also the notation conventions for methods and the List of Email methods.

email:AddBCC( name, [nickname])

email:AddCC( name, [nickname])

email:AddHeader( header, value)

email:AddPart( content, [Type= string], [Name= string], [Encoding= string], - [Disposition= string], [Description= string])

email:AddRecipient( name, [nickname])

%currentString = email:Domain email:Domain = newString

%number = email:GetReplyCode

%string = email:GetReplyText

%currentString = email:Host email:Host = newString

[%rc =] email:Mail[( [[Port=] string], [[CancelOnError=] number], - [Userid= string], [Password= string])]

%email = [%(Email):]New

%currentPort = email:Port email:Port = newPort

[%number =] email:RemoveRecipient( string)

email:Sender( name, [nickname])

email:SetBody( content, [Type= string], [Name= string], [Encoding= string])