Hey I'm new to android can someone please explain me What does it mean to inflate a view from an xml file in little detail.
As I'm trying to show some data on RecyclerView from an arraylist.
Hey I'm new to android can someone please explain me What does it mean to inflate a view from an xml file in little detail.
As I'm trying to show some data on RecyclerView from an arraylist.
Instantiates a layout XML file into its corresponding View objects. It is never used directly. Instead, use getLayoutInflater()
or getSystemService(Class)
to retrieve a standard LayoutInflater instance that is already hooked up to the current context and correctly configured for the device you are running on. For example:
LayoutInflater inflater = (LayoutInflater)context.getSystemService
(Context.LAYOUT_INFLATER_SERVICE);