Comments (1)
A compiled repository without any event source will only react to the event that it's activated. This could be useful in many scenarios, but typically when all the data sources are static, for example, when you're building a data chain from some static data.
A compiled repository with event source will also react to events from those sources and attempt to update its value.
External event sources typically provide values or signals to the compiled repository. For example, if this repository gets a value from another repository, then if that value changes, this repository should refresh. In this case you'll want to put "that repository" as one of the event sources of "this repository".
An example of "signal" event source: a network connectivity checker. If "this repository" depends on data from the network, then it needs network connectivity to function correctly. If it's activated during the time the device is not connected to a useful network (totally disconnected, or connected to a WiFi that has a paywall), then the computation will likely fail. In this case, you'll want to use the network connectivity checker as one of the event sources, so "this repository" can retry the computation.
Another example "signal" event source: a "refresh trigger". This trigger fires the event when the user selects "refresh" from the UI. Then you'll want the repository to redo the calculation to get fresh data from its data source(s).
Agera is built for responsive UI and is typically used to provide data to the UI and reacts to user interactions and other environment changes that mandate a change of the UI. The event source function ties neatly to this type of event-driven approach.
from agera.
Related Issues (20)
- Compilation problems HOT 1
- Crash when trying to remove not added updatable HOT 1
- Add the 1.2.0 release to the GitHub releases screen HOT 1
- Exception when Response is Empty HOT 4
- [Question] Usages of non main thread to register an Updatable to a BaseObservable? HOT 5
- Wish to support Kotlin language.
- crash bug HOT 3
- About IdentityMultimap query. HOT 3
- Is this library dead? HOT 2
- [question] Push Event on a high speed frequency, Pull Data will too busy to attend to all HOT 2
- Query HOT 3
- [Query]: About switch work-thread HOT 10
- Agera 是否支持线程并发再合并? HOT 1
- #44
- (gradle4.4.1, agera1.4.0) when I run proguard, I got these warnings:
- Could not find dependency "com.google.android.agera:agera:1.4.0" HOT 6
- Sample doesn't build, is this project dead? HOT 7
- Androidx支持
- Deploy the last artifact outside of jcenter HOT 1
- Security Policy violation Binary Artifacts HOT 41
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from agera.