Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //somewhere in your sensor class {
- public interface SensorInputObserver {
- public void onNewSensorValues(*put primitives here, not objects, or reuse the objects you put here);
- }
- SensorInputObserver mSensorInputObserver;
- public void processSensorInput() {
- ...
- //once finished with processing, pick relevant values and
- if (mSensorInputObserver != null) {
- mSensorInputObserver.onNewSensorValues(***);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement