Struct cyfs_lib::RequestSourceInfo
source · [−]pub struct RequestSourceInfo {
pub protocol: RequestProtocol,
pub zone: DeviceZoneInfo,
pub dec: ObjectId,
pub verified: Option<ObjectId>,
}
Fields
protocol: RequestProtocol
zone: DeviceZoneInfo
dec: ObjectId
verified: Option<ObjectId>
Implementations
sourceimpl RequestSourceInfo
impl RequestSourceInfo
pub fn new_local_system() -> Self
pub fn new_local_anonymouse() -> Self
pub fn new_local_dec(dec: Option<ObjectId>) -> Self
pub fn new_zone_dec(dec: Option<ObjectId>) -> Self
pub fn new_friend_zone_dec(dec: Option<ObjectId>) -> Self
pub fn new_other_zone_dec(dec: Option<ObjectId>) -> Self
pub fn protocol(self, protocol: RequestProtocol) -> Self
pub fn set_dec(&mut self, dec_id: ObjectId)
pub fn dec(self, dec_id: ObjectId) -> Self
pub fn is_system_dec(&self) -> bool
pub fn is_anonymous_dec_app(&self) -> bool
pub fn get_opt_dec(&self) -> Option<&ObjectId>
pub fn set_verified(&mut self, target_dec_id: ObjectId)
pub fn is_verified(&self, target_dec_id: &ObjectId) -> bool
pub fn check_target_dec_permission(
&self,
op_target_dec: &Option<ObjectId>
) -> bool
pub fn is_current_device(&self) -> bool
pub fn is_current_zone(&self) -> bool
pub fn compare_zone_category(&self, zone_category: DeviceZoneCategory) -> bool
pub fn compare_zone(&self, zone: &ObjectId) -> bool
pub fn compare_dec(&self, dec: &ObjectId) -> bool
pub fn mask(
&self,
dec_id: &ObjectId,
permissions: impl Into<AccessPermissions>
) -> u32
pub fn owner_dec_mask(&self, permissions: impl Into<AccessPermissions>) -> u32
pub fn other_dec_mask(&self, permissions: impl Into<AccessPermissions>) -> u32
pub fn check_current_zone(&self, service: &str) -> BuckyResult<()>
pub fn check_current_device(&self, service: &str) -> BuckyResult<()>
Trait Implementations
sourceimpl Clone for RequestSourceInfo
impl Clone for RequestSourceInfo
sourcefn clone(&self) -> RequestSourceInfo
fn clone(&self) -> RequestSourceInfo
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for RequestSourceInfo
impl Debug for RequestSourceInfo
sourceimpl Display for RequestSourceInfo
impl Display for RequestSourceInfo
sourceimpl Into<OpEnvSourceInfo> for RequestSourceInfo
impl Into<OpEnvSourceInfo> for RequestSourceInfo
sourcefn into(self) -> OpEnvSourceInfo
fn into(self) -> OpEnvSourceInfo
Converts this type into the (usually inferred) input type.
sourceimpl JsonCodec<RequestSourceInfo> for RequestSourceInfo
impl JsonCodec<RequestSourceInfo> for RequestSourceInfo
fn encode_json(&self) -> Map<String, Value>
fn decode_json(obj: &Map<String, Value>) -> BuckyResult<Self>
fn encode_string(&self) -> String
fn decode_string(value: &str) -> Result<T, BuckyError>
fn decode_value(value: &Value) -> Result<T, BuckyError>
fn encode_value(&self) -> Value
Auto Trait Implementations
impl RefUnwindSafe for RequestSourceInfo
impl Send for RequestSourceInfo
impl Sync for RequestSourceInfo
impl Unpin for RequestSourceInfo
impl UnwindSafe for RequestSourceInfo
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more