A fragment is a portion of an Activity. A fragment have its own code and its own UI, for this reason is highly reusable.

The main utility of fragments is that we can show the same app in different ways depending on the screen size of the device. In a tablet, we have more space and we can show more content than a mobile, then, in a tablet we can put more fragments in the same activity than mobile.

Android introduced fragments in Android 3.0 (API level 11) to support large screens, but there is a compatibility library to use them in minor API levels. We’ll write another post to explain this better.

You’ll find all documentation of fragments here.

Related Posts

Data Persistence in iOS Applications

Sharing Services

The Provisioning Portal

A Hack@home Event
Powered by AppCircus

Our Sponsors/Partners Egypt Innovate google orange vodafone TA-Telecom Microsoft

Our partners aleshanek ya balady arabnetdotopen gdg-cairo Green Arm Bey2ollak World Bank itida - Developing IT in Egypt Ministry