class Rosetta::Parser

Defined in:

rosetta/parser.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(path : String, default_locale : String | Symbol, available_locales : Array(String | Symbol)) #

[View source]

Instance Method Detail

def alternative_locales : Array(String) #

[View source]
def available_locales : Array(String) #

[View source]
def default_locale : String #

[View source]
def error : String | Nil #

[View source]
def load! : Void #

Loads and parses JSON files, then YAML files, adds them to the list of translations.


[View source]
def parse! : String #

Returns a list of self-containing translation modules.


[View source]
def path : String #

[View source]
def translations : Hash(String, Hash(String, String)) #

[View source]