Documentation ¶
Overview ¶
Package file provides functions for dealing with files.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Scope = wdte.S().Map(map[wdte.ID]wdte.Func{ "open": wdte.GoFunc(Open), "create": wdte.GoFunc(Create), "append": wdte.GoFunc(Append), })
Scope is a scope containing the functions in this package.
Functions ¶
func Append ¶
Append is a WDTE function with the following signature:
append path
Opens the file at path for appending, creating it if it doesn't already exist, and returns it.
Types ¶
type File ¶
File wraps an os.File, allowing it to be used as a WDTE function. While it contains unexproted fields, it is safe for a client to simply wrap an *os.File in it manually.
A file is considered a "File" by reflection, as well as a "Reader" if it is opened for reading and a "Writer" if it is opened for writing. If the file was created manually, it will be considered both a reader and a writer.
Click to show internal directories.
Click to hide internal directories.