Babylon.NET - ResourcesProvider

Simple - intuitive - productive - Visual Studio localization has never been easier.

 

XML ResourcesProvider

The provider will read all XML files in the base directory and treat them as files containing string resources.

Files are named using the pattern <filename>.[<culture code=code>].xml. The provider assumes invariant strings are contained in a file with no culture code in the file name (e.g. strings.xml). All files containing culture codes (e.g. strings.de-DE.xml) will be treated as translations.

Strings not present in the invariant file are ignored.

Relative paths are fully supported. Subfolders of the base directory are also processed. The name of the subfolder becomes part of the resource name and therefore all translations of an invariant file must be placed in the same folder.

Comments are supported.

Download the provider source code including example files.

JSON ResourcesProvider

The provider will read all JSON files in the base directory and treat them as files containing string resources.

Files are named using the pattern <filename>.[<culture code=code>].json. The provider assumes invariant strings are contained in a file with no culture code in the file name (e.g. strings.json). All files containing culture codes (e.g. strings.de-DE.json) will be treated as translations.

Strings not present in the invariant file are ignored.

Relative paths are fully supported. Subfolders of the base directory are also processed. The name of the subfolder becomes part of the resource name and therefore all translations of an invariant file must be placed in the same folder.

Comments are not supported.

Download the provider source code including example files.

Java .properties ResourcesProvider

The provider will read all Java .properties files in the base directory and treat them as files containing string resources.

The provider assumes that invariant strings are contained in a file with no culture codes in the file name (e.g. strings.properties). All files containing culture codes of the form _culturecode-countrycode (e.g. strings_de-DE.json) will be treated as translations.

Strings not present in the invariant file are ignored.

Relative paths are fully supported. Subfolders of the base directory are also processed. The name of the subfolder becomes part of the resource name and therefore all translations of an invariant file must be placed in the same folder.

Only the default ISO-8859-1 (Latin1) encoding is supported. No escaping will be done. Any comments or other lines in the files will be stripped. Comments are not supported.

Download the provider source code including example files.

Copyright 2016 by Redpin - The localization experts | .NET and Localization. | Download | Buy | Privacy | Contact