Added resolve method to angular.IQService.

This commit is contained in:
Marco Gonzalez
2015-09-28 21:00:52 -06:00
parent ffceea9dd1
commit fe917d27e9
2 changed files with 20 additions and 1 deletions
+9 -1
View File
@@ -1052,12 +1052,20 @@ declare module angular {
*
* @param value Value or a promise
*/
when<T>(value: IPromise<T>|T): IPromise<T>;
resolve<T>(value: IPromise<T>|T): IPromise<T>;
/**
* Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise. This is useful when you are dealing with an object that might or might not be a promise, or if the promise comes from a source that can't be trusted.
*/
resolve(): IPromise<void>;
/**
* Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise. This is useful when you are dealing with an object that might or might not be a promise, or if the promise comes from a source that can't be trusted.
*
* @param value Value or a promise
*/
when<T>(value: IPromise<T>|T): IPromise<T>;
/**
* Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise. This is useful when you are dealing with an object that might or might not be a promise, or if the promise comes from a source that can't be trusted.
*/
when(): IPromise<void>;
}