C# Класс BlogEngine.Core.Json.JsonCulture

Represents the i18n culture used by blog.js. Used by ResourceHandler.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AddResource ( string resourceLabelKey ) : string

Adds a new translatable string resource to this JsonCulture.

JsonCulture ( CultureInfo cultureInfo, ResourceType resourceType ) : System

Creates a new JsonCulture instance from the supplied CultureInfo.

This class uses a dictionary as its basis for storing/caching its information. This makes it incredibly easy to extend without having to create/remove properties.

ToJsonString ( ) : string

Returns a JSON formatted string repressentation of this JsonCulture instance's culture labels.

Описание методов

AddResource() публичный Метод

Adds a new translatable string resource to this JsonCulture.
public AddResource ( string resourceLabelKey ) : string
resourceLabelKey string The key used to retrieve the translated value from global resource labels.
Результат string

JsonCulture() публичный Метод

Creates a new JsonCulture instance from the supplied CultureInfo.
This class uses a dictionary as its basis for storing/caching its information. This makes it incredibly easy to extend without having to create/remove properties.
public JsonCulture ( CultureInfo cultureInfo, ResourceType resourceType ) : System
cultureInfo System.Globalization.CultureInfo The CultureInfo needed to get the proper translations for this JsonCulture instance
resourceType ResourceType Type of resource (blog or admin)
Результат System

ToJsonString() публичный Метод

Returns a JSON formatted string repressentation of this JsonCulture instance's culture labels.
public ToJsonString ( ) : string
Результат string