# bookclerk_library::entities::editions

SeaORM entity for the `editions` table (text primary key).

| Item | Kind | Summary |
| --- | --- | --- |
| [`Model`](#model) | struct | Row shape for this table (`DeriveEntityModel`). |
| [`ColumnIter`](#columniter) | struct | An iterator over the variants of [Column] |
| [`Entity`](#entity) | struct | Generated by sea-orm-macros |
| [`PrimaryKeyIter`](#primarykeyiter) | struct | An iterator over the variants of [PrimaryKey] |
| [`ActiveModel`](#activemodel) | struct | Generated by sea-orm-macros |
| [`RelationIter`](#relationiter) | struct | An iterator over the variants of [Relation] |
| [`Column`](#column) | enum | Generated by sea-orm-macros |
| [`PrimaryKey`](#primarykey) | enum | Generated by sea-orm-macros |
| [`Relation`](#relation) | enum | Declared SeaORM relations (none unless FK edges are modeled). |

## Structs

### Model

```rust
pub struct Model {
    pub id: String,
    pub expression_id: String,
    pub media_kind: String,
    pub title: String,
    pub subtitle: Option<String>,
    pub published_at: Option<String>,
    pub duration_minutes: Option<i64>,
    pub cover_url: Option<String>,
    pub created_at: String,
    pub updated_at: String,
    pub enrich_source: Option<String>,
    pub enrich_confidence: Option<f64>,
    pub enrich_updated_at: Option<String>,
}
```

Row shape for this table (`DeriveEntityModel`).

**Fields**

- `id`: Edition id (a random UUID).
- `expression_id`: The expression it releases.
- `media_kind`: Form: `audiobook`, `ebook`, `print` or `podcast_audio`.
- `title`: Display title.
- `subtitle`: Subtitle when distinct from the title.
- `published_at`: Publication date (RFC 3339) when known.
- `duration_minutes`: Runtime in whole minutes when known.
- `cover_url`: HTTPS URL of cover art when known.
- `created_at`: RFC 3339 timestamp when the row was inserted.
- `updated_at`: RFC 3339 timestamp when the row was last modified.
- `enrich_source`: Who filled the edition's (and its work's) missing metadata:
  `metadata:<plugin key>` for a metadata provider, `audible` for the
  Audible catalog match; `None` until an enricher filled something.
- `enrich_confidence`: How sure that enricher was of its match, from 0.0 to 1.0.
- `enrich_updated_at`: When the enricher last filled it (RFC 3339).

#### Model::into_ex

```rust
pub fn into_ex(self) -> Self
```

Generated by sea-orm-macros

Implements: `Clone`, `Debug`, `From<Model>`, `FromQueryResult`, `IntoActiveModel<ActiveModel>`, `ModelTrait`, `PartialEq`, `TryFrom<ActiveModel>`, `TryIntoModel<Model>`

### ColumnIter

```rust
pub struct ColumnIter {
    /* private fields */
}
```

An iterator over the variants of [Column](#column)

Implements: `Clone`, `Debug`, `DoubleEndedIterator`, `ExactSizeIterator`, `FusedIterator`, `Iterator`

### Entity

```rust
pub struct Entity;
```

Generated by sea-orm-macros

Implements: `Clone`, `Copy`, `Debug`, `Default`, `EntityName`, `EntityTrait`, `Iden`, `IdenStatic`

### PrimaryKeyIter

```rust
pub struct PrimaryKeyIter {
    /* private fields */
}
```

An iterator over the variants of [PrimaryKey](#primarykey)

Implements: `Clone`, `Debug`, `DoubleEndedIterator`, `ExactSizeIterator`, `FusedIterator`, `Iterator`

### ActiveModel

```rust
pub struct ActiveModel {
    pub id: ActiveValue<String>,
    pub expression_id: ActiveValue<String>,
    pub media_kind: ActiveValue<String>,
    pub title: ActiveValue<String>,
    pub subtitle: ActiveValue<Option<String>>,
    pub published_at: ActiveValue<Option<String>>,
    pub duration_minutes: ActiveValue<Option<i64>>,
    pub cover_url: ActiveValue<Option<String>>,
    pub created_at: ActiveValue<String>,
    pub updated_at: ActiveValue<String>,
    pub enrich_source: ActiveValue<Option<String>>,
    pub enrich_confidence: ActiveValue<Option<f64>>,
    pub enrich_updated_at: ActiveValue<Option<String>>,
}
```

Generated by sea-orm-macros

**Fields**

- `id`: Generated by sea-orm-macros
- `expression_id`: Generated by sea-orm-macros
- `media_kind`: Generated by sea-orm-macros
- `title`: Generated by sea-orm-macros
- `subtitle`: Generated by sea-orm-macros
- `published_at`: Generated by sea-orm-macros
- `duration_minutes`: Generated by sea-orm-macros
- `cover_url`: Generated by sea-orm-macros
- `created_at`: Generated by sea-orm-macros
- `updated_at`: Generated by sea-orm-macros
- `enrich_source`: Generated by sea-orm-macros
- `enrich_confidence`: Generated by sea-orm-macros
- `enrich_updated_at`: Generated by sea-orm-macros

Implements: `ActiveModelBehavior`, `ActiveModelTrait`, `Clone`, `Debug`, `Default`, `From<Model>`, `IntoActiveModel<ActiveModel>`, `PartialEq`, `TryFrom<ActiveModel>`, `TryIntoModel<Model>`

### RelationIter

```rust
pub struct RelationIter {
    /* private fields */
}
```

An iterator over the variants of [Relation](#relation)

Implements: `Clone`, `Debug`, `DoubleEndedIterator`, `ExactSizeIterator`, `FusedIterator`, `Iterator`

## Enums

### Column

```rust
pub enum Column {
    Id,
    ExpressionId,
    MediaKind,
    Title,
    Subtitle,
    PublishedAt,
    DurationMinutes,
    CoverUrl,
    CreatedAt,
    UpdatedAt,
    EnrichSource,
    EnrichConfidence,
    EnrichUpdatedAt,
}
```

Generated by sea-orm-macros

**Variants**

- `Id`: Generated by sea-orm-macros
- `ExpressionId`: Generated by sea-orm-macros
- `MediaKind`: Generated by sea-orm-macros
- `Title`: Generated by sea-orm-macros
- `Subtitle`: Generated by sea-orm-macros
- `PublishedAt`: Generated by sea-orm-macros
- `DurationMinutes`: Generated by sea-orm-macros
- `CoverUrl`: Generated by sea-orm-macros
- `CreatedAt`: Generated by sea-orm-macros
- `UpdatedAt`: Generated by sea-orm-macros
- `EnrichSource`: Generated by sea-orm-macros
- `EnrichConfidence`: Generated by sea-orm-macros
- `EnrichUpdatedAt`: Generated by sea-orm-macros

Implements: `Clone`, `ColumnTrait`, `Copy`, `Debug`, `FromStr`, `Iden`, `IdenStatic`, `IntoEnumIterator`

### PrimaryKey

```rust
pub enum PrimaryKey {
    Id,
}
```

Generated by sea-orm-macros

**Variants**

- `Id`: Generated by sea-orm-macros

Implements: `Clone`, `Copy`, `Debug`, `Iden`, `IdenStatic`, `IntoEnumIterator`, `PrimaryKeyToColumn`, `PrimaryKeyTrait`

### Relation

```rust
pub enum Relation {}
```

Declared SeaORM relations (none unless FK edges are modeled).

Implements: `Clone`, `Copy`, `Debug`, `IntoEnumIterator`, `RelationTrait`
