Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Please check all of the traits that make fragments useful. They are reusable They can be used to build a flexible UI Fragments have

1. Please check all of the traits that make fragments useful.

  1. They are reusable
  2. They can be used to build a flexible UI
  3. Fragments have the same lifecycle as their host activity
  4. You can dynamically add or remove them during runtime
  5. All of the above

2. What is the right sequence in order to dynamically display a fragment.

For example, to start a new activity: A) Create a new Intent that points to the new activity, B) Add any information you want to that Intent, C) Start the intent. The right sequence is ABC.

A- Create a new fragment instance in a host activity

B- Create a new fragment class that inflates a layout

C- Create a layout that defines the appearance of the fragment

D- Add the fragment to it's host activity using the FragmentManager and a fragment transaction

  1. ABDC
  2. ADBC
  3. CBAD
  4. DACB
  5. DCBA

3. Which callback method is called when the Fragments user interface becomes visible but is not yet active?

  1. onCreateView()
  2. onStart()
  3. onPause()
  4. onResume()

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database System

Authors: Elmasri Ramez And Navathe Shamkant

7th Edition

978-9332582705

More Books

Students also viewed these Databases questions

Question

Find the point(s) on the surface xyz = 1 closest to the origin.

Answered: 1 week ago