[−][src]Struct refinery_core::config::Config
Implementations
impl Config[src]
pub fn new(db_type: ConfigDbType) -> Config[src]
create a new config instance
pub fn from_env_var(name: &str) -> Result<Config, Error>[src]
create a new Config instance from an environment variable that contains a URL
pub fn from_file_location<T: AsRef<Path>>(location: T) -> Result<Config, Error>[src]
create a new Config instance from a config file located on the file system
pub fn db_type(&self) -> ConfigDbType[src]
pub fn set_db_user(self, db_user: &str) -> Config[src]
pub fn set_db_pass(self, db_pass: &str) -> Config[src]
pub fn set_db_path(self, db_path: &str) -> Config[src]
pub fn set_db_host(self, db_host: &str) -> Config[src]
pub fn set_db_port(self, db_port: &str) -> Config[src]
pub fn set_db_name(self, db_name: &str) -> Config[src]
Trait Implementations
impl AsyncMigrate for Config[src]
pub fn get_last_applied_migration<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<Option<Migration>, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait, [src]
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<Option<Migration>, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
pub fn get_applied_migrations<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<Vec<Migration>, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait, [src]
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<Vec<Migration>, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
pub fn migrate<'life0, 'life1, 'async_trait>(
&'life0 mut self,
migrations: &'life1 [Migration],
abort_divergent: bool,
abort_missing: bool,
grouped: bool,
target: Target
) -> Pin<Box<dyn Future<Output = Result<Report, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait, [src]
&'life0 mut self,
migrations: &'life1 [Migration],
abort_divergent: bool,
abort_missing: bool,
grouped: bool,
target: Target
) -> Pin<Box<dyn Future<Output = Result<Report, Error>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
impl Debug for Config[src]
impl<'de> Deserialize<'de> for Config[src]
pub fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>, [src]
__D: Deserializer<'de>,
impl FromStr for Config[src]
type Err = Error
The associated error which can be returned from parsing.
pub fn from_str(url_str: &str) -> Result<Config, Self::Err>[src]
create a new Config instance from a string that contains a URL
impl Migrate for Config[src]
pub fn get_last_applied_migration(&mut self) -> Result<Option<Migration>, Error>[src]
pub fn get_applied_migrations(&mut self) -> Result<Vec<Migration>, Error>[src]
pub fn migrate(
&mut self,
migrations: &[Migration],
abort_divergent: bool,
abort_missing: bool,
grouped: bool,
target: Target
) -> Result<Report, Error>[src]
&mut self,
migrations: &[Migration],
abort_divergent: bool,
abort_missing: bool,
grouped: bool,
target: Target
) -> Result<Report, Error>
impl Serialize for Config[src]
pub fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer, [src]
__S: Serializer,
impl TryFrom<Url> for Config[src]
Auto Trait Implementations
impl RefUnwindSafe for Config[src]
impl Send for Config[src]
impl Sync for Config[src]
impl Unpin for Config[src]
impl UnwindSafe for Config[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>, [src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,