User files
File (library.file.UserFileType) is a general-purpose type for holding uploaded files. It allows the file represented by the node to be re-uploaded.
Content files
Content File (library.file.ContentFileType) can be used to create content files. The content of the file and the extension are entered as node members.
Derived content files
Derived File (library.file.DerivedFileType) can be used to create content files that are calculated using scripts defined on the file node.
Derived File supports inheritance, though you will need to manually set the tab number to 0.
Derived content files define the script within the file node themselves. This would not be appropriate for many solutions, which need to control the script more carefully. However, it is relatively easy to create a node type which derives content files:
- Set the Display Class display property to "file".
- Set the File Class display property to "content".
- Set the File Content value to the file content.
- Set the File Extension value to the file extension.
- Set the File Size scale to the size of the content. You can use the Derive Content File Size member type to derive the file size from the content.
File with derivatives / derivative file
File With Derivatives (library.file.FileWithDerivativesType) is a specialised node type for creating user files, with additional support for managing images. It automatically creates a set of derivative files (of type Derivative File (library.file.DerivativeFileType)) according to a specification held in the File options (library.file.FileOptions) member. If the file is re-uploaded, the derivative files are updated accordingly.
File With Derivatives is used by member types created with Upload Member Type (library.file.UploadMemberTypeType) and Gallery Member Type (library.file.GalleryMemberTypeType). These member types and thefile options are documented in File member type types.
Nodes of type File With Derivatives record the derivative files within the Derivative files (library.file.DerivativeFiles) members. This is a bindings-like member type which can be used to retrieve a particular derivative, such as an image preview.