This repository has been archived by the owner on Feb 26, 2022. It is now read-only.
Bug 706590 - API for implementing XPCOM interfaces #305
Merged
Merged
Changes from 24 commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
71938a6
Merge branch 'bug/compose-702835' into bug/shared.modules-706590
Gozala aac050b
Define module for generating UUID's.
Gozala fd9afb3
Merge remote-tracking branch 'upstream/master' into bug/shared.module…
Gozala 132b1fa
Implement Unknown and Factory base XPCOM components.
Gozala 8d7a486
Update tests for xpcom module.
Gozala c757842
Update timer implementation that depended on old `xpcom`
Gozala 6b54275
Update observer-service that depended on old xpcom.
Gozala 7fa3ba7
Update memory module that assumed that every object has constructor p…
Gozala 42bd88a
Update widget module that depended on old xpcom module.
Gozala d8b8018
Update selection module that depended on old xpcom module.
Gozala 4968bd5
Update request module that depended on old xpcom module.
Gozala f7bbcfa
Add self into contributors of the modified files.
Gozala 40936fc
Merge remote-tracking branch 'upstream/master' into bug/xpcom-706590
Gozala 6ef1eae
Merge remote-tracking branch 'upstream/master' into bug/xpcom-706590
Gozala 164801e
Remove unused sdkVersion variable.
Gozala c081ee6
Adding uuid tests.
Gozala 1863cb6
Merge remote-tracking branch 'upstream/master' into bug/xpcom-706590
Gozala d662597
Use `ns` function exported by `Namespace` module in order to avoid co…
Gozala 775e99e
Factor out `Service` exemplar from the `Factory` and change `createIn…
Gozala d6405a7
Update tests for xpcom module to include ones suggested by @ochameau
Gozala 18153c4
Update XPCOM module documentation.
Gozala 1cc7603
Merge remote-tracking branch 'upstream/master' into bug/xpcom-706590
Gozala 04cb16f
Update API as suggested by @ochameau
Gozala 29b511d
Fix regression introduced by moving `wrappedJSObject` to an `Unknown`.
Gozala 72f26c7
Refine implementation so that `Service` inherits from `Factory` that …
Gozala a685c27
Allow `null` contractID.
Gozala f28dbf6
Update tests.
Gozala 80d1a3b
Simplify observer service.
Gozala 12721cf
Rename `getClass` to more descriptive `factoryByContract`.
Gozala 666df10
Update implementation to use shorter property names.
Gozala 393ea33
Update documentation.
Gozala cf21e2b
Adding better description to the factoryByContract.
Gozala 7de95cb
Update tests.
Gozala 992bf09
Add suggested test case.
Gozala 3c45576
fix indentation.
Gozala ef89c9b
Use shorter function syntax.
Gozala 7e56d38
improve code comments as suggested by ochameau.
Gozala File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI: defineLazyGetter is special, it is used to fetch and set an attribute lazily and only once:
https://developer.mozilla.org/en/JavaScript_code_modules/XPCOMUtils.jsm#defineLazyGetter%28%29
I'd imagine it has been used for performances reason. And it doesn't necessary worth its noise nor using mozilla-dark-feature use!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Exactly it also assumes that
this
represents a scope, which is valid now, but in of my loader prototypes it was not, so I'd prefer not to use it. If we need to be lazy just use a function that caches return value.