pub struct WechatConfig {
pub app_id: String,
pub offical_appid: String,
pub secret: String,
pub token: String,
pub platform: PlatformType,
pub mch_id: String,
pub private_key: String,
pub certificate: String,
pub secret_key: String,
pub notify_url: String,
pub refund_notify_url: String,
}Expand description
微信sdk配置
Fields§
§app_id: String§offical_appid: String§secret: String§token: String§platform: PlatformType§mch_id: String§private_key: String§certificate: String§secret_key: String§notify_url: String§refund_notify_url: StringImplementations§
Source§impl WechatConfig
impl WechatConfig
Sourcepub fn load(params: Value) -> WechatResult<WechatConfig>
pub fn load(params: Value) -> WechatResult<WechatConfig>
设置配置
Sourcepub fn load_yaml(conf_path: &str) -> WechatResult<WechatConfig>
pub fn load_yaml(conf_path: &str) -> WechatResult<WechatConfig>
加载yml配置文件
Trait Implementations§
Source§impl Clone for WechatConfig
impl Clone for WechatConfig
Source§fn clone(&self) -> WechatConfig
fn clone(&self) -> WechatConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for WechatConfig
impl Debug for WechatConfig
Auto Trait Implementations§
impl Freeze for WechatConfig
impl RefUnwindSafe for WechatConfig
impl Send for WechatConfig
impl Sync for WechatConfig
impl Unpin for WechatConfig
impl UnwindSafe for WechatConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more