Documentation ¶
Overview ¶
Package render provides the file content rendering for the web server.
Index ¶
- Variables
- func Diz(art *models.File, extraDir string) ([]byte, error)
- func Encoder(art *models.File, r io.Reader) encoding.Encoding
- func InsertDiz(b []byte, diz []byte) []byte
- func NoScreenshot(art *models.File, previewPath string) bool
- func Read(art *models.File, downloadDir, extraDir string) ([]byte, error)
- func Viewer(art *models.File) bool
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func Diz ¶ added in v1.5.1
Diz returns the content of the FILE_ID.DIZ file. The text is intended to be used as a readme, preview or an in-browser viewer.
func Encoder ¶
Encoder returns the encoding for the model file entry. Based on the platform and section. Otherwise it will attempt to determine the encoding from the file byte content.
func InsertDiz ¶ added in v1.5.1
InsertDiz inserts the FILE_ID.DIZ content into the extisting byte content.
func NoScreenshot ¶
NoScreenshot returns true when the file entry should not attempt to display a screenshot. This is based on the platform, section or if the screenshot is missing on the server.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.