###
# ownCloud
#
# @author Bernhard Posselt
# Copyright (c) 2012 - Bernhard Posselt <nukeawhale@gmail.com>
#
# This file is licensed under the Affero General Public License version 3 or later.
# See the COPYING-README file
#
###

angular.module('LargeFileUpload').factory 'LargeFileUploadRequest',
['$http', 'Config', '_LargeFileUploadRequest', 'Publisher',
($http, Config, _LargeFileUploadRequest, Publisher) ->
	return new _LargeFileUploadRequest($http, Config, Publisher)
]

angular.module('LargeFileUpload').factory 'ItemModel',
['_ItemModel',
(_ItemModel) ->
	return new _ItemModel()
]

angular.module('LargeFileUpload').factory 'Publisher',
['_Publisher', 'ItemModel',
(_Publisher, ItemModel) ->
	publisher = new _Publisher()
	publisher.subscribeModelTo(ItemModel, 'items')
	return publisher
]