Hi, is it possible somehow to get all the factories instances that the name 
ends with "strategy", for example?
I'm building a strategy pattern, and right now, the code looks like:

angular.module('mainApp').factory('detailStrategy', ['$q', 'detailsUrl', 
'liveScheduleStrategy', 'liveProgramStrategy', 'liveSeriesStrategy', 
'movieStrategy', 'seriesStrategy', function ($q, detailsUrl, 
liveScheduleStrategy, liveProgramStrategy, liveSeriesStrategy, 
movieStrategy, seriesStrategy) {
    var getContentData = function (contentOrPid) {
        var strategies = [liveScheduleStrategy, liveProgramStrategy, 
liveSeriesStrategy, movieStrategy, seriesStrategy];


However, it would much more nicer if I could use $injector to return all 
the strategies, because if I create a new strategy, then I would have to 
add it as a dependency.

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to