Translation

Represents translation with expressions.

  • key

    Key that identifies a translation.

    Declaration

    Swift

    let key: String
  • Expressions that are related to a translation.

    Declaration

    Swift

    let expressions: [Expression]
  • Validates passed text and uses fittingWidth for getting proper localized string.

    Declaration

    Swift

    func validate(text: String, fittingWidth: Int?) -> String?

    Parameters

    text

    A text that is matched.

    fittingWidth

    A max width of a screen that text should match.

    Return Value

    A localized string if any expression validates the text, otherwise nil.