# Print output for @column tags ?>
Developers

- Design
- Develop
- Distribute

Developer Console

## Most visited

## Recently visited

## Results for

Summary: Ctors | Methods | Inherited Methods

# IntFlagMapping

`public final class IntFlagMapping`
`extends Object` ``

java.lang.Object
↳ | android.view.inspector.IntFlagMapping

Maps the values of an `int` property to sets of string for properties that encode flags. An `InspectionCompanion` may provide an instance of this class to a `PropertyMapper` for flag values packed into primitive `int` properties. Each flag has a mask and a target value, for non-exclusive flags, the target can also be used as the mask. A given integer value is compared against each flag to find what flags are active for it by bitwise anding it with the mask and comparing the result against the target, that is, `(value & mask) == target`.

See also:

- `PropertyMapper.mapIntFlag(String, int, java.util.function.IntFunction)`

## Summary

### Public constructors
`IntFlagMapping()`

### Public methods
`void` | `add(int mask, int target, String name)` Add a mutually exclusive flag to the map.
`Set<String>` | `get(int value)` Get a set of the names of enabled flags for a given property value.

### Inherited methods
From class `java.lang.Object`
`Object` | `clone()` Creates and returns a copy of this object.
`boolean` | `equals(Object obj)` Indicates whether some other object is "equal to" this one.
`void` | `finalize()` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
`final Class<?>` | `getClass()` Returns the runtime class of this `Object`.
`int` | `hashCode()` Returns a hash code value for the object.
`final void` | `notify()` Wakes up a single thread that is waiting on this object's monitor.
`final void` | `notifyAll()` Wakes up all threads that are waiting on this object's monitor.
`String` | `toString()` Returns a string representation of the object.
`final void` | `wait(long timeout, int nanos)` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed.
`final void` | `wait(long timeout)` Causes the current thread to wait until either another thread invokes the `notify()` method or the `notifyAll()` method for this object, or a specified amount of time has elapsed.
`final void` | `wait()` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object.

## Public constructors

### IntFlagMapping

    public IntFlagMapping ()

## Public methods

### add

    public void add (int mask,
                    int target,
                    String name)

Add a mutually exclusive flag to the map.

Parameters
`mask` | `int`: The bit mask to compare to and with a value
`target` | `int`: The target value to compare the masked value with
`name` | `String`: The name of the flag to include if enabled This value cannot be `null`.

### get

    public Set<String> get (int value)

Get a set of the names of enabled flags for a given property value.

Parameters
`value` | `int`: The value of the property

Returns
`Set<String>` | The names of the enabled flags, empty if no flags enabled This value cannot be `null`.

Full name *
Email address *
Company / developer name
One of your Play Store app URLs *
Which best describes your business:*
Apps
Games
Apps & Games
*
*