You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
363 B
Rust
21 lines
363 B
Rust
use mediarepo_database::entities::namespace;
|
|
|
|
#[derive(Clone, Debug)]
|
|
pub struct NamespaceDto {
|
|
model: namespace::Model,
|
|
}
|
|
|
|
impl NamespaceDto {
|
|
pub(crate) fn new(model: namespace::Model) -> Self {
|
|
Self { model }
|
|
}
|
|
|
|
pub fn id(&self) -> i64 {
|
|
self.model.id
|
|
}
|
|
|
|
pub fn name(&self) -> &String {
|
|
&self.model.name
|
|
}
|
|
}
|