Targets
This service is in charge of providing and validating the targets stored on the runner file.
Constructor Summary
Public Constructor | ||
public |
constructor(packageInfo: Object, pathUtils: PathUtils, projextPlugin: ProjextPlugin, runnerFile: RunnerFile) Class constructor. |
Member Summary
Public Members | ||
public |
The information of the project's |
|
public |
A local reference for the |
|
public |
A local reference for the |
|
public |
A local reference for the |
Method Summary
Public Methods | ||
public |
Returns the target with the name of project (specified on the |
|
public |
Get a target information by its name. |
|
public |
Validate a target information. |
Private Methods | ||
private |
_normalizeTarget(target: Target): Target Add the execution path ( |
Public Constructors
public constructor(packageInfo: Object, pathUtils: PathUtils, projextPlugin: ProjextPlugin, runnerFile: RunnerFile) source
Class constructor.
Params:
Name | Type | Attribute | Description |
packageInfo | Object | The project's |
|
pathUtils | PathUtils | To create the targets exeuction paths. |
|
projextPlugin | ProjextPlugin | To check if projext is present or not. |
|
runnerFile | RunnerFile | To get the targets information. |
Public Members
Public Methods
public getDefaultTarget(): Target source
Returns the target with the name of project (specified on the package.json
) and if there's
no target with that name, then the first one, using a list of the targets name on alphabetical
order.
Throw:
If the project has no targets |
public getTarget(name: string): Target source
Get a target information by its name.
Params:
Name | Type | Attribute | Description |
name | string | The target name. |
Throw:
If the target information is not on the runner file. |
public validate(name: string): boolean source
Validate a target information.
Params:
Name | Type | Attribute | Description |
name | string |
|
The target name. |