Types
28 pages.
The complete vocabulary of built-in types — the scalars you can store, the collections, the two callable spellings (`Action` and `Func`), and the…
The values your app computes with, and the declarations that name and scope them. Most scalar types are exactly C#'s — int, long, double, string…
`&`, `|`, `^`, `~`, `<<` and `>>` work on `int`, with C#'s meanings and C#'s precedence. Unlike `+`, `-`, `*` and `/`, they do not raise on overflow…
The members of C#'s `string` that take a `StringComparison`, a `CultureInfo`, a `StringSplitOptions` or a `NormalizationForm` work as in C#, with…
Some places take a value that must be known at compile time — an attribute argument, a config setting, a workflow message. Adjacent string literals…
`DateOnly` is a calendar date (no time); `TimeOnly` is a time of day (no date) — the C# types. Build them with `new DateOnly(y, m, d)` / `new…
A date and time. It is a wall-clock value, not an instant on a timeline, so it is never shifted by anybody's timezone. Reading its parts and doing…
An instant *plus the offset it was recorded at*. Use it when the local time something happened is part of the fact — a warehouse `TIMESTAMP_TZ`, a…
`Entity` is a reference to a row of ANY type the app keeps — what a notification, a comment or a question "about some record" holds. It reads as its…
A place, a route or an area on the Earth, as a GeoJSON geometry — longitude/latitude, WGS84. It is exactly the shape a browser map library draws and…
C#'s collection interfaces are accepted wherever a type is written, each as the collection it names: IEnumerable<T>, IReadOnlyList<T> and…
A member that holds a JSON document — an object, an array, or any value. It is stored as real jsonb, and written and read through JsonSerializer, so…
A member that holds a markdown document. You read and write it as ordinary text, but it is stored as a list of sections split on its headings, so a…
A member is required or optional by how you spell its type. A bare value type with a natural zero reads that zero; a bare value-shaped type with no…
`TimeSpan` is the duration type — a length of time, as in C#. Build one with the `TimeSpan.FromX` factories or `new TimeSpan(…)`, read…
A duration, a bare date, and a bare time of day. Subtracting two DateTimes gives a TimeSpan; adding one back gives a DateTime. All three are exact…
The platform puts 70 ordinary English words in scope in every app with no `using` — `Group`, `Match`, `Point`, `Month`, `Now`, `Uri`, `Connection`…
Exact base-10 arithmetic with 38 significant digits — for warehouse columns and anything else too wide for `decimal`. Every rule it follows is…
Raw bytes — a file's contents, a digest, a key. Write one as C# does, `new byte[] { 0x89, 0x50 }`, or as a collection expression `[0x89, 0x50]`…
A single character, written in single quotes. It is what you get from `s[0]` and from iterating a string, and it is the argument the `char.*`…
Exact base-10 arithmetic, for money and anything else where a fraction of a cent matters. It behaves identically whether your code runs on the server…
A 64-bit whole number, exact to its full range — ids, sequence numbers, row versions, byte offsets. It holds the same value whether your code runs on…
Declares the namespace a file's types belong to, written once at the top of the file. It is optional — a file without one puts its types in the…
Three ways to write a string, all of them C#'s. The ordinary form processes escapes. The verbatim form (`@"…"`) processes none and may span lines…
A top-level declaration carries a public or internal visibility that decides whether code outside its package can name it. The default depends on…
typeof(X) and x.GetType() answer a Type, which is the type's name: Name ("Int32"), FullName ("System.Int32"), ToString() and ==. GetType() is the…
Declares a capability your app depends on, written inside the `app { }` manifest block. It provisions the capability (its tables and types become…
A postfix `!` tells the compiler a value it types as possibly-null is present — C#'s null-forgiving operator. It is a compile-time promise only: it…