validator

package
v0.0.0-...-0664266 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2014 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NewLineRegex *regexp.Regexp = regexp.MustCompile("(\n)")
View Source
var PositionalPlaceholderRegex *regexp.Regexp = regexp.MustCompile("(\\%[0-9]+\\$[a-zA-Z])")
View Source
var PotentialPlaceholderRegex *regexp.Regexp = regexp.MustCompile("(\\%\\s)")
View Source
var SimplePlaceholderRegex *regexp.Regexp = regexp.MustCompile("(\\%[a-zA-Z])")

Functions

func Validate

func Validate(resDir, baseLocale, stringsFilename string, showMissing bool) (errorList []error)

Validate the string resources that are inside the "resDir" directory. The XML string file for the "baseLocale" is not validated, but used for comparison. Returns a list of errors.

Types

type ResourceMissingError

type ResourceMissingError struct {
	// contains filtered or unexported fields
}

func (*ResourceMissingError) Error

func (r *ResourceMissingError) Error() string

type ValidationError

type ValidationError struct {
	// contains filtered or unexported fields
}

func (*ValidationError) Error

func (v *ValidationError) Error() string

Jump to

Keyboard shortcuts

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