-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
185 additions
and
69 deletions.
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
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
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
11 changes: 11 additions & 0 deletions
11
packages/@ember/-internals/runtime/lib/mixins/container_proxy.d.ts
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Container } from '@ember/-internals/container'; | ||
import Mixin from '../../types/mixin'; | ||
|
||
interface ContainerProxy { | ||
ownerInjection: Container['ownerInjection']; | ||
lookup: Container['lookup']; | ||
factoryFor: Container['factoryFor']; | ||
} | ||
declare const ContainerProxy: Mixin; | ||
|
||
export { ContainerProxy as default }; |
17 changes: 17 additions & 0 deletions
17
packages/@ember/-internals/runtime/lib/mixins/registry_proxy.d.ts
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { Registry } from '@ember/-internals/container'; | ||
import Mixin from '../../types/mixin'; | ||
|
||
interface RegistryProxyMixin { | ||
resolveRegistration: Registry['resolve']; | ||
register: Registry['register']; | ||
unregister: Registry['unregister']; | ||
hasRegistration: Registry['has']; | ||
registeredOption: Registry['getOption']; | ||
registerOptions: Registry['options']; | ||
registeredOptions: Registry['getOptions']; | ||
registerOptionsForType: Registry['optionsForType']; | ||
registeredOptionsForType: Registry['getOptionsForType']; | ||
} | ||
declare const RegistryProxyMixin: Mixin; | ||
|
||
export { RegistryProxyMixin as default }; |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,16 @@ | ||
import EngineInstance from './instance'; | ||
import { EngineInstanceOptions, Factory } from '@ember/-internals/owner'; | ||
import { EngineInstanceOptions } from '@ember/-internals/owner'; | ||
import { Namespace, RegistryProxyMixin } from '@ember/-internals/runtime'; | ||
|
||
export function getEngineParent(instance: EngineInstance): EngineInstance | undefined; | ||
export { getEngineParent } from '@ember/engine/lib/engine-parent'; | ||
|
||
export { EngineInstance }; | ||
|
||
export default class Engine { | ||
constructor(...args: any[]); | ||
init(...args: any[]): void; | ||
register<T, C>(fullName: string, factory: Factory<T, C>, options?: object): void; | ||
// eslint-disable-next-line @typescript-eslint/no-empty-interface | ||
interface Engine extends RegistryProxyMixin {} | ||
declare class Engine extends Namespace { | ||
buildInstance(options?: EngineInstanceOptions): EngineInstance; | ||
initializer: (initializer: unknown) => void; | ||
instanceInitializer: (initializer: unknown) => void; | ||
Resolver: unknown | null; | ||
} | ||
|
||
export { Engine as default }; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
import { ContainerProxyMixin, RegistryProxyMixin } from '@ember/-internals/runtime'; | ||
import { Owner } from '@ember/-internals/owner'; | ||
import { BootOptions } from '@ember/application/instance'; | ||
import EmberObject from '@ember/object'; | ||
|
||
// eslint-disable-next-line @typescript-eslint/no-empty-interface | ||
interface EngineInstance extends Owner {} | ||
interface EngineInstance extends RegistryProxyMixin, ContainerProxyMixin, Owner {} | ||
|
||
declare class EngineInstance extends EmberObject { | ||
boot(): void; | ||
init(...args: unknown[]): void; | ||
boot(options?: BootOptions): void; | ||
unregister(fullName: string): void; | ||
} | ||
|
||
export default EngineInstance; |
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.