1
1
/// <reference path="angular-resource.d.ts" />
2
2
3
- interface IMyResource extends ng . resource . IResource < IMyResource > { } ;
4
- interface IMyResourceClass extends ng . resource . IResourceClass < IMyResource > { } ;
3
+ interface IMyResource extends angular . resource . IResource < IMyResource > { } ;
4
+ interface IMyResourceClass extends angular . resource . IResourceClass < IMyResource > { } ;
5
5
6
6
///////////////////////////////////////
7
7
// IActionDescriptor
8
8
///////////////////////////////////////
9
- var actionDescriptor : ng . resource . IActionDescriptor ;
9
+ var actionDescriptor : angular . resource . IActionDescriptor ;
10
10
11
11
actionDescriptor . headers = { header : 'value' } ;
12
12
actionDescriptor . isArray = true ;
@@ -19,7 +19,7 @@ actionDescriptor.params = { key: 'value' };
19
19
///////////////////////////////////////
20
20
var resourceClass : IMyResourceClass ;
21
21
var resource : IMyResource ;
22
- var resourceArray : ng . resource . IResourceArray < IMyResource > ;
22
+ var resourceArray : angular . resource . IResourceArray < IMyResource > ;
23
23
24
24
resource = resourceClass . delete ( ) ;
25
25
resource = resourceClass . delete ( { key : 'value' } ) ;
@@ -49,7 +49,7 @@ resourceArray = resourceClass.query({ key: 'value' }, { key: 'value' });
49
49
resourceArray = resourceClass . query ( { key : 'value' } , { key : 'value' } , function ( ) { } ) ;
50
50
resourceArray = resourceClass . query ( { key : 'value' } , { key : 'value' } , function ( ) { } , function ( ) { } ) ;
51
51
resourceArray . push ( resource ) ;
52
- resourceArray . $promise . then ( function ( data : ng . resource . IResourceArray < IMyResource > ) { } ) ;
52
+ resourceArray . $promise . then ( function ( data : angular . resource . IResourceArray < IMyResource > ) { } ) ;
53
53
54
54
resource = resourceClass . remove ( ) ;
55
55
resource = resourceClass . remove ( { key : 'value' } ) ;
@@ -73,8 +73,8 @@ resource = resourceClass.save({ key: 'value' }, { key: 'value' }, function () {
73
73
// IResource
74
74
///////////////////////////////////////
75
75
76
- var promise : ng . IPromise < IMyResource > ;
77
- var arrayPromise : ng . IPromise < IMyResource [ ] > ;
76
+ var promise : angular . IPromise < IMyResource > ;
77
+ var arrayPromise : angular . IPromise < IMyResource [ ] > ;
78
78
79
79
promise = resource . $delete ( ) ;
80
80
promise = resource . $delete ( { key : 'value' } ) ;
@@ -97,7 +97,7 @@ arrayPromise = resourceArray[0].$query({ key: 'value' }, function () { });
97
97
arrayPromise = resourceArray [ 0 ] . $query ( function ( ) { } ) ;
98
98
arrayPromise = resourceArray [ 0 ] . $query ( function ( ) { } , function ( ) { } ) ;
99
99
arrayPromise = resourceArray [ 0 ] . $query ( { key : 'value' } , function ( ) { } , function ( ) { } ) ;
100
- arrayPromise . then ( function ( data : ng . resource . IResourceArray < IMyResource > ) { } ) ;
100
+ arrayPromise . then ( function ( data : angular . resource . IResourceArray < IMyResource > ) { } ) ;
101
101
102
102
promise = resource . $remove ( ) ;
103
103
promise = resource . $remove ( { key : 'value' } ) ;
@@ -116,7 +116,7 @@ promise = resource.$save({ key: 'value' }, function () { }, function () { });
116
116
///////////////////////////////////////
117
117
// IResourceService
118
118
///////////////////////////////////////
119
- var resourceService : ng . resource . IResourceService ;
119
+ var resourceService : angular . resource . IResourceService ;
120
120
resourceClass = resourceService < IMyResource , IMyResourceClass > ( 'test' ) ;
121
121
resourceClass = resourceService < IMyResource > ( 'test' ) ;
122
122
resourceClass = resourceService ( 'test' ) ;
@@ -125,12 +125,12 @@ resourceClass = resourceService('test');
125
125
// IModule
126
126
///////////////////////////////////////
127
127
var mod : ng . IModule ;
128
- var resourceServiceFactoryFunction : ng . resource . IResourceServiceFactoryFunction < IMyResource > ;
129
- var resourceService : ng . resource . IResourceService ;
128
+ var resourceServiceFactoryFunction : angular . resource . IResourceServiceFactoryFunction < IMyResource > ;
129
+ var resourceService : angular . resource . IResourceService ;
130
130
131
131
resourceClass = resourceServiceFactoryFunction < IMyResourceClass > ( resourceService ) ;
132
132
133
- resourceServiceFactoryFunction = function ( resourceService : ng . resource . IResourceService ) { return < any > resourceClass ; } ;
133
+ resourceServiceFactoryFunction = function ( resourceService : angular . resource . IResourceService ) { return < any > resourceClass ; } ;
134
134
mod = mod . factory ( 'factory name' , resourceServiceFactoryFunction ) ;
135
135
136
136
///////////////////////////////////////
0 commit comments