filetype

package
v1.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CsvFileType = FileType{
	"csv",
	misc.ArrToMap("csv"),
	validator.CsvValidator{},
}

Instance of the FileType object to represent a CSV file

View Source
var EnvFileType = FileType{
	"env",
	misc.ArrToMap("env"),
	validator.EnvValidator{},
}

Instance of the FileType object to represent a ENV file

An array of files types that are supported by the validator

View Source
var HclFileType = FileType{
	"hcl",
	misc.ArrToMap("hcl"),
	validator.HclValidator{},
}

Instance of the FileType object to represent a HCL file

View Source
var HoconFileType = FileType{
	"hocon",
	misc.ArrToMap("hocon"),
	validator.HoconValidator{},
}

Instance of the FileType object to represent a HOCON file

View Source
var IniFileType = FileType{
	"ini",
	misc.ArrToMap("ini"),
	validator.IniValidator{},
}

Instance of FileType object to represent a Ini file

View Source
var JsonFileType = FileType{
	"json",
	misc.ArrToMap("json"),
	validator.JsonValidator{},
}

Instance of the FileType object to represent a JSON file

View Source
var PlistFileType = FileType{
	"plist",
	misc.ArrToMap("plist"),
	validator.PlistValidator{},
}

Instance of the FileType object to represent a Plist file

View Source
var PropFileType = FileType{
	"properties",
	misc.ArrToMap("properties"),
	validator.PropValidator{},
}

Instance of FileType object to represent a Properties file

View Source
var TomlFileType = FileType{
	"toml",
	misc.ArrToMap("toml"),
	validator.TomlValidator{},
}

Instance of FileType object to represent a Toml file

View Source
var XmlFileType = FileType{
	"xml",
	misc.ArrToMap("xml"),
	validator.XmlValidator{},
}

Instance of FileType object to represent a XML file

View Source
var YamlFileType = FileType{
	"yaml",
	misc.ArrToMap("yml", "yaml"),
	validator.YamlValidator{},
}

Instance of the FileType object to represent a YAML file

Functions

This section is empty.

Types

type FileType

type FileType struct {
	Name       string
	Extensions map[string]struct{}
	Validator  validator.Validator
}

The FileType object stores information about a file type including name, extensions, as well as an instance of the file type's validator to be able to validate the file

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL