SlideShare ist ein Scribd-Unternehmen logo
1 von 16
Stargazing at State
Migration Meadow
Testing Trails
Performance Peak
Layout Lake
Material Tents
Google Developer Student Clubs
Bakhtiyarpur College Of Engineering - Patna
This work is licensed under the Apache 2.0 License
Compose Camp #4
App Architecture,
Navigation & Adaptivity
Google Developer Student Clubs
Bakhtiyarpur College Of Engineering - Patna
22nd September, 2022
This work is licensed under the Apache 2.0 License
App Architecture
A typical Android app contains multiple app components, including activities, fragments, services, content
providers, and broadcast receivers.
Activity : It is that window in which the app draws its UI. One activity implements one screen in an app.
Fragments : A Fragment represents a reusable portion of your app's UI. Also known as sub-activity. This
adds modularity to your App.
Services : It is an application component that can perform long-running operations in the background. It
does not provide a user interface. Once started, a service might continue running for some time,
even after the user switches to another application. Eg: Location tracer, Audio Recorder, etc.
Content Providers : It manages access to a central repository of data. Eg- Phone Numbers saved in your
contacts can be accessed by 3rd party applications like Whatsapp, Telegram,
etc
Broadcast Receivers : It is an Android component which allows you to send or receive Android system or
application events.
An application architecture describes the patterns and techniques used to design and build an
application. The architecture gives you a roadmap and best practices to follow when building an
application, so that you end up with a well-structured app.
This work is licensed under the Apache 2.0 License
Recommended app architecture
Each application should have at least two layers:
● The UI layer that displays application data on the screen.
● The data layer that contains the business logic of your
app and exposes application data.
You can add an additional layer called the domain layer to
simplify and reuse the interactions between the UI and data
layers.
This work is licensed under the Apache 2.0 License
UI layer
The role of the UI layer (or presentation layer) is to display the
application data on the screen. Whenever the data changes,
either due to user interaction (such as pressing a button) or
external input (such as a network response), the UI should
update to reflect the changes.
The UI layer is made up of two things:
● UI elements that render the data on the screen. You
build these elements using Views or Jetpack Compose
functions.
● State holders (such as ViewModel classes) that hold
data, expose it to the UI, and handle logic.
This work is licensed under the Apache 2.0 License
Data layer
The data layer of an app contains the business logic. The
business logic is what gives value to your app—it's made of
rules that determine how your app creates, stores, and
changes data.
For example, you might create a NotesRepository class for
storing notes on your application, or a PaymentsRepository
class for data related to payments.
Repository classes are used for :
● Exposing data to the rest of the app.
● Centralizing changes to the data.
● Resolving conflicts between multiple data sources.
● Containing business logic.
This work is licensed under the Apache 2.0 License
Benefits of Architecture
Having a good Architecture implemented in your app brings a lot of
benefits to the project and engineering teams:
● It improves the maintainability, quality and robustness of the
overall app.
● It allows the app to scale. More people and more teams can
contribute to the same codebase with minimal code conflicts.
● It helps with onboarding. As Architecture brings consistency to
your project, new members of the team can quickly get up to
speed and be more efficient in less amount of time.
● It is easier to test. A good Architecture encourages simpler types
which are generally easier to test.
● Bugs can be investigated methodically with well defined
processes.
This work is licensed under the Apache 2.0 License
Navigation occurs between your’s app destination-
that is , anywhere in your app to which users can
navigate. These destinations are connected via
actions. A navigation graph is a resource file that
contains all of your destinations and actions. The
graph represents all of your app's navigation paths.
Navigation :-
This work is licensed under the Apache 2.0 License
Figure shows a visual representation of a navigation graph for
a sample app containing six destinations connected by five
actions. Each destination is represented by a preview
thumbnail, and connecting actions are represented by arrows
that show how users can navigate from one destination to
another.
Structure of navigation implementation
This work is licensed under the Apache 2.0 License
This work is licensed under the Apache 2.0 License
Adaptive Android
Apps
Android devices come in a variety of shapes, sizes, and form factors. You should design your app
to run on these different types of devices, from small screen devices to larger screen devices.
Your app must have a flexible layout. Instead of defining your layout with rigid dimensions that
assume a certain aspect ratio and screen size, your layout should be able to gracefully adapt
to various screen sizes and orientations. The same principle applies when your app is running
on a foldable device where the screen size and aspect ratio may change while your app is
running.
This work is licensed under the Apache 2.0 License
App Demo by Himanshu Raj (21CS28)
BCE - Mart
This work is licensed under the Apache 2.0 License
App Demo by Sandesh Kumar (21CS37)
Web - Devil
This work is licensed under the Apache 2.0 License
Compose Camp Week #4 Content
https://d
Architecture Components Adapt for different sizes
Navigation in Jetpack Compose
This work is licensed under the Apache 2.0 License
Week 4 content
Architecture Components Navigation in jetpack compose
Adapt for different screen sizes
● Built an adaptive app with
dynamic navigation
● Stages of the activity
lifecycle
● Intro to app architecture
● Architecture: The UI
layer
and many more…..
● Navigate between screens
with compose
● Test the cupcake app
● Add navigation
● and many more….
This work is licensed under the Apache 2.0 License
THANK
YOU
Google Developer Student Clubs
Bakhtiyarpur College Of Engineering - Patna

Weitere ähnliche Inhalte

Ähnlich wie Compose camp 4.pptx

Web Application Development-Ultimate Guide To Web Application Architecture
Web Application Development-Ultimate Guide To Web Application ArchitectureWeb Application Development-Ultimate Guide To Web Application Architecture
Web Application Development-Ultimate Guide To Web Application ArchitectureVersatile Mobitech
 
Design and Monitoring Performance of Digital Properties
Design and Monitoring Performance of Digital PropertiesDesign and Monitoring Performance of Digital Properties
Design and Monitoring Performance of Digital PropertiesIRJET Journal
 
Application for Data Sync Between Different geo Locations
Application for Data Sync Between Different geo LocationsApplication for Data Sync Between Different geo Locations
Application for Data Sync Between Different geo LocationsMike Taylor
 
Automatized Application Services for Android Devices Using Apache Ant in Clou...
Automatized Application Services for Android Devices Using Apache Ant in Clou...Automatized Application Services for Android Devices Using Apache Ant in Clou...
Automatized Application Services for Android Devices Using Apache Ant in Clou...IRJET Journal
 
Introduction to android
Introduction to androidIntroduction to android
Introduction to androidjavalabsf
 
Research Inventy : International Journal of Engineering and Science
Research Inventy : International Journal of Engineering and ScienceResearch Inventy : International Journal of Engineering and Science
Research Inventy : International Journal of Engineering and Scienceinventy
 
Progressive Web Application by Citytech
Progressive Web Application by CitytechProgressive Web Application by Citytech
Progressive Web Application by CitytechRitwik Das
 
EMC Documentum xCP 2.0 Design Patterns
EMC Documentum xCP 2.0 Design PatternsEMC Documentum xCP 2.0 Design Patterns
EMC Documentum xCP 2.0 Design PatternsHaytham Ghandour
 
Case study on tablet application for real time video, audio and ppt conversion
Case study on tablet application for real time video, audio and ppt conversionCase study on tablet application for real time video, audio and ppt conversion
Case study on tablet application for real time video, audio and ppt conversionGrey Matter India Technologies PVT LTD
 
A Deep Dive into Android App Development 2.0.pdf
A Deep Dive into Android App Development 2.0.pdfA Deep Dive into Android App Development 2.0.pdf
A Deep Dive into Android App Development 2.0.pdflubnayasminsebl
 
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...DicodingEvent
 
progressive web app
 progressive web app progressive web app
progressive web appRAGINI .
 
Web Based Application for Rent or Sale
Web Based Application for Rent or SaleWeb Based Application for Rent or Sale
Web Based Application for Rent or SaleMike Taylor
 

Ähnlich wie Compose camp 4.pptx (20)

Web Application Development-Ultimate Guide To Web Application Architecture
Web Application Development-Ultimate Guide To Web Application ArchitectureWeb Application Development-Ultimate Guide To Web Application Architecture
Web Application Development-Ultimate Guide To Web Application Architecture
 
Design and Monitoring Performance of Digital Properties
Design and Monitoring Performance of Digital PropertiesDesign and Monitoring Performance of Digital Properties
Design and Monitoring Performance of Digital Properties
 
Application for Data Sync Between Different geo Locations
Application for Data Sync Between Different geo LocationsApplication for Data Sync Between Different geo Locations
Application for Data Sync Between Different geo Locations
 
Automatized Application Services for Android Devices Using Apache Ant in Clou...
Automatized Application Services for Android Devices Using Apache Ant in Clou...Automatized Application Services for Android Devices Using Apache Ant in Clou...
Automatized Application Services for Android Devices Using Apache Ant in Clou...
 
Introduction to android
Introduction to androidIntroduction to android
Introduction to android
 
Research Inventy : International Journal of Engineering and Science
Research Inventy : International Journal of Engineering and ScienceResearch Inventy : International Journal of Engineering and Science
Research Inventy : International Journal of Engineering and Science
 
Progressive Web Application by Citytech
Progressive Web Application by CitytechProgressive Web Application by Citytech
Progressive Web Application by Citytech
 
EMC Documentum xCP 2.0 Design Patterns
EMC Documentum xCP 2.0 Design PatternsEMC Documentum xCP 2.0 Design Patterns
EMC Documentum xCP 2.0 Design Patterns
 
Case study on tablet application for real time video, audio and ppt conversion
Case study on tablet application for real time video, audio and ppt conversionCase study on tablet application for real time video, audio and ppt conversion
Case study on tablet application for real time video, audio and ppt conversion
 
A Deep Dive into Android App Development 2.0.pdf
A Deep Dive into Android App Development 2.0.pdfA Deep Dive into Android App Development 2.0.pdf
A Deep Dive into Android App Development 2.0.pdf
 
Progressive web app
Progressive web appProgressive web app
Progressive web app
 
Flutter.pdf
 Flutter.pdf Flutter.pdf
Flutter.pdf
 
Cc unit 5
Cc unit 5Cc unit 5
Cc unit 5
 
Naresh Chirra
Naresh ChirraNaresh Chirra
Naresh Chirra
 
React Native
React Native React Native
React Native
 
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
Baparekraf Digital Talent Day: Monitoring dan Coaching Penerima Fasilitasi BD...
 
Ajax
AjaxAjax
Ajax
 
icv
icvicv
icv
 
progressive web app
 progressive web app progressive web app
progressive web app
 
Web Based Application for Rent or Sale
Web Based Application for Rent or SaleWeb Based Application for Rent or Sale
Web Based Application for Rent or Sale
 

Mehr von bcedsc

INDUCTION 2023.pdf
INDUCTION 2023.pdfINDUCTION 2023.pdf
INDUCTION 2023.pdfbcedsc
 
Machine Learning
Machine LearningMachine Learning
Machine Learningbcedsc
 
Introduction To Flutter
Introduction To FlutterIntroduction To Flutter
Introduction To Flutterbcedsc
 
Let's Flutter
Let's FlutterLet's Flutter
Let's Flutterbcedsc
 
JAVASCRIPT UNLEASHED
JAVASCRIPT UNLEASHEDJAVASCRIPT UNLEASHED
JAVASCRIPT UNLEASHEDbcedsc
 
Getting Started with HTML & CSS
Getting Started with HTML & CSSGetting Started with HTML & CSS
Getting Started with HTML & CSSbcedsc
 
Solution Challenge_ Info Session.pptx
Solution Challenge_ Info Session.pptxSolution Challenge_ Info Session.pptx
Solution Challenge_ Info Session.pptxbcedsc
 
web roadmap.pdf
web roadmap.pdfweb roadmap.pdf
web roadmap.pdfbcedsc
 
GCCP '22 Introduction & Instructions
GCCP '22 Introduction & InstructionsGCCP '22 Introduction & Instructions
GCCP '22 Introduction & Instructionsbcedsc
 
Hacktoberfest.pdf
Hacktoberfest.pdfHacktoberfest.pdf
Hacktoberfest.pdfbcedsc
 
compose camp 1.pptx
compose camp 1.pptxcompose camp 1.pptx
compose camp 1.pptxbcedsc
 
Compose camp 2.pptx
Compose camp 2.pptxCompose camp 2.pptx
Compose camp 2.pptxbcedsc
 
GDSC Induction 2022.pdf
GDSC Induction 2022.pdfGDSC Induction 2022.pdf
GDSC Induction 2022.pdfbcedsc
 

Mehr von bcedsc (13)

INDUCTION 2023.pdf
INDUCTION 2023.pdfINDUCTION 2023.pdf
INDUCTION 2023.pdf
 
Machine Learning
Machine LearningMachine Learning
Machine Learning
 
Introduction To Flutter
Introduction To FlutterIntroduction To Flutter
Introduction To Flutter
 
Let's Flutter
Let's FlutterLet's Flutter
Let's Flutter
 
JAVASCRIPT UNLEASHED
JAVASCRIPT UNLEASHEDJAVASCRIPT UNLEASHED
JAVASCRIPT UNLEASHED
 
Getting Started with HTML & CSS
Getting Started with HTML & CSSGetting Started with HTML & CSS
Getting Started with HTML & CSS
 
Solution Challenge_ Info Session.pptx
Solution Challenge_ Info Session.pptxSolution Challenge_ Info Session.pptx
Solution Challenge_ Info Session.pptx
 
web roadmap.pdf
web roadmap.pdfweb roadmap.pdf
web roadmap.pdf
 
GCCP '22 Introduction & Instructions
GCCP '22 Introduction & InstructionsGCCP '22 Introduction & Instructions
GCCP '22 Introduction & Instructions
 
Hacktoberfest.pdf
Hacktoberfest.pdfHacktoberfest.pdf
Hacktoberfest.pdf
 
compose camp 1.pptx
compose camp 1.pptxcompose camp 1.pptx
compose camp 1.pptx
 
Compose camp 2.pptx
Compose camp 2.pptxCompose camp 2.pptx
Compose camp 2.pptx
 
GDSC Induction 2022.pdf
GDSC Induction 2022.pdfGDSC Induction 2022.pdf
GDSC Induction 2022.pdf
 

Kürzlich hochgeladen

ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfVanessa Camilleri
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)lakshayb543
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONHumphrey A Beña
 
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptxAUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptxiammrhaywood
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designMIPLM
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptxmary850239
 
Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)cama23
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...Nguyen Thanh Tu Collection
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxVanesaIglesias10
 
Food processing presentation for bsc agriculture hons
Food processing presentation for bsc agriculture honsFood processing presentation for bsc agriculture hons
Food processing presentation for bsc agriculture honsManeerUddin
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 

Kürzlich hochgeladen (20)

ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdf
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
 
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptxAUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-design
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx4.16.24 21st Century Movements for Black Lives.pptx
4.16.24 21st Century Movements for Black Lives.pptx
 
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptxYOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
 
Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)Global Lehigh Strategic Initiatives (without descriptions)
Global Lehigh Strategic Initiatives (without descriptions)
 
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
HỌC TỐT TIẾNG ANH 11 THEO CHƯƠNG TRÌNH GLOBAL SUCCESS ĐÁP ÁN CHI TIẾT - CẢ NĂ...
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptx
 
Food processing presentation for bsc agriculture hons
Food processing presentation for bsc agriculture honsFood processing presentation for bsc agriculture hons
Food processing presentation for bsc agriculture hons
 
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptxYOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 

Compose camp 4.pptx

  • 1. Stargazing at State Migration Meadow Testing Trails Performance Peak Layout Lake Material Tents Google Developer Student Clubs Bakhtiyarpur College Of Engineering - Patna
  • 2. This work is licensed under the Apache 2.0 License Compose Camp #4 App Architecture, Navigation & Adaptivity Google Developer Student Clubs Bakhtiyarpur College Of Engineering - Patna 22nd September, 2022
  • 3. This work is licensed under the Apache 2.0 License App Architecture A typical Android app contains multiple app components, including activities, fragments, services, content providers, and broadcast receivers. Activity : It is that window in which the app draws its UI. One activity implements one screen in an app. Fragments : A Fragment represents a reusable portion of your app's UI. Also known as sub-activity. This adds modularity to your App. Services : It is an application component that can perform long-running operations in the background. It does not provide a user interface. Once started, a service might continue running for some time, even after the user switches to another application. Eg: Location tracer, Audio Recorder, etc. Content Providers : It manages access to a central repository of data. Eg- Phone Numbers saved in your contacts can be accessed by 3rd party applications like Whatsapp, Telegram, etc Broadcast Receivers : It is an Android component which allows you to send or receive Android system or application events. An application architecture describes the patterns and techniques used to design and build an application. The architecture gives you a roadmap and best practices to follow when building an application, so that you end up with a well-structured app.
  • 4. This work is licensed under the Apache 2.0 License Recommended app architecture Each application should have at least two layers: ● The UI layer that displays application data on the screen. ● The data layer that contains the business logic of your app and exposes application data. You can add an additional layer called the domain layer to simplify and reuse the interactions between the UI and data layers.
  • 5. This work is licensed under the Apache 2.0 License UI layer The role of the UI layer (or presentation layer) is to display the application data on the screen. Whenever the data changes, either due to user interaction (such as pressing a button) or external input (such as a network response), the UI should update to reflect the changes. The UI layer is made up of two things: ● UI elements that render the data on the screen. You build these elements using Views or Jetpack Compose functions. ● State holders (such as ViewModel classes) that hold data, expose it to the UI, and handle logic.
  • 6. This work is licensed under the Apache 2.0 License Data layer The data layer of an app contains the business logic. The business logic is what gives value to your app—it's made of rules that determine how your app creates, stores, and changes data. For example, you might create a NotesRepository class for storing notes on your application, or a PaymentsRepository class for data related to payments. Repository classes are used for : ● Exposing data to the rest of the app. ● Centralizing changes to the data. ● Resolving conflicts between multiple data sources. ● Containing business logic.
  • 7. This work is licensed under the Apache 2.0 License Benefits of Architecture Having a good Architecture implemented in your app brings a lot of benefits to the project and engineering teams: ● It improves the maintainability, quality and robustness of the overall app. ● It allows the app to scale. More people and more teams can contribute to the same codebase with minimal code conflicts. ● It helps with onboarding. As Architecture brings consistency to your project, new members of the team can quickly get up to speed and be more efficient in less amount of time. ● It is easier to test. A good Architecture encourages simpler types which are generally easier to test. ● Bugs can be investigated methodically with well defined processes.
  • 8. This work is licensed under the Apache 2.0 License Navigation occurs between your’s app destination- that is , anywhere in your app to which users can navigate. These destinations are connected via actions. A navigation graph is a resource file that contains all of your destinations and actions. The graph represents all of your app's navigation paths. Navigation :-
  • 9. This work is licensed under the Apache 2.0 License Figure shows a visual representation of a navigation graph for a sample app containing six destinations connected by five actions. Each destination is represented by a preview thumbnail, and connecting actions are represented by arrows that show how users can navigate from one destination to another. Structure of navigation implementation
  • 10. This work is licensed under the Apache 2.0 License
  • 11. This work is licensed under the Apache 2.0 License Adaptive Android Apps Android devices come in a variety of shapes, sizes, and form factors. You should design your app to run on these different types of devices, from small screen devices to larger screen devices. Your app must have a flexible layout. Instead of defining your layout with rigid dimensions that assume a certain aspect ratio and screen size, your layout should be able to gracefully adapt to various screen sizes and orientations. The same principle applies when your app is running on a foldable device where the screen size and aspect ratio may change while your app is running.
  • 12. This work is licensed under the Apache 2.0 License App Demo by Himanshu Raj (21CS28) BCE - Mart
  • 13. This work is licensed under the Apache 2.0 License App Demo by Sandesh Kumar (21CS37) Web - Devil
  • 14. This work is licensed under the Apache 2.0 License Compose Camp Week #4 Content https://d Architecture Components Adapt for different sizes Navigation in Jetpack Compose
  • 15. This work is licensed under the Apache 2.0 License Week 4 content Architecture Components Navigation in jetpack compose Adapt for different screen sizes ● Built an adaptive app with dynamic navigation ● Stages of the activity lifecycle ● Intro to app architecture ● Architecture: The UI layer and many more….. ● Navigate between screens with compose ● Test the cupcake app ● Add navigation ● and many more….
  • 16. This work is licensed under the Apache 2.0 License THANK YOU Google Developer Student Clubs Bakhtiyarpur College Of Engineering - Patna

Hinweis der Redaktion

  1. Results, Criteria,
  2. Results, Criteria,