Android developers are always looking for a way to get their work done with less code. Getting references to view objects and setting up event handlers takes a lot of boilerplate code, and you very quickly start wondering if there’s a better way. Butter Knife is an open-source library that can significantly reduce that code.
- [Instructor] Android developers are always looking for…a way to get their work done with less code.…Getting references to view object…and setting up event handlers takes a good bit of…boilerplate code and you very quickly start wondering…if there's a better way.…There's a popular open source library named ButterKnife.…It's available at this web page.…The purpose of ButterKnife is to streamline your code,…moving away from the use of the findViewById method…and toward the use of annotations.…
To get started with ButterKnife, go to this page…and scroll all the way down to the bottom.…Under the Download section, under Gradle,…select and copy these two declarations.…Then go back to Android Studio…and open your Gradle build file for your app module.…Paste those declarations at the bottom…and then re-sync Gradle.…ButterKnife is now available to your application.…
In the main activity class of this application…there are two view references, one for a TextView…and the other for a CoordinatorLayout.…In the onCreate method, there are two equivalent assignments…
Skill Level Intermediate
Q: Why can't I earn a Certificate of Completion for this course?
A: We publish a new tutorial or tutorials for this course on a regular basis. We are unable to offer a Certificate of Completion because it is an ever-evolving course that is not designed to be completed. Check back often for new movies.
Android App Development: Communicating with the Userwith Joe Marini1h 12m Intermediate
Building Android Apps with Cloud Serviceswith Albert Lo2h 37m Intermediate
Android App Development: Data Persistence Librarieswith Annyce Davis3h 59m Intermediate
New This Week:
1. Android Development Tips Weekly
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.