Property FormatVersion
FormatVersion
Gets the format version that the repository actually has, as read from its info file when this instance opened the repository or written to it by an upgrade at that point.
Declaration
public RepoFormatVersion FormatVersion { get; }
Property Value
| Type | Description |
|---|---|
| RepoFormatVersion |
Remarks
The value is a specific version, never Latest. Once the repository is open it is at least MinimumFormatVersion, and it is higher when the repository already had a newer version, which is not changed. In ReadOnly mode, which never upgrades, it can also be lower than the option, or a version this library only supports for reading, which is then not a defined RepoFormatVersion value.
On a version 1 repository, transactions record their deletions with per-file markers instead of a delete journal, with the same behavior.
Exceptions
| Type | Condition |
|---|---|
| InvalidOperationException | The repository has not been opened yet: neither EnsureCreated() nor EnsureInitialized() has returned and no operation has run. |