Struct zookeeper::Acl

source ·
pub struct Acl {
    pub perms: Permission,
    pub scheme: String,
    pub id: String,
}
Expand description

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§

Create a new ACL with the given permissions, scheme, and id.

This ACL gives the creators authentication id’s all permissions.

This is a completely open ACL.

This ACL gives the world the ability to read.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Formats the value using the given formatter. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
Converts the given value to a String. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.