pub struct PolicyDecision {
pub intent_id: String,
pub approved: bool,
pub rejection_reason: Option<DenialReason>,
pub action_denials: Vec<DenialReason>,
pub approved_actions: Vec<AuthorizedAction>,
}Expand description
策略校验结果
Fields§
§intent_id: String原始意图 ID
approved: bool原始意图是否通过校验
rejection_reason: Option<DenialReason>被拒绝的原因 (如有)
action_denials: Vec<DenialReason>在意图层通过但被动作层规则拦截的具体原因序列 (同一意图内可有多条;顺序对应被丢弃的 SuggestedAction 顺序)
approved_actions: Vec<AuthorizedAction>通过校验的动作列表 (可能少于原始列表)
Trait Implementations§
Source§impl Clone for PolicyDecision
impl Clone for PolicyDecision
Source§fn clone(&self) -> PolicyDecision
fn clone(&self) -> PolicyDecision
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 moreAuto Trait Implementations§
impl Freeze for PolicyDecision
impl RefUnwindSafe for PolicyDecision
impl Send for PolicyDecision
impl Sync for PolicyDecision
impl Unpin for PolicyDecision
impl UnsafeUnpin for PolicyDecision
impl UnwindSafe for PolicyDecision
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