All Projects → hacknife → Briefness

hacknife / Briefness

Licence: apache-2.0
数据绑定、布局绑定、控件绑定、事件绑定、数据异常预处理、开发更加简单。

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Briefness

Exchange Rates Mvvm
Sample Android project which incorporates MVVM, databinding, RxJava2, Dagger2 and Clean Architecture approach.
Stars: ✭ 43 (-72.78%)
Mutual labels:  databinding
Livedatabinding
Kotlin example with LiveData and Data Binding usage
Stars: ✭ 108 (-31.65%)
Mutual labels:  databinding
Bindables
🧬 Android DataBinding kit for notifying data changes from Model layers to UI layers on MVVM architecture.
Stars: ✭ 130 (-17.72%)
Mutual labels:  databinding
Databindingexample
Sample project for the https://stfalcon.com/en/blog/post/faster-android-apps-with-databinding blogpost
Stars: ✭ 58 (-63.29%)
Mutual labels:  databinding
Android Databinding
this is the databinding framework of android . help to binding data to the view.
Stars: ✭ 93 (-41.14%)
Mutual labels:  databinding
Beatplayer
Music Player
Stars: ✭ 117 (-25.95%)
Mutual labels:  databinding
Weaponapp
一个尽量做到极致的集大成App,努力做到最好(开发阶段)——MVVM+Retrofit+RxJava+Small 插件化+单元测试+MD
Stars: ✭ 1,011 (+539.87%)
Mutual labels:  databinding
Coolweather
Weather App that uses Android best practices. Android Jetpack, clean architecture. Written in Kotlin
Stars: ✭ 154 (-2.53%)
Mutual labels:  databinding
Kotlin Architecture Components Notes Demo
Example of Android Architecture Components which implements MVVM Pattern and written in Kotlin
Stars: ✭ 103 (-34.81%)
Mutual labels:  databinding
Awesomegithub
🔥Android Github客户端,基于组件化开发,支持账户密码与认证登陆。使用Kotlin语言进行开发,项目架构是基于JetPack&DataBinding的MVVM;项目中使用了Arouter、Retrofit、Coroutine、Glide、Dagger与Hilt等流行开源技术。
Stars: ✭ 128 (-18.99%)
Mutual labels:  databinding
Jetpackmvvm
🐔🏀一个Jetpack结合MVVM的快速开发框架,基于MVVM模式集成谷歌官方推荐的JetPack组件库:LiveData、ViewModel、Lifecycle、Navigation组件 使用Kotlin语言,添加大量拓展函数,简化代码 加入Retrofit网络请求,协程,帮你简化各种操作,让你快速开发项目
Stars: ✭ 1,100 (+596.2%)
Mutual labels:  databinding
Archetype
[DEPRECATED]Badass MVVM architecture.
Stars: ✭ 84 (-46.84%)
Mutual labels:  databinding
Mentorship Android
Mentorship System is an application that matches women in tech to mentor each other, on career development, through 1:1 relations during a certain period of time. This is the Android application of this project.
Stars: ✭ 117 (-25.95%)
Mutual labels:  databinding
Spinner Bindings
SpinnerBindings expounds on how we can bind a Spinner with DataBinding or InverseDataBinding.
Stars: ✭ 47 (-70.25%)
Mutual labels:  databinding
Popularmovies
🎥 Movie discovery app showcasing Android best practices with Google's recommended architecture: MVVM + Repository + Offline support + Android Architecture Components + Paging library & Retrofit2.
Stars: ✭ 142 (-10.13%)
Mutual labels:  databinding
Frekans
📻 Frekans is a radio player app. It will be fully developed with Kotlin. It is work-in-progress and under heavy development.
Stars: ✭ 43 (-72.78%)
Mutual labels:  databinding
Harrypotter
🧙🏻 Sample HarryPotter application based on MVVM architecture (ViewModel, LiveData, Repository, Coroutines, Koin or Dagger-Hilt)
Stars: ✭ 116 (-26.58%)
Mutual labels:  databinding
Nationalgeographic
NationalGeographic with Android Architecture Components(Lifecycle) & Kotlin
Stars: ✭ 156 (-1.27%)
Mutual labels:  databinding
Android Vmlib
VMLib is an Android framework based on Android Jetpack, easy to use, desinged for fast development. Embrace the new way devloping Android :)
Stars: ✭ 146 (-7.59%)
Mutual labels:  databinding
Movieapp Clean Architecture
Learning Project (Movie App) For Applying Android Architecture Components And Clean Architecture Using MVVM With Kotlin
Stars: ✭ 123 (-22.15%)
Mutual labels:  databinding

Briefness



数据绑定、布局绑定、控件绑定、事件绑定、数据异常预处理、开发更加简单。

特点

  • 支持MVVM(Model-View-ViewModel)
  • 支持任意数据类型绑定(包含自定义控件)
  • 支持任意类绑定(Activity、Fragment、Dialog、View 如果有需要普通类也可以)
  • 规避空指针引发的异常(防止项目开发中,数据异常引起的空指针)
  • 支持View绑定(我不建议你这样做,因为根本没有必要)
  • 支持点击事件双向绑定(Activity中绑、layout中也可以)
  • 支持长按点击事件绑定
  • 支持library、application
  • 支持布局绑定
  • 支持简单比较运算

概述

Briefness能够避免在项目开发中一些重复繁琐的工作,规避因数据异常引发的空指针异常,提高开发效率。它量身为MVVM框架打造,实现UI逻辑与业务分离,解耦,提高可重用性。 它提供了3种注解方式,9种xml属性完成数据绑定,事件绑定等操作。

属性 功能 控件
imports 引入需要绑定的类 root view
viewModel 引入Viewmodel root view
bind 绑定数据 view
click 点击监听 view
longClick 长按监听 view
textChanged 文本变化监听 TextView
checkChanged 选择变化监听 CheckBox
tabSelected 选择变化监听 TabLayout
tabUnselected 选择变化监听 TabLayout
pageSelected 选择变化监听 ViewPager
progressChanged 进度变化监听 SeekBar
radioChanged 选择变化监听 RadioButton
注解 功能
BindLayout 绑定布局,并解析布局文件
BindView 绑定控件
BindClick 绑定事件
Immersive 沉浸式

比较

注解控件 注解方法 注解布局 数据绑定 任意绑定 事件传递 学习成本
Briefness 支持 支持 支持 支持 支持 支持
Databinding 不支持 不支持 不支持 支持 不支持 支持
ButterKnife 支持 支持 不支持 不支持 不支持 不支持
XUtil 支持 支持 不支持 不支持 不支持 不支持

使用说明

  1. 在使用Briefness提供的功能之前,必须调用Briefness.bind方法,该方法会返回Briefenssor的一个实现类。

  2. 在绑定和引入类中,如果你需要绑定多个数据,或者引入多个类,请使用“|”符号隔开。

  3. "$"符号必须是成对使用的,使用"$"引起来的变量表示是需要变换的。

  4. 注解使用说明

  5. XML属性标签使用说明

  6. MVVM的使用与框架搭建

快速引入项目

合并以下代码到需要使用的Module的dependencies中。

	dependencies {
                ...
              implementation 'com.hacknife.briefness:briefness:2.3.1'
    	      annotationProcessor 'com.hacknife.briefness:briefness-compiler:2.3.1'
	}

混淆

-keep class * implements com.hacknife.briefness.Briefnessor{*;}
-keep @com.hacknife.briefness.BindLayout class *
-keep public interface com.hacknife.briefness.Briefnessor{public *;}
-keep class **.BriefnessInjector {
    *;
}
-keep class **.ViewInjector {
     *;
}




感谢浏览

请不要吝啬你的小星星,如果你有任何疑问,请加入QQ群,我将竭诚为你解答。
Image Text

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].