@criticalmanufacturing/dev-i18n-transform
Version:
i18n <--> gettext transform
24 lines (23 loc) • 1.11 kB
TypeScript
import { IConverterResourcesMethods } from "./converter.interface";
import { IDataLocalizedMessages } from "../model/database";
export declare class ResourcesConverter implements IConverterResourcesMethods {
/**
* In case of create a new file, this is the header used
*/
private fileHeader;
/**
* Add new localized message to culture file
* @param cultureFile (file of localized message culture)
* @param localizedMessage (localized message)
*/
private addNewLocalizedMessage;
/**
* Receiving a localized message, this method will find the file that will change and
* insert the new localized message.
* Return array with changed paths
* @param localized (localized messages)
* @param contentForEachFile (map with content for each file where keys are the paths and values the respective content)
* @param filesResourcesExtension (extension of files)
*/
writeToFile(localized: IDataLocalizedMessages[], contentForEachFile: Map<string, string>, filesResourcesExtension: string): Promise<string[]>;
}