Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emitter #22

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Emitter #22

wants to merge 3 commits into from

Conversation

jacobrosenthal
Copy link

It would be nice to emit, or internally listen to emitters and use callbacks for async support. For instance its currently impossible to know when you've successfully stopped advertising so you can start again. Also it would be nice to be notified of advertisingStartError and servicesSetError.

@sandeepmistry offered to the solution just listen on the bleno singleton but it seems like these are in the domain of eddystone beacon and should be offered?

Anyway this should open it for discussion at least.

@sandeepmistry
Copy link
Collaborator

@jacobrosenthal thanks for starting the discussion.

Agreed, I think the following events are relevant: 'advertisingStartError', 'advertisingStart', 'advertisingStop'. What use cases were you thinking of for re-emitting the other bleno event?

Would changing the advertising API's to include an optional callback help?

@jacobrosenthal
Copy link
Author

Hadnt thought of a need for the others yet, but figured why not spit them
out while I was at it :)

Emitting vs callbacks is probably your preference. Callbacks can be
promisified easier...

On Sun, Sep 6, 2015 at 2:51 PM, Sandeep Mistry notifications@github.com
wrote:

@jacobrosenthal https://github.com/jacobrosenthal thanks for starting
the discussion.

Agreed, I think the following events are relevant:
'advertisingStartError', 'advertisingStart', 'advertisingStop'. What use
cases were you thinking of for re-emitting the other bleno event?

Would changing the advertising API's to include an optional callback help?


Reply to this email directly or view it on GitHub
#22 (comment)
.

@sandeepmistry
Copy link
Collaborator

I would say callbacks are the way to go for now. @don what do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants