pub struct Question {
pub ac_rate: Option<f64>,
pub difficulty: Option<String>,
pub freq_bar: Option<f64>,
pub frontend_question_id: String,
pub is_favor: Option<bool>,
pub paid_only: Option<bool>,
pub status: Option<String>,
pub title: Option<String>,
pub title_slug: Option<String>,
pub has_solution: Option<bool>,
pub has_video_solution: Option<bool>,
pub topic_tags: Option<Vec<TopicTag>>,
}
Fields§
§ac_rate: Option<f64>
§difficulty: Option<String>
§freq_bar: Option<f64>
§frontend_question_id: String
§is_favor: Option<bool>
§paid_only: Option<bool>
§status: Option<String>
§title: Option<String>
§title_slug: Option<String>
§has_solution: Option<bool>
§has_video_solution: Option<bool>
Trait Implementations§
source§impl<'de> Deserialize<'de> for Question
impl<'de> Deserialize<'de> for Question
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl ModelUtils for Question
impl ModelUtils for Question
type ActiveModel = ActiveModel
type Entity = Entity
type Model = Model
fn on_conflict() -> OnConflict
fn post_multi_insert<'life0, 'async_trait>( db: &'life0 DatabaseConnection, objects: Vec<Self> ) -> Pin<Box<dyn Future<Output = AppResult<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
fn to_model(&self) -> AppResult<Self::Model>
fn to_db<'life0, 'life1, 'async_trait>( &'life0 self, db: &'life1 DatabaseConnection ) -> Pin<Box<dyn Future<Output = AppResult<InsertResult<Self::ActiveModel>>> + Send + 'async_trait>>where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,
fn multi_insert<'life0, 'async_trait>( db: &'life0 DatabaseConnection, objects: Vec<Self> ) -> Pin<Box<dyn Future<Output = AppResult<()>> + Send + 'async_trait>>where Self: Send + 'async_trait, 'life0: 'async_trait,
fn get_active_model(&self) -> AppResult<Self::ActiveModel>
Auto Trait Implementations§
impl RefUnwindSafe for Question
impl Send for Question
impl Sync for Question
impl Unpin for Question
impl UnwindSafe for Question
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more