Table of Contents

Class Language

Namespace
ToSic.Eav.Data.Sys.Dimensions
Assembly
ToSic.Eav.Data.dll

Supports all classes in the .NET Framework class hierarchy and provides low-level services to derived classes. This is the ultimate base class of all classes in the .NET Framework; it is the root of the type hierarchy.

[InternalApi_DoNotUse_MayChangeWithoutNotice]
public record Language : ILanguage, IDimension, IEquatable<Language>
Inheritance
object
Language
Implements

Constructors

Language(string, bool, int)

Represents a Dimension / Language Assignment to a value.

public Language(string Key, bool ReadOnly, int Id = 0)

Parameters

Key string
ReadOnly bool
Id int

Properties

Id

Gets the internal DimensionId as it is stored in the DB. This is only used for scenarios where the dimensions are defined in relational data.

public int Id { get; init; }

Property Value

int

Remarks

This was called DimensionId till v22, but was renamed to Id to be more consistent with other entities.

Key

Gets the main dimension Key.

public string Key { get; }

Property Value

string

Remarks

For languages, it's usually values like en-us or de-de (always lower case)

ReadOnly

Gets whether Dimension is assigned read only.

public bool ReadOnly { get; init; }

Property Value

bool

Remarks

This affects the UI, so that the value cannot be edited in these dimensions.