FreezableUtils | Android Developers

Quicknav Quicknav
Links

- Google Play Developer Console
- Android Developers Blog
- About Android

Android Sites

- Android.com
- Android Developers
- Android Open Source Project

Language
close

- - About
  - Wear
  - TV
  - Auto
- - Get Started
  - Devices
  - Style
  - Patterns
  - Building Blocks
  - Downloads
  - Videos
- - Training
  - API Guides
  - Reference
  - Tools
  - Google Services
  - Samples
- - Google Play
  - Essentials
  - Get Users
  - Engage & Retain
  - Monetize
  - Tools & Reference
  - Developer Stories

## Results

Loading...
Summary: Ctors | Methods | Inherited Methods | [Expand All]
public final class

# FreezableUtils

extends Object

java.lang.Object
↳ | com.google.android.gms.common.data.FreezableUtils

## Class Overview

Utilities for working with `Freezable` objects.

## Summary

Public Constructors
| FreezableUtils()

Public Methods
static <T, E extends Freezable<T>> ArrayList<T> | freeze(E[] array) Utility helper method to freeze an array of freezable entities into a list of concrete entities.
static <T, E extends Freezable<T>> ArrayList<T> | freeze(ArrayList<E> list) Utility helper method to freeze a list of freezable entities into a list of concrete entities.
static <T, E extends Freezable<T>> ArrayList<T> | freezeIterable(Iterable<E> iterable) Utility helper method to freeze an array of freezable entities into a list of concrete entities.

[Expand] Inherited Methods
From class java.lang.Object
Object | clone()
boolean | equals(Object arg0)
void | finalize()
final Class<?> | getClass()
int | hashCode()
final void | notify()
final void | notifyAll()
String | toString()
final void | wait()
final void | wait(long arg0, int arg1)
final void | wait(long arg0)

## Public Constructors

#### public FreezableUtils ()

## Public Methods

#### public static ArrayList<T> freeze (E[] array)

Utility helper method to freeze an array of freezable entities into a list of concrete entities. The array provided here must contain elements that implement the `Freezable` interface.

Type T is the type of object returned by freezing an element of the array. In most cases, this will be the same as `E`.

Type E is the type of object contained in the array. Must implement `Freezable`.

##### Parameters

array | Array to freeze contents from.

##### Returns

- ArrayList of frozen representations of the object present in the provided array.

#### public static ArrayList<T> freeze (ArrayList<E> list)

Utility helper method to freeze a list of freezable entities into a list of concrete entities. The list provided here must contain elements that implement the `Freezable` interface.

Type T is the type of object returned by freezing an element of the list. In most cases, this will be the same as `E`.

Type E is the type of object contained in the list. Must implement `Freezable`.

##### Parameters

list | `ArrayList` to freeze contents from.

##### Returns

- ArrayList of frozen representations of the object present in the provided list.

#### public static ArrayList<T> freezeIterable (Iterable<E> iterable)

Utility helper method to freeze an array of freezable entities into a list of concrete entities. The array provided here must contain elements that implement the `Freezable` interface.

Type T is the type of object returned by freezing an element of the array. In most cases, this will be the same as `E`.

Type E is the type of object contained in the array. Must implement `Freezable`.

##### Parameters

iterable | Iterable to freeze contents from.

##### Returns

- ArrayList of frozen representations of the object present in the provided array.