lightbulb_outline Please take our October 2018 developer survey. Start survey
added in version 1.0.0
belongs to Maven artifact androidx.slice:slice-core:1.0.0

SliceConvert

public class SliceConvert
extends Object

java.lang.Object
   ↳ androidx.slice.SliceConvert


Convert between androidx.slice.Slice and android.app.slice.Slice

Summary

Public methods

static Slice unwrap(Slice slice)

Convert androidx.slice.Slice to android.app.slice.Slice

static Slice wrap(Slice slice, Context context)

Convert android.app.slice.Slice to androidx.slice.Slice

Inherited methods

Public methods

unwrap

added in version 1.0.0
public static Slice unwrap (Slice slice)

Convert androidx.slice.Slice to android.app.slice.Slice

Parameters
slice Slice

Returns
Slice

wrap

added in version 1.0.0
public static Slice wrap (Slice slice, 
                Context context)

Convert android.app.slice.Slice to androidx.slice.Slice

Parameters
slice Slice

context Context

Returns
Slice