Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Methods](https://developer.android.com/reference/android/content/res/Resources.Theme#pubmethods) \| [Inherited Methods](https://developer.android.com/reference/android/content/res/Resources.Theme#inhmethods)

# Resources.Theme

*** ** * ** ***


`
public

final

class
Resources.Theme
`


`

extends https://developer.android.com/reference/java/lang/Object


`

`


`

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | android.content.res.Resources.Theme |

<br />

*** ** * ** ***

This class holds the current attribute values for a particular theme.
In other words, a Theme is a set of values for resource attributes;
these are used in conjunction with `https://developer.android.com/reference/android/content/res/TypedArray`
to resolve the final value for an attribute.

The Theme's attributes come into play in two ways: (1) a styled
attribute can explicit reference a value in the theme through the
"?themeAttribute" syntax; (2) if no value has been defined for a
particular styled attribute, as a last resort we will try to find that
attribute's value in the Theme.

You will normally use the `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)` APIs to
retrieve XML attributes with style and theme information applied.

## Summary

| ### Public methods ||
|---|---|
| ` void` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#applyStyle(int,%20boolean)(int resId, boolean force) ` Place new attribute values into the theme. |
| ` void` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#dump(int,%20java.lang.String,%20java.lang.String)(int priority, https://developer.android.com/reference/java/lang/String tag, https://developer.android.com/reference/java/lang/String prefix) ` Print contents of this theme out to the log. |
| ` boolean` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object o) ` Indicates whether some other object is "equal to" this one. |
| ` int[]` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#getAttributeResolutionStack(int,%20int,%20int)(int defStyleAttr, int defStyleRes, int explicitStyleRes) ` Returns the ordered list of resource ID that are considered when resolving attribute values when making an equivalent call to `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)` . |
| ` int` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#getChangingConfigurations()() ` Returns a bit mask of configuration changes that will impact this theme (and thus require completely reloading it). |
| ` https://developer.android.com/reference/android/graphics/drawable/Drawable` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#getDrawable(int)(int id) ` Return a drawable object associated with a particular resource ID and styled for the Theme. |
| ` int` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#getExplicitStyle(android.util.AttributeSet)(https://developer.android.com/reference/android/util/AttributeSet set) ` Returns the resource ID for the style specified using `style="..."` in the `https://developer.android.com/reference/android/util/AttributeSet`'s backing XML element or `https://developer.android.com/reference/android/content/res/Resources#ID_NULL` otherwise if not specified or otherwise not applicable. |
| ` https://developer.android.com/reference/android/content/res/Resources` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#getResources()() ` Returns the resources to which this theme belongs. |
| ` int` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#hashCode()() ` Returns a hash code value for the object. |
| ` https://developer.android.com/reference/android/content/res/TypedArray` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)(https://developer.android.com/reference/android/util/AttributeSet set, int[] attrs, int defStyleAttr, int defStyleRes) ` Return a TypedArray holding the attribute values in <var translate="no">set</var> that are listed in <var translate="no">attrs</var>. |
| ` https://developer.android.com/reference/android/content/res/TypedArray` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int[])(int[] attrs) ` Return a TypedArray holding the values defined by <var translate="no">Theme</var> which are listed in <var translate="no">attrs</var>. |
| ` https://developer.android.com/reference/android/content/res/TypedArray` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int,%20int[])(int resId, int[] attrs) ` Return a TypedArray holding the values defined by the style resource <var translate="no">resid</var> which are listed in <var translate="no">attrs</var>. |
| ` void` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#rebase()() ` Rebases the theme against the parent Resource object's current configuration by re-applying the styles passed to `https://developer.android.com/reference/android/content/res/Resources.Theme#applyStyle(int,%20boolean)`. |
| ` boolean` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#resolveAttribute(int,%20android.util.TypedValue,%20boolean)(int resid, https://developer.android.com/reference/android/util/TypedValue outValue, boolean resolveRefs) ` Retrieve the value of an attribute in the Theme. |
| ` void` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#setTo(android.content.res.Resources.Theme)(https://developer.android.com/reference/android/content/res/Resources.Theme other) ` Set this theme to hold the same contents as the theme <var translate="no">other</var>. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/android/content/res/Resources.Theme#toString()() ` Returns a string representation of the object. |

| ### Inherited methods |
|---|---|
| From class ` https://developer.android.com/reference/java/lang/Object ` |---|---| | ` https://developer.android.com/reference/java/lang/Object` | ` https://developer.android.com/reference/java/lang/Object#clone()() ` Creates and returns a copy of this object. | | ` boolean` | ` https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object obj) ` Indicates whether some other object is "equal to" this one. | | ` void` | ` https://developer.android.com/reference/java/lang/Object#finalize()() ` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. | | ` final https://developer.android.com/reference/java/lang/Class<?>` | ` https://developer.android.com/reference/java/lang/Object#getClass()() ` Returns the runtime class of this `Object`. | | ` int` | ` https://developer.android.com/reference/java/lang/Object#hashCode()() ` Returns a hash code value for the object. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#notify()() ` Wakes up a single thread that is waiting on this object's monitor. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#notifyAll()() ` Wakes up all threads that are waiting on this object's monitor. | | ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/java/lang/Object#toString()() ` Returns a string representation of the object. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait(long,%20int)(long timeoutMillis, int nanos) ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait(long)(long timeoutMillis) ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed. | | ` final void` | ` https://developer.android.com/reference/java/lang/Object#wait()() ` Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*. | ||

## Public methods

### applyStyle

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public void applyStyle (int resId, 
                boolean force)
```

Place new attribute values into the theme. The style resource
specified by <var translate="no">resid</var> will be retrieved from this Theme's
resources, its values placed into the Theme object.

The semantics of this function depends on the <var translate="no">force</var>
argument: If false, only values that are not already defined in
the theme will be copied from the system resource; otherwise, if
any of the style's attributes are already defined in the theme, the
current values in the theme will be overwritten.

<br />

| Parameters ||
|---|---|
| `resId` | `int`: The resource ID of a style resource from which to obtain attribute values. <br /> |
| `force` | `boolean`: If true, values in the style resource will always be used in the theme; otherwise, they will only be used if not already defined in the theme. <br /> |

### dump

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public void dump (int priority, 
                String tag, 
                String prefix)
```

Print contents of this theme out to the log. For debugging only.

<br />

| Parameters ||
|---|---|
| `priority` | `int`: The log priority to use. <br /> |
| `tag` | `String`: The log tag to use. <br /> |
| `prefix` | `String`: Text to prefix each line printed. <br /> |

### equals

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public boolean equals (Object o)
```

Indicates whether some other object is "equal to" this one.


The `equals` method implements an equivalence relation
on non-null object references:

- It is *reflexive*: for any non-null reference value `x`, `x.equals(x)` should return `true`.
- It is *symmetric*: for any non-null reference values `x` and `y`, `x.equals(y)` should return `true` if and only if `y.equals(x)` returns `true`.
- It is *transitive*: for any non-null reference values `x`, `y`, and `z`, if `x.equals(y)` returns `true` and `y.equals(z)` returns `true`, then `x.equals(z)` should return `true`.
- It is *consistent*: for any non-null reference values `x` and `y`, multiple invocations of `x.equals(y)` consistently return `true` or consistently return `false`, provided no information used in `equals` comparisons on the objects is modified.
- For any non-null reference value `x`, `x.equals(null)` should return `false`.


An equivalence relation partitions the elements it operates on
into *equivalence classes*; all the members of an
equivalence class are equal to each other. Members of an
equivalence class are substitutable for each other, at least
for some purposes.

<br />

| Parameters ||
|---|---|
| `o` | `Object`: This value may be `null`. <br /> |

| Returns ||
|---|---|
| `boolean` | `true` if this object is the same as the obj argument; `false` otherwise. <br /> |

### getAttributeResolutionStack

Added in [API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public int[] getAttributeResolutionStack (int defStyleAttr, 
                int defStyleRes, 
                int explicitStyleRes)
```

Returns the ordered list of resource ID that are considered when resolving attribute
values when making an equivalent call to
`https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)` . The list will include
a set of explicit styles (`explicitStyleRes` and it will include the default styles
(`defStyleAttr` and `defStyleRes`).

<br />

| Parameters ||
|---|---|
| `defStyleAttr` | `int`: An attribute in the current theme that contains a reference to a style resource that supplies defaults values for the TypedArray. Can be 0 to not look for defaults. <br /> |
| `defStyleRes` | `int`: A resource identifier of a style resource that supplies default values for the TypedArray, used only if defStyleAttr is 0 or can not be found in the theme. Can be 0 to not look for defaults. <br /> |
| `explicitStyleRes` | `int`: A resource identifier of an explicit style resource. <br /> |

| Returns ||
|---|---|
| `int[]` | ordered list of resource ID that are considered when resolving attribute values. This value cannot be `null`. <br /> |

### getChangingConfigurations

Added in [API level 23](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public int getChangingConfigurations ()
```

Returns a bit mask of configuration changes that will impact this
theme (and thus require completely reloading it).

<br />

| Returns ||
|---|---|
| `int` | a bit mask of configuration changes, as defined by `https://developer.android.com/reference/android/content/pm/ActivityInfo` Value is either `0` or a combination of the following: - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_MCC` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_MNC` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_LOCALE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_TOUCHSCREEN` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_KEYBOARD` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_KEYBOARD_HIDDEN` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_NAVIGATION` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_ORIENTATION` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_SCREEN_LAYOUT` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_UI_MODE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_SCREEN_SIZE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_SMALLEST_SCREEN_SIZE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_DENSITY` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_LAYOUT_DIRECTION` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_COLOR_MODE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_FONT_SCALE` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_GRAMMATICAL_GENDER` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_FONT_WEIGHT_ADJUSTMENT` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_ASSETS_PATHS` - `https://developer.android.com/reference/android/content/pm/ActivityInfo#CONFIG_RESOURCES_UNUSED` |

**See also:**

- `https://developer.android.com/reference/android/content/pm/ActivityInfo`

### getDrawable

Added in [API level 21](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public Drawable getDrawable (int id)
```

Return a drawable object associated with a particular resource ID
and styled for the Theme.

<br />

| Parameters ||
|---|---|
| `id` | `int`: The desired resource identifier, as generated by the aapt tool. This integer encodes the package, type, and resource entry. The value 0 is an invalid identifier. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/graphics/drawable/Drawable` | Drawable An object that can be used to draw this resource. <br /> |

| Throws ||
|---|---|
| `https://developer.android.com/reference/android/content/res/Resources.NotFoundException` | Throws NotFoundException if the given ID does not exist. |

### getExplicitStyle

Added in [API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public int getExplicitStyle (AttributeSet set)
```

Returns the resource ID for the style specified using `style="..."` in the
`https://developer.android.com/reference/android/util/AttributeSet`'s backing XML element or `https://developer.android.com/reference/android/content/res/Resources#ID_NULL` otherwise if not
specified or otherwise not applicable.


Each `https://developer.android.com/reference/android/view/View` can have an explicit style specified in the layout file.
This style is used first during the `https://developer.android.com/reference/android/view/View` attribute resolution, then
if an attribute is not defined there the resource system looks at default style and theme
as fallbacks.

<br />

| Parameters ||
|---|---|
| `set` | `AttributeSet`: The base set of attribute values. This value may be `null`. <br /> |

| Returns ||
|---|---|
| `int` | The resource ID for the style specified using `style="..."` in the `https://developer.android.com/reference/android/util/AttributeSet`'s backing XML element or `https://developer.android.com/reference/android/content/res/Resources#ID_NULL` otherwise if not specified or otherwise not applicable. <br /> |

### getResources

Added in [API level 21](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public Resources getResources ()
```

Returns the resources to which this theme belongs.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/content/res/Resources` | Resources to which this theme belongs. <br /> |

### hashCode

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public int hashCode ()
```

Returns a hash code value for the object. This method is
supported for the benefit of hash tables such as those provided by
`https://developer.android.com/reference/java/util/HashMap`.


The general contract of `hashCode` is:

- Whenever it is invoked on the same object more than once during an execution of a Java application, the `hashCode` method must consistently return the same integer, provided no information used in `equals` comparisons on the object is modified. This integer need not remain consistent from one execution of an application to another execution of the same application.
- If two objects are equal according to the `https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)` method, then calling the `hashCode` method on each of the two objects must produce the same integer result.
- It is *not* required that if two objects are unequal according to the `https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)` method, then calling the `hashCode` method on each of the two objects must produce distinct integer results. However, the programmer should be aware that producing distinct integer results for unequal objects may improve the performance of hash tables.

<br />

<br />

| Returns ||
|---|---|
| `int` | a hash code value for this object. <br /> |

### obtainStyledAttributes

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public TypedArray obtainStyledAttributes (AttributeSet set, 
                int[] attrs, 
                int defStyleAttr, 
                int defStyleRes)
```

Return a TypedArray holding the attribute values in
<var translate="no">set</var>
that are listed in <var translate="no">attrs</var>. In addition, if the given
AttributeSet specifies a style class (through the "style" attribute),
that style will be applied on top of the base attributes it defines.

Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when you are done
with the array.

When determining the final value of a particular attribute, there
are four inputs that come into play:

1. Any attribute values in the given AttributeSet.
2. The style resource specified in the AttributeSet (named "style").
3. The default style specified by <var translate="no">defStyleAttr</var> and <var translate="no">defStyleRes</var>
4. The base values in this theme.

Each of these inputs is considered in-order, with the first listed
taking precedence over the following ones. In other words, if in the
AttributeSet you have supplied `<Button
textColor="#ff000000">`, then the button's text will
*always* be black, regardless of what is specified in any of
the styles.

<br />

| Parameters ||
|---|---|
| `set` | `AttributeSet`: The base set of attribute values. May be null. <br /> |
| `attrs` | `int`: The desired attributes to be retrieved. These attribute IDs must be sorted in ascending order. This value cannot be `null`. <br /> |
| `defStyleAttr` | `int`: An attribute in the current theme that contains a reference to a style resource that supplies defaults values for the TypedArray. Can be 0 to not look for defaults. <br /> |
| `defStyleRes` | `int`: A resource identifier of a style resource that supplies default values for the TypedArray, used only if defStyleAttr is 0 or can not be found in the theme. Can be 0 to not look for defaults. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/content/res/TypedArray` | Returns a TypedArray holding an array of the attribute values. Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when done with it. This value cannot be `null`. <br /> |

**See also:**

- `https://developer.android.com/reference/android/content/res/Resources#obtainAttributes(android.util.AttributeSet,%20int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int,%20int[])`

### obtainStyledAttributes

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public TypedArray obtainStyledAttributes (int[] attrs)
```

Return a TypedArray holding the values defined by
<var translate="no">Theme</var> which are listed in <var translate="no">attrs</var>.

Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when you are done
with the array.

<br />

| Parameters ||
|---|---|
| `attrs` | `int`: The desired attributes. These attribute IDs must be sorted in ascending order. This value cannot be `null`. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/content/res/TypedArray` | Returns a TypedArray holding an array of the attribute values. Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when done with it. This value cannot be `null`. <br /> |

| Throws ||
|---|---|
| `https://developer.android.com/reference/android/content/res/Resources.NotFoundException` | Throws NotFoundException if the given ID does not exist. |

**See also:**

- `https://developer.android.com/reference/android/content/res/Resources#obtainAttributes(android.util.AttributeSet,%20int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int,%20int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)`

### obtainStyledAttributes

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public TypedArray obtainStyledAttributes (int resId, 
                int[] attrs)
```

Return a TypedArray holding the values defined by the style
resource <var translate="no">resid</var> which are listed in <var translate="no">attrs</var>.

Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when you are done
with the array.

<br />

| Parameters ||
|---|---|
| `resId` | `int`: The desired style resource. <br /> |
| `attrs` | `int`: The desired attributes in the style. These attribute IDs must be sorted in ascending order. This value cannot be `null`. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/content/res/TypedArray` | Returns a TypedArray holding an array of the attribute values. Be sure to call `https://developer.android.com/reference/android/content/res/TypedArray#recycle()` when done with it. This value cannot be `null`. <br /> |

| Throws ||
|---|---|
| `https://developer.android.com/reference/android/content/res/Resources.NotFoundException` | Throws NotFoundException if the given ID does not exist. |

**See also:**

- `https://developer.android.com/reference/android/content/res/Resources#obtainAttributes(android.util.AttributeSet,%20int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(int[])`
- `https://developer.android.com/reference/android/content/res/Resources.Theme#obtainStyledAttributes(android.util.AttributeSet,%20int[],%20int,%20int)`

### rebase

Added in [API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public void rebase ()
```

Rebases the theme against the parent Resource object's current
configuration by re-applying the styles passed to
`https://developer.android.com/reference/android/content/res/Resources.Theme#applyStyle(int,%20boolean)`.

<br />

### resolveAttribute

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public boolean resolveAttribute (int resid, 
                TypedValue outValue, 
                boolean resolveRefs)
```

Retrieve the value of an attribute in the Theme. The contents of
<var translate="no">outValue</var> are ultimately filled in by
`https://developer.android.com/reference/android/content/res/Resources#getValue(int,%20android.util.TypedValue,%20boolean)`.

<br />

| Parameters ||
|---|---|
| `resid` | `int`: The resource identifier of the desired theme attribute. <br /> |
| `outValue` | `TypedValue`: Filled in with the ultimate resource value supplied by the attribute. <br /> |
| `resolveRefs` | `boolean`: If true, resource references will be walked; if false, <var translate="no">outValue</var> may be a TYPE_REFERENCE. In either case, it will never be a TYPE_ATTRIBUTE. <br /> |

| Returns ||
|---|---|
| `boolean` | boolean Returns true if the attribute was found and <var translate="no">outValue</var> is valid, else false. <br /> |

### setTo

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public void setTo (Resources.Theme other)
```

Set this theme to hold the same contents as the theme
<var translate="no">other</var>. If both of these themes are from the same
Resources object, they will be identical after this function
returns. If they are from different Resources, only the resources
they have in common will be set in this theme.

<br />

| Parameters ||
|---|---|
| `other` | `Resources.Theme`: The existing Theme to copy from. <br /> |

### toString

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String toString ()
```

Returns a string representation of the object.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | a string representation of the object. <br /> |