Struct mysql::consts::CapabilityFlags [−]
pub struct CapabilityFlags { /* fields omitted */ }
Client capability flags
Methods
impl CapabilityFlags
impl CapabilityFlags
pub const CLIENT_LONG_PASSWORD: CapabilityFlags
CLIENT_LONG_PASSWORD: CapabilityFlags = CapabilityFlags{bits: 1,}
Use the improved version of Old Password Authentication. Assumed to be set since 4.1.1.
pub const CLIENT_FOUND_ROWS: CapabilityFlags
CLIENT_FOUND_ROWS: CapabilityFlags = CapabilityFlags{bits: 2,}
Send found rows instead of affected rows in EOF_Packet.
pub const CLIENT_LONG_FLAG: CapabilityFlags
CLIENT_LONG_FLAG: CapabilityFlags = CapabilityFlags{bits: 4,}
Get all column flags. Longer flags in Protocol::ColumnDefinition320.
Server
Supports longer flags.
Client
Expects longer flags.
pub const CLIENT_CONNECT_WITH_DB: CapabilityFlags
CLIENT_CONNECT_WITH_DB: CapabilityFlags = CapabilityFlags{bits: 8,}
Database (schema) name can be specified on connect in Handshake Response Packet.
Server
Supports schema-name in Handshake Response Packet.
Client
Handshake Response Packet contains a schema-name.
pub const CLIENT_NO_SCHEMA: CapabilityFlags
CLIENT_NO_SCHEMA: CapabilityFlags = CapabilityFlags{bits: 16,}
Don't allow database.table.column.
pub const CLIENT_COMPRESS: CapabilityFlags
CLIENT_COMPRESS: CapabilityFlags = CapabilityFlags{bits: 32,}
Compression protocol supported.
Server
Supports compression.
Client
Switches to Compression compressed protocol after successful authentication.
pub const CLIENT_ODBC: CapabilityFlags
CLIENT_ODBC: CapabilityFlags = CapabilityFlags{bits: 64,}
Special handling of ODBC behavior.
pub const CLIENT_LOCAL_FILES: CapabilityFlags
CLIENT_LOCAL_FILES: CapabilityFlags = CapabilityFlags{bits: 128,}
Can use LOAD DATA LOCAL.
Server
Enables the LOCAL INFILE request of LOAD DATA|XML.
Client
Will handle LOCAL INFILE request.
pub const CLIENT_IGNORE_SPACE: CapabilityFlags
CLIENT_IGNORE_SPACE: CapabilityFlags = CapabilityFlags{bits: 256,}
Ignore spaces before '('.
Server
Parser can ignore spaces before '('.
Client
Let the parser ignore spaces before '('.
pub const CLIENT_PROTOCOL_41: CapabilityFlags
CLIENT_PROTOCOL_41: CapabilityFlags = CapabilityFlags{bits: 512,}
pub const CLIENT_INTERACTIVE: CapabilityFlags
CLIENT_INTERACTIVE: CapabilityFlags = CapabilityFlags{bits: 1024,}
This is an interactive client. Use System_variables::net_wait_timeout versus System_variables::net_interactive_timeout.
Server
Supports interactive and noninteractive clients.
Client
Client is interactive.
pub const CLIENT_SSL: CapabilityFlags
CLIENT_SSL: CapabilityFlags = CapabilityFlags{bits: 2048,}
Use SSL encryption for the session.
Server
Supports SSL
Client
Switch to SSL after sending the capability-flags.
pub const CLIENT_IGNORE_SIGPIPE: CapabilityFlags
CLIENT_IGNORE_SIGPIPE: CapabilityFlags = CapabilityFlags{bits: 4096,}
Client only flag. Not used.
Client
Do not issue SIGPIPE if network failures occur (libmysqlclient only).
pub const CLIENT_TRANSACTIONS: CapabilityFlags
CLIENT_TRANSACTIONS: CapabilityFlags = CapabilityFlags{bits: 8192,}
Client knows about transactions.
Server
Can send status flags in OK_Packet / EOF_Packet.
Client
Expects status flags in OK_Packet / EOF_Packet.
Note
This flag is optional in 3.23, but always set by the server since 4.0.
pub const CLIENT_RESERVED: CapabilityFlags
CLIENT_RESERVED: CapabilityFlags = CapabilityFlags{bits: 16384,}
pub const CLIENT_SECURE_CONNECTION: CapabilityFlags
CLIENT_SECURE_CONNECTION: CapabilityFlags = CapabilityFlags{bits: 32768,}
pub const CLIENT_MULTI_STATEMENTS: CapabilityFlags
CLIENT_MULTI_STATEMENTS: CapabilityFlags = CapabilityFlags{bits: 65536,}
Enable/disable multi-stmt support. Also sets CLIENT_MULTI_RESULTS. Currently not checked anywhere.
Server
Can handle multiple statements per COM_QUERY and COM_STMT_PREPARE.
Client
May send multiple statements per COM_QUERY and COM_STMT_PREPARE.
pub const CLIENT_MULTI_RESULTS: CapabilityFlags
CLIENT_MULTI_RESULTS: CapabilityFlags = CapabilityFlags{bits: 131072,}
Enable/disable multi-results.
Server
Can send multiple resultsets for COM_QUERY. Error if the server needs to send them and client does not support them.
Client
Can handle multiple resultsets for COM_QUERY.
Requires
CLIENT_PROTOCOL_41
pub const CLIENT_PS_MULTI_RESULTS: CapabilityFlags
CLIENT_PS_MULTI_RESULTS: CapabilityFlags = CapabilityFlags{bits: 262144,}
Multi-results and OUT parameters in PS-protocol.
Server
Can send multiple resultsets for COM_STMT_EXECUTE.
Client
Can handle multiple resultsets for COM_STMT_EXECUTE.
Requires
CLIENT_PROTOCOL_41
pub const CLIENT_PLUGIN_AUTH: CapabilityFlags
CLIENT_PLUGIN_AUTH: CapabilityFlags = CapabilityFlags{bits: 524288,}
Client supports plugin authentication.
Server
Sends extra data in Initial Handshake Packet and supports the pluggable authentication protocol.
Client
Supports authentication plugins.
Requires
CLIENT_PROTOCOL_41
pub const CLIENT_CONNECT_ATTRS: CapabilityFlags
CLIENT_CONNECT_ATTRS: CapabilityFlags = CapabilityFlags{bits: 1048576,}
Client supports connection attributes.
Server
Permits connection attributes in Protocol::HandshakeResponse41.
Client
Sends connection attributes in Protocol::HandshakeResponse41.
pub const CLIENT_PLUGIN_AUTH_LENENC_CLIENT_DATA: CapabilityFlags
CLIENT_PLUGIN_AUTH_LENENC_CLIENT_DATA: CapabilityFlags = CapabilityFlags{bits: 2097152,}
Enable authentication response packet to be larger than 255 bytes. When the ability to change default plugin require that the initial password field in the Protocol::HandshakeResponse41 paclet can be of arbitrary size. However, the 4.1 client-server protocol limits the length of the auth-data-field sent from client to server to 255 bytes. The solution is to change the type of the field to a true length encoded string and indicate the protocol change with this client capability flag.
Server
Understands length-encoded integer for auth response data in Protocol::HandshakeResponse41.
Client
Length of auth response data in Protocol::HandshakeResponse41 is a length-encoded integer.
Note
The flag was introduced in 5.6.6, but had the wrong value.
pub const CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS: CapabilityFlags
CLIENT_CAN_HANDLE_EXPIRED_PASSWORDS: CapabilityFlags = CapabilityFlags{bits: 4194304,}
Don't close the connection for a user account with expired password.
Server
Announces support for expired password extension.
Client
Can handle expired passwords.
pub const CLIENT_SESSION_TRACK: CapabilityFlags
CLIENT_SESSION_TRACK: CapabilityFlags = CapabilityFlags{bits: 8388608,}
Capable of handling server state change information. Its a hint to the server to include the state change information in OK_Packet.
Server
Can set SERVER_SESSION_STATE_CHANGED in the SERVER_STATUS_flags_enum and send Session State Information in a OK_Packet.
Client
Expects the server to send Session State Information in a OK_Packet.
pub const CLIENT_DEPRECATE_EOF: CapabilityFlags
CLIENT_DEPRECATE_EOF: CapabilityFlags = CapabilityFlags{bits: 16777216,}
Client no longer needs EOF_Packet and will use OK_Packet instead.
Server
Can send OK after a Text Resultset.
Client
Expects an OK_Packet (instead of EOF_Packet) after the resultset rows of a Text Resultset.
Background
To support CLIENT_SESSION_TRACK, additional information must be sent after all successful commands. Although the OK_Packet is extensible, the EOF_Packet is not due to the overlap of its bytes with the content of the Text Resultset Row.
Therefore, the EOF_Packet in the Text Resultset is replaced with an OK_Packet. EOF_Packet is deprecated as of MySQL 5.7.5.
pub const CLIENT_PROGRESS_OBSOLETE: CapabilityFlags
CLIENT_PROGRESS_OBSOLETE: CapabilityFlags = CapabilityFlags{bits: 536870912,}
Client or server supports progress reports within error packet.
pub const CLIENT_SSL_VERIFY_SERVER_CERT: CapabilityFlags
CLIENT_SSL_VERIFY_SERVER_CERT: CapabilityFlags = CapabilityFlags{bits: 1073741824,}
Verify server certificate. Client only flag.
Deprecated in favor of –ssl-mode.
pub const CLIENT_REMEMBER_OPTIONS: CapabilityFlags
CLIENT_REMEMBER_OPTIONS: CapabilityFlags = CapabilityFlags{bits: 2147483648,}
Don't reset the options after an unsuccessful connect. Client only flag.
pub fn empty() -> CapabilityFlags
pub fn empty() -> CapabilityFlags
Returns an empty set of flags.
pub fn all() -> CapabilityFlags
pub fn all() -> CapabilityFlags
Returns the set containing all flags.
pub fn bits(&self) -> u32
pub fn bits(&self) -> u32
Returns the raw value of the flags currently stored.
pub fn from_bits(bits: u32) -> Option<CapabilityFlags>
pub fn from_bits(bits: u32) -> Option<CapabilityFlags>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
pub fn from_bits_truncate(bits: u32) -> CapabilityFlags
pub fn from_bits_truncate(bits: u32) -> CapabilityFlags
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
pub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Returns true
if no flags are currently stored.
pub fn is_all(&self) -> bool
pub fn is_all(&self) -> bool
Returns true
if all flags are currently set.
pub fn intersects(&self, other: CapabilityFlags) -> bool
pub fn intersects(&self, other: CapabilityFlags) -> bool
Returns true
if there are flags common to both self
and other
.
pub fn contains(&self, other: CapabilityFlags) -> bool
pub fn contains(&self, other: CapabilityFlags) -> bool
Returns true
all of the flags in other
are contained within self
.
pub fn insert(&mut self, other: CapabilityFlags)
pub fn insert(&mut self, other: CapabilityFlags)
Inserts the specified flags in-place.
pub fn remove(&mut self, other: CapabilityFlags)
pub fn remove(&mut self, other: CapabilityFlags)
Removes the specified flags in-place.
pub fn toggle(&mut self, other: CapabilityFlags)
pub fn toggle(&mut self, other: CapabilityFlags)
Toggles the specified flags in-place.
pub fn set(&mut self, other: CapabilityFlags, value: bool)
pub fn set(&mut self, other: CapabilityFlags, value: bool)
Inserts or removes the specified flags depending on the passed value.
Trait Implementations
impl LowerHex for CapabilityFlags
impl LowerHex for CapabilityFlags
impl BitAnd<CapabilityFlags> for CapabilityFlags
impl BitAnd<CapabilityFlags> for CapabilityFlags
type Output = CapabilityFlags
The resulting type after applying the &
operator.
fn bitand(self, other: CapabilityFlags) -> CapabilityFlags
fn bitand(self, other: CapabilityFlags) -> CapabilityFlags
Returns the intersection between the two sets of flags.
impl PartialOrd<CapabilityFlags> for CapabilityFlags
impl PartialOrd<CapabilityFlags> for CapabilityFlags
fn partial_cmp(&self, other: &CapabilityFlags) -> Option<Ordering>
fn partial_cmp(&self, other: &CapabilityFlags) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &CapabilityFlags) -> bool
fn lt(&self, other: &CapabilityFlags) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &CapabilityFlags) -> bool
fn le(&self, other: &CapabilityFlags) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &CapabilityFlags) -> bool
fn gt(&self, other: &CapabilityFlags) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &CapabilityFlags) -> bool
fn ge(&self, other: &CapabilityFlags) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Extend<CapabilityFlags> for CapabilityFlags
impl Extend<CapabilityFlags> for CapabilityFlags
fn extend<T>(&mut self, iterator: T) where
T: IntoIterator<Item = CapabilityFlags>,
fn extend<T>(&mut self, iterator: T) where
T: IntoIterator<Item = CapabilityFlags>,
Extends a collection with the contents of an iterator. Read more
impl Hash for CapabilityFlags
impl Hash for CapabilityFlags
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Sub<CapabilityFlags> for CapabilityFlags
impl Sub<CapabilityFlags> for CapabilityFlags
type Output = CapabilityFlags
The resulting type after applying the -
operator.
fn sub(self, other: CapabilityFlags) -> CapabilityFlags
fn sub(self, other: CapabilityFlags) -> CapabilityFlags
Returns the set difference of the two sets of flags.
impl Clone for CapabilityFlags
impl Clone for CapabilityFlags
fn clone(&self) -> CapabilityFlags
fn clone(&self) -> CapabilityFlags
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for CapabilityFlags
impl Debug for CapabilityFlags
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter. Read more
impl Ord for CapabilityFlags
impl Ord for CapabilityFlags
fn cmp(&self, other: &CapabilityFlags) -> Ordering
fn cmp(&self, other: &CapabilityFlags) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl Binary for CapabilityFlags
impl Binary for CapabilityFlags
impl Octal for CapabilityFlags
impl Octal for CapabilityFlags
impl UpperHex for CapabilityFlags
impl UpperHex for CapabilityFlags
impl BitOr<CapabilityFlags> for CapabilityFlags
impl BitOr<CapabilityFlags> for CapabilityFlags
type Output = CapabilityFlags
The resulting type after applying the |
operator.
fn bitor(self, other: CapabilityFlags) -> CapabilityFlags
fn bitor(self, other: CapabilityFlags) -> CapabilityFlags
Returns the union of the two sets of flags.
impl FromIterator<CapabilityFlags> for CapabilityFlags
impl FromIterator<CapabilityFlags> for CapabilityFlags
fn from_iter<T>(iterator: T) -> CapabilityFlags where
T: IntoIterator<Item = CapabilityFlags>,
fn from_iter<T>(iterator: T) -> CapabilityFlags where
T: IntoIterator<Item = CapabilityFlags>,
Creates a value from an iterator. Read more
impl SubAssign<CapabilityFlags> for CapabilityFlags
impl SubAssign<CapabilityFlags> for CapabilityFlags
fn sub_assign(&mut self, other: CapabilityFlags)
fn sub_assign(&mut self, other: CapabilityFlags)
Disables all flags enabled in the set.
impl BitXor<CapabilityFlags> for CapabilityFlags
impl BitXor<CapabilityFlags> for CapabilityFlags
type Output = CapabilityFlags
The resulting type after applying the ^
operator.
fn bitxor(self, other: CapabilityFlags) -> CapabilityFlags
fn bitxor(self, other: CapabilityFlags) -> CapabilityFlags
Returns the left flags, but with all the right flags toggled.
impl Copy for CapabilityFlags
impl Copy for CapabilityFlags
impl BitAndAssign<CapabilityFlags> for CapabilityFlags
impl BitAndAssign<CapabilityFlags> for CapabilityFlags
fn bitand_assign(&mut self, other: CapabilityFlags)
fn bitand_assign(&mut self, other: CapabilityFlags)
Disables all flags disabled in the set.
impl Eq for CapabilityFlags
impl Eq for CapabilityFlags
impl PartialEq<CapabilityFlags> for CapabilityFlags
impl PartialEq<CapabilityFlags> for CapabilityFlags
fn eq(&self, other: &CapabilityFlags) -> bool
fn eq(&self, other: &CapabilityFlags) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &CapabilityFlags) -> bool
fn ne(&self, other: &CapabilityFlags) -> bool
This method tests for !=
.
impl BitXorAssign<CapabilityFlags> for CapabilityFlags
impl BitXorAssign<CapabilityFlags> for CapabilityFlags
fn bitxor_assign(&mut self, other: CapabilityFlags)
fn bitxor_assign(&mut self, other: CapabilityFlags)
Toggles the set of flags.
impl Not for CapabilityFlags
impl Not for CapabilityFlags
type Output = CapabilityFlags
The resulting type after applying the !
operator.
fn not(self) -> CapabilityFlags
fn not(self) -> CapabilityFlags
Returns the complement of this set of flags.
impl BitOrAssign<CapabilityFlags> for CapabilityFlags
impl BitOrAssign<CapabilityFlags> for CapabilityFlags
fn bitor_assign(&mut self, other: CapabilityFlags)
fn bitor_assign(&mut self, other: CapabilityFlags)
Adds the set of flags.
Auto Trait Implementations
impl Send for CapabilityFlags
impl Send for CapabilityFlags
impl Sync for CapabilityFlags
impl Sync for CapabilityFlags