bookclerk_library::entities::copy_grants
SeaORM entity for copy_grants: one reader's leave to download the
copy this library holds of one edition. Written by
control_plane::copies.
| Item | Kind | Summary |
|---|---|---|
Model |
struct | Row shape for one grant. |
ColumnIter |
struct | An iterator over the variants of [Column] |
Entity |
struct | Generated by sea-orm-macros |
PrimaryKeyIter |
struct | An iterator over the variants of [PrimaryKey] |
ActiveModel |
struct | Generated by sea-orm-macros |
RelationIter |
struct | An iterator over the variants of [Relation] |
Column |
enum | Generated by sea-orm-macros |
PrimaryKey |
enum | Generated by sea-orm-macros |
Relation |
enum | Declared SeaORM relations (none). |
pub struct Model {
pub copy_id: String,
pub token_hash: String,
pub holder_kind: String,
pub holder_id: String,
pub user_id: i64,
pub edition_id: String,
pub serving_node_id: String,
pub destination: String,
pub files_digest: String,
pub created_at: String,
pub expires_at: String,
}
Row shape for one grant.
Fields
copy_id: Copy id (hyphenated UUID).token_hash:hash_tokenof the bearer token; the token itself is never stored.holder_kind: What asked:node(a branch) orcard(a clerk's library card).holder_id: The asking node's id, or the card's id.user_id: The person the copy is for (users.id).edition_id: The edition copied.serving_node_id: The node that answered the grant and serves the files.destination: The output destination on that node the files are read from.files_digest: Digest of the edition's file rows on that destination at grant, in download order; a download is refused once they differ.created_at: RFC 3339 grant time.expires_at: RFC 3339 time after which the token is refused.
pub fn into_ex(self) -> Self
Generated by sea-orm-macros
Implements: Clone, Debug, Eq, From<Model>, FromQueryResult, IntoActiveModel<ActiveModel>, ModelTrait, PartialEq, TryFrom<ActiveModel>, TryIntoModel<Model>
pub struct ColumnIter {
/* private fields */
}
An iterator over the variants of Column
Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator
pub struct Entity;
Generated by sea-orm-macros
Implements: Clone, Copy, Debug, Default, EntityName, EntityTrait, Iden, IdenStatic
pub struct PrimaryKeyIter {
/* private fields */
}
An iterator over the variants of PrimaryKey
Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator
pub struct ActiveModel {
pub copy_id: ActiveValue<String>,
pub token_hash: ActiveValue<String>,
pub holder_kind: ActiveValue<String>,
pub holder_id: ActiveValue<String>,
pub user_id: ActiveValue<i64>,
pub edition_id: ActiveValue<String>,
pub serving_node_id: ActiveValue<String>,
pub destination: ActiveValue<String>,
pub files_digest: ActiveValue<String>,
pub created_at: ActiveValue<String>,
pub expires_at: ActiveValue<String>,
}
Generated by sea-orm-macros
Fields
copy_id: Generated by sea-orm-macrostoken_hash: Generated by sea-orm-macrosholder_kind: Generated by sea-orm-macrosholder_id: Generated by sea-orm-macrosuser_id: Generated by sea-orm-macrosedition_id: Generated by sea-orm-macrosserving_node_id: Generated by sea-orm-macrosdestination: Generated by sea-orm-macrosfiles_digest: Generated by sea-orm-macroscreated_at: Generated by sea-orm-macrosexpires_at: Generated by sea-orm-macros
Implements: ActiveModelBehavior, ActiveModelTrait, Clone, Debug, Default, From<Model>, IntoActiveModel<ActiveModel>, PartialEq, TryFrom<ActiveModel>, TryIntoModel<Model>
pub struct RelationIter {
/* private fields */
}
An iterator over the variants of Relation
Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator
pub enum Column {
CopyId,
TokenHash,
HolderKind,
HolderId,
UserId,
EditionId,
ServingNodeId,
Destination,
FilesDigest,
CreatedAt,
ExpiresAt,
}
Generated by sea-orm-macros
Variants
CopyId: Generated by sea-orm-macrosTokenHash: Generated by sea-orm-macrosHolderKind: Generated by sea-orm-macrosHolderId: Generated by sea-orm-macrosUserId: Generated by sea-orm-macrosEditionId: Generated by sea-orm-macrosServingNodeId: Generated by sea-orm-macrosDestination: Generated by sea-orm-macrosFilesDigest: Generated by sea-orm-macrosCreatedAt: Generated by sea-orm-macrosExpiresAt: Generated by sea-orm-macros
Implements: Clone, ColumnTrait, Copy, Debug, FromStr, Iden, IdenStatic, IntoEnumIterator
pub enum PrimaryKey {
CopyId,
}
Generated by sea-orm-macros
Variants
CopyId: Generated by sea-orm-macros
Implements: Clone, Copy, Debug, Iden, IdenStatic, IntoEnumIterator, PrimaryKeyToColumn, PrimaryKeyTrait
pub enum Relation {}
Declared SeaORM relations (none).
Implements: Clone, Copy, Debug, IntoEnumIterator, RelationTrait
Generated from crates/bookclerk-library at main · View as Markdown