Struct ndk::configuration::Configuration[][src]

pub struct Configuration { /* fields omitted */ }
Expand description

A native AConfiguration *.

This stores information about configuration. See the NDK docs

Implementations

Construct a Configuration from a pointer.

Safety

By calling this function, you assert that it is a valid pointer to a native AConfiguration, and give ownership of it to the Configuration instance.

Create a new Configuration, with the same contents as the AConfiguration referenced by the pointer.

This is useful if you have a pointer, but not ownership of it.

Safety

By calling this function, you assert that it is a valid pointer to a native AConfiguration.

The pointer to the native AConfiguration. Keep in mind that the Configuration object still has ownership, and will free it when dropped.

Create a new Configuration, with none of the values set.

dest.copy(&src) copies the contents of src to dest

Information about what fields differ between the two configurations

Returns false if anything in self conflicts with requested

Returns the country code. It will always be two letters.

Returns the screen density in dpi.

On some devices it can return values outside of the density enum.

Returns the keyboard type.

Returns keyboard visibility/availability.

Returns the language, as a String of two characters, if a language is set

Returns the layout direction

Returns the mobile country code.

Returns the mobile network code, if one is defined

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

Executes the destructor for this type. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

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

Look up the concrete type from the JVM.

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. 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.