Struct zookeeper::Acl [−][src]
An access control list.
In general, the ACL system is similar to UNIX file access permissions, where znodes act as
files. Unlike UNIX, each znode can have any number of ACLs to correspond with the potentially
limitless (and pluggable) authentication schemes. A more surprising difference is that ACLs are
not recursive: If /path
is only readable by a single user, but /path/sub
is world-readable,
then anyone will be able to read /path/sub
.
See the ZooKeeper Programmer's Guide for more information.
Fields
perms: Permission
The permissions associated with this ACL.
scheme: String
The authentication scheme this list is used for. The most common scheme is "auth"
, which
allows any authenticated user to do anything (see creator_all
).
id: String
The ID of the user under the scheme
. For example, with the "ip"
scheme
, this is an IP
address or CIDR netmask.
Implementations
impl Acl
[src]
pub fn new<T, U>(permissions: Permission, scheme: T, id: U) -> Acl where
T: ToString,
U: ToString,
[src]
T: ToString,
U: ToString,
Create a new ACL with the given permissions
, scheme
, and id
.
pub fn creator_all() -> &'static Vec<Acl>ⓘ
[src]
This ACL gives the creators authentication id's all permissions.
pub fn open_unsafe() -> &'static Vec<Acl>ⓘ
[src]
This is a completely open ACL.
pub fn read_unsafe() -> &'static Vec<Acl>ⓘ
[src]
This ACL gives the world the ability to read.
Trait Implementations
impl Clone for Acl
[src]
impl Debug for Acl
[src]
impl Display for Acl
[src]
impl PartialEq<Acl> for Acl
[src]
impl StructuralPartialEq for Acl
[src]
Auto Trait Implementations
impl RefUnwindSafe for Acl
[src]
impl Send for Acl
[src]
impl Sync for Acl
[src]
impl Unpin for Acl
[src]
impl UnwindSafe for Acl
[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> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
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>,