C# Class Microsoft.WindowsAzure.Commands.Utilities.CloudService.CloudServiceProject

Class that encapsulates all of the info about a service, to which we can add roles. This is all in memory, so no disk operations occur.
Afficher le fichier Open project: Azure/azure-powershell Class Usage Examples

Méthodes publiques

Méthode Description
AddRoleRuntime ( CloudProjectPathInfo paths, string roleName, string runtimeType, string runtimeVersion, string manifest = null ) : void

Add the specified runtime to a role, checking that the runtime and version are currently available int he cloud

AddWebRole ( string scaffolding, string name = null, int instanceCount = 1 ) : RoleInfo
AddWorkerRole ( string scaffolding, string name = null, int instanceCount = 1 ) : RoleInfo
ChangeRolePermissions ( RoleInfo role ) : void
ChangeServiceName ( string newName, CloudProjectPathInfo paths ) : void
CloudServiceProject ( ) : Common.System
CloudServiceProject ( string cloudConfigurationFullPath ) : Common.System
CloudServiceProject ( string rootPath, string scaffoldingPath ) : Common.System
CloudServiceProject ( string rootPath, string name, string scaffoldingPath ) : Common.System
GenerateScaffolding ( string scaffolding, string roleName, object>.Dictionary parameters ) : void

Generates scaffolding for role.

GetCloudRuntimes ( CloudProjectPathInfo paths, string manifest ) : CloudRuntimeCollection

Retrieve currently available cloud runtimes

Reload ( ) : void

Reloads the cloud service project configuration from the disk.

ResolveRuntimePackageUrls ( string manifest = null ) : string

Resolves the service runtimes into downloadable URLs.

SetRoleInstances ( CloudProjectPathInfo paths, string roleName, int instances ) : void

Sets the role instance count

SetRoleVMSize ( CloudProjectPathInfo paths, string roleName, string VMSize ) : void

Sets the role VMSize

StartEmulators ( bool launchBrowser, ComputeEmulatorMode mode, string &roleInformation, string &warning ) : void

Starts azure emulator for this service.

This methods removes all deployments already in the emulator.

StopEmulators ( string &warning ) : void

Private Methods

Méthode Description
AddRoleCore ( string scaffolding, RoleInfo role ) : void

Adds the given role to both config files and the service def.

ConfigureNewService ( ServiceComponents components, CloudProjectPathInfo paths, string serviceName ) : void
CreateDefaultParameters ( RoleInfo role ) : object>.Dictionary
CreateNewService ( string serviceRootPath, string serviceName ) : void
CreatePackage ( DevEnv type ) : void
GetRoleName ( string name, string defaultName, IEnumerable existingNames ) : string

Creates a role name, ensuring it doesn't already exist. If null is passed in, a number will be appended to the defaultRoleName.

SetScaffolding ( string scaffoldingFolderDirectory ) : void
VerifyCloudServiceProjectComponents ( ) : void

Method Details

AddRoleRuntime() public méthode

Add the specified runtime to a role, checking that the runtime and version are currently available int he cloud
public AddRoleRuntime ( CloudProjectPathInfo paths, string roleName, string runtimeType, string runtimeVersion, string manifest = null ) : void
paths CloudProjectPathInfo service path info
roleName string Name of the role to change
runtimeType string The runtime identifier
runtimeVersion string The runtime version
manifest string Location fo the manifest file, default is the cloud manifest
Résultat void

AddWebRole() public méthode

public AddWebRole ( string scaffolding, string name = null, int instanceCount = 1 ) : RoleInfo
scaffolding string
name string
instanceCount int
Résultat RoleInfo

AddWorkerRole() public méthode

public AddWorkerRole ( string scaffolding, string name = null, int instanceCount = 1 ) : RoleInfo
scaffolding string
name string
instanceCount int
Résultat RoleInfo

ChangeRolePermissions() public méthode

public ChangeRolePermissions ( RoleInfo role ) : void
role RoleInfo
Résultat void

ChangeServiceName() public méthode

public ChangeServiceName ( string newName, CloudProjectPathInfo paths ) : void
newName string
paths CloudProjectPathInfo
Résultat void

CloudServiceProject() public méthode

public CloudServiceProject ( ) : Common.System
Résultat Common.System

CloudServiceProject() public méthode

public CloudServiceProject ( string cloudConfigurationFullPath ) : Common.System
cloudConfigurationFullPath string
Résultat Common.System

CloudServiceProject() public méthode

public CloudServiceProject ( string rootPath, string scaffoldingPath ) : Common.System
rootPath string
scaffoldingPath string
Résultat Common.System

CloudServiceProject() public méthode

public CloudServiceProject ( string rootPath, string name, string scaffoldingPath ) : Common.System
rootPath string
name string
scaffoldingPath string
Résultat Common.System

GenerateScaffolding() public méthode

Generates scaffolding for role.
public GenerateScaffolding ( string scaffolding, string roleName, object>.Dictionary parameters ) : void
scaffolding string The relative scaffolding source path
roleName string The role name
parameters object>.Dictionary The rule parameters
Résultat void

GetCloudRuntimes() public méthode

Retrieve currently available cloud runtimes
public GetCloudRuntimes ( CloudProjectPathInfo paths, string manifest ) : CloudRuntimeCollection
paths CloudProjectPathInfo service path info
manifest string The manifest to use to get current runtime info - default is the cloud manifest
Résultat CloudRuntimeCollection

Reload() public méthode

Reloads the cloud service project configuration from the disk.
public Reload ( ) : void
Résultat void

ResolveRuntimePackageUrls() public méthode

Resolves the service runtimes into downloadable URLs.
public ResolveRuntimePackageUrls ( string manifest = null ) : string
manifest string The custom manifest file
Résultat string

SetRoleInstances() public méthode

Sets the role instance count
public SetRoleInstances ( CloudProjectPathInfo paths, string roleName, int instances ) : void
paths CloudProjectPathInfo The service paths
roleName string The name of the role to change its instance count
instances int
Résultat void

SetRoleVMSize() public méthode

Sets the role VMSize
public SetRoleVMSize ( CloudProjectPathInfo paths, string roleName, string VMSize ) : void
paths CloudProjectPathInfo The service paths
roleName string The name of the role to change its vm size
VMSize string The new role vm size
Résultat void

StartEmulators() public méthode

Starts azure emulator for this service.
This methods removes all deployments already in the emulator.
public StartEmulators ( bool launchBrowser, ComputeEmulatorMode mode, string &roleInformation, string &warning ) : void
launchBrowser bool Switch to control opening a browser for web roles.
mode ComputeEmulatorMode
roleInformation string
warning string
Résultat void

StopEmulators() public méthode

public StopEmulators ( string &warning ) : void
warning string
Résultat void