Write - Function SummarySummary:Writes to a file, url, or port-spec (block or object). Usage:write destination value Arguments:destination - The destination argument. (must be: file url object block) value - The value argument. Refinements:/binary - Preserves contents exactly. /string - Translates all line terminators. /direct - Opens the port without buffering. /append - Writes to the end of an existing file. /no-wait - Returns immediately without waiting if no data. /lines - Handles data as lines. /part - Reads a specified amount of data. size - The size argument. (must be: number) /with - Specifies alternate line termination. end-of-line - The end-of-line argument. (must be: char string) /allow - Specifies the protection attributes when created. access - The access argument. (must be: block) /mode - Block of above refinements. args - The args argument. (must be: block) /custom - Allows special refinements. params - The params argument. (must be: block) Description:WRITE is typically used to write a file to disk, but many other operations, such as writing data to URLs and ports, are possible. Normally a string or binary value is provided to this function, but other types of data such as a number or a time can be written. They will be converted to text. The /BINARY refinement will write out data as its exact representation. This is good for writing image, sound and other binary data. The /STRING refinement translates line terminators to the operating system's line terminator. This behavior is default. The /APPEND refinement is useful logging purposes, as it won't overwrite existing data. The /LINES refinement can take a block of values and will write each value to a line. By default, WRITE will write the block of values as a concatonated string of formed values. The /PART refinement will read the specified number of elements from the data being written. The /WITH refinement converts characters, or strings, specified into line terminators. See the User's Guide for more detailed explanation of using READ and its refinements.
Related:close - Closes an open port connection.
| ||||||||
|