Class Reference
IRIS for UNIX 2019.2
InterSystems: The power behind what matters   
Documentation  Search
  [ENSLIB] >  [%Net] >  [MIMEWriter]
Private  Storage   

class %Net.MIMEWriter extends %RegisteredObject

%Net.MIMEWriter outputs a MIME document as represented by a top level %Net.MIMEPart with multiple parts specified.


Parameters Properties Methods Queries Indices ForeignKeys Triggers
2 15


%%OIDGet %AddToSaveSet %BindExport %BuildObjectGraph
%ClassIsLatestVersion %ClassName %Close %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IncrementCount %IsA %IsModified
%New %NormalizeObject %ObjectModified %OriginalNamespace
%PackageName %RemoveFromSaveSet %SerializeObject %SetModified
%ValidateObject OutputToDevice OutputToFile OutputToStream
WriteHeader WriteMIMEBody WriteMIMEMessage


• property OutputDestination as %String [ Private,InitialExpression = "device" ];
Destination for %Net.MIMEWriter output. Possible values are "file", "stream" and "device".
• property OutputStream as %RawString [ Private ];
Stream for output to stream or file. Will store a stream, but declare as %RegisteredObject to prevent auto create of serial object.


• private method %Write(text As %String)
• private method AppendToOutput(ByRef out As %String, str As %String)
Append encoded data to output buffer
• private method EncodeStreamBase64(stream As %Stream.Object) as %Status
Write stream -- base64 encoded
• private method EncodeStreamQuotedPrintable(stream As %Stream.Object) as %Status
Write stream -- quoted printable encoded
• private method OutputNoEncoding(stream As %Stream.Object)
Write stream - not encoded
• method OutputToDevice() as %Status
OutputToDevice sets output to the current device which is the default if no output method is specified.
• method OutputToFile(filename As %String) as %Status
OutputToFile sets output to be directed to a new file, named filename. The file is created with parameters "WNS".
• method OutputToStream(ByRef export As %BinaryStream) as %Status
OutputToStream sets output to be directed to a stream. export is the exported stream. If export is the oref of a stream, the MIME document will be written to this existing stream at the current position. If export is "", then a new %GlobalBinaryStream will be created to contain the MIME document and its oref returned. In this case, export must be passed by reference.
• private method ProcessLine(line As %String)
Output buffered output
• private method WriteBody(message As %Net.MIMEPart) as %Status
Write the body.
• method WriteHeader(name As %String, value As %String)
Write a header
• method WriteMIMEBody(message As %Net.MIMEPart) as %Status
WriteMIMEBody outputs the body of a MIME multipart message. If the messsage is multipart, the caller is expected to output needed headers. If the message, is not multipart, then headers are output.
• method WriteMIMEMessage(message As %Net.MIMEPart) as %Status
WriteMIMEMessage outputs a MIME message.
• private method WritePart(part As %Net.MIMEPart) as %Status
Write a MIME part
• private method pad2(n As %String) as %String
Return integer or hex padded to 2 place with leading zeros

Copyright (c) 2019 by InterSystems Corporation. Cambridge, Massachusetts, U.S.A. All rights reserved. Confidential property of InterSystems Corporation.