-
Notifications
You must be signed in to change notification settings - Fork 2
Record
A buffer interface for piping data between tasks.
A Record is a representation of some form of input, typically a file, whose contents are stored in an underlying buffer. Records are passed between Tasks, allowing unlimited in-memory transformations before being written to their final destination. A valid Record instance must include the following properties and methods. The canonical implementation is node-record.
A property identifying the path to a record.
String property containing the record's encoding.
The underlying buffer. May be an ES5 accessor method.
Fill internal buffer synchronously and return self for chaining. Input may be any Buffer, or a string which is valid for the record's encoding.
Append data to internal buffer synchronously and return self for chaining. Input may be any Buffer, or a string which is valid for the record's encoding.
Prepend data to internal buffer synchronously and return self for chaining. Input may be any Buffer, or a string which is valid for the record's encoding.
Return string value of underlying buffer. If encoding is undefined, use the encoding from the instance. If that is also undefined, default to 'utf8'.
Return a clone of the record.
Pass a clone of this record to method
, yielding a promise which resolves to its return value. If the transformation method is asynchronous, it must return a promise.