QueryConsentRecord

Trait QueryConsentRecord 

Source
pub trait QueryConsentRecord {
    // Required methods
    fn get_consent_record(
        &self,
        entity: String,
        entity_type: ConsentType,
    ) -> Result<Option<StoredConsentRecord>, ConnectionError>;
    fn consent_records(
        &self,
    ) -> Result<Vec<StoredConsentRecord>, ConnectionError>;
    fn consent_records_paged(
        &self,
        limit: i64,
        offset: i64,
    ) -> Result<Vec<StoredConsentRecord>, ConnectionError>;
    fn insert_newer_consent_record(
        &self,
        record: StoredConsentRecord,
    ) -> Result<bool, ConnectionError>;
    fn insert_or_replace_consent_records(
        &self,
        records: &[StoredConsentRecord],
    ) -> Result<Vec<StoredConsentRecord>, ConnectionError>;
    fn maybe_insert_consent_record_return_existing(
        &self,
        record: &StoredConsentRecord,
    ) -> Result<Option<StoredConsentRecord>, ConnectionError>;
    fn find_consent_by_dm_id(
        &self,
        dm_id: &str,
    ) -> Result<Vec<StoredConsentRecord>, ConnectionError>;
}

Required Methods§

Returns the consent_records for the given entity up

Source

fn consent_records(&self) -> Result<Vec<StoredConsentRecord>, ConnectionError>

Source

fn consent_records_paged( &self, limit: i64, offset: i64, ) -> Result<Vec<StoredConsentRecord>, ConnectionError>

Returns true if newer

Insert consent_records, and replace existing entries, returns records that are new or changed

Implementations on Foreign Types§

Source§

impl<T: QueryConsentRecord + ?Sized> QueryConsentRecord for &T

Implementors§