C# Class GoogleCloudExtension.DataSources.InstanceExtensions

This class implements extension methods which implement behaviors on top of the instance models.
ファイルを表示 Open project: GoogleCloudPlatform/google-cloud-visualstudio

Public Methods

Method Description
GeneratePublishSettings ( this instance, string userName, string password ) : string

Generates the publishsettings information for a given GCE instance.

GetAppEngineFlexService ( this instance ) : string

Returns the App Engine Flex service for a GCE instance if it part of an App Engine Flex app.

GetAppEngineFlexVersion ( this instance ) : string

Returns the App Engine Flex version for a GCE instance that is part of an App Engine Flex app.

GetDestinationAppUri ( this instance ) : string

Determines the URL to use to see the ASP.NET app that runs on the given instance.

GetInternalIpAddress ( this instance ) : string

Returns the internal IP address for the instance.

GetMachineType ( this instance ) : string

Retruns the machine type based on the GCE machine type URL.

GetPublicIpAddress ( this instance ) : string

Returns the public IP address, if it exists, for the instance.

GetPublishUrl ( this instance ) : string

Determines the URL to use to publish to this server. Typically used for ASP.NET 4.x apps.

GetSqlServerPassword ( this instance ) : string

Returns the SQL server password stored in the instance's metadata.

GetTags ( this instance ) : string

Returns a string with all of the tags for the instance.

GetWindowsInstanceInfo ( this instance ) : WindowsInstanceInfo

Returns the instance information for this instance, if it is a Windows instance.

GetZoneName ( this instance ) : string

Returns the zone name where the instance is located.

HasSqlServerPassword ( this instance ) : bool

Returns whether the given instance has SQL server password defined or not.

IsAppEngineFlexInstance ( this instance ) : bool

Determines if the given instance is an App Engine Flex instance.

IsAspnetInstance ( this instance ) : bool

Determines if the given instance is an ASP.NET instance.

IsRunning ( this instance ) : bool

Returns whether the given instance is in the running state.

IsWindowsInstance ( this instance ) : bool

Determines if the given instance is a Windows instance.

Method Details

GeneratePublishSettings() public static method

Generates the publishsettings information for a given GCE instance.
public static GeneratePublishSettings ( this instance, string userName, string password ) : string
instance this The instance to inspect.
userName string The user name to use.
password string The passwod to use.
return string

GetAppEngineFlexService() public static method

Returns the App Engine Flex service for a GCE instance if it part of an App Engine Flex app.
public static GetAppEngineFlexService ( this instance ) : string
instance this The instance to inspect.
return string

GetAppEngineFlexVersion() public static method

Returns the App Engine Flex version for a GCE instance that is part of an App Engine Flex app.
public static GetAppEngineFlexVersion ( this instance ) : string
instance this The instance to inspect.
return string

GetDestinationAppUri() public static method

Determines the URL to use to see the ASP.NET app that runs on the given instance.
public static GetDestinationAppUri ( this instance ) : string
instance this The instance to check.
return string

GetInternalIpAddress() public static method

Returns the internal IP address for the instance.
public static GetInternalIpAddress ( this instance ) : string
instance this The instance to inspect.
return string

GetMachineType() public static method

Retruns the machine type based on the GCE machine type URL.
public static GetMachineType ( this instance ) : string
instance this The instance to inspect.
return string

GetPublicIpAddress() public static method

Returns the public IP address, if it exists, for the instance.
public static GetPublicIpAddress ( this instance ) : string
instance this The instance to inspect.
return string

GetPublishUrl() public static method

Determines the URL to use to publish to this server. Typically used for ASP.NET 4.x apps.
public static GetPublishUrl ( this instance ) : string
instance this The instance to check.
return string

GetSqlServerPassword() public static method

Returns the SQL server password stored in the instance's metadata.
public static GetSqlServerPassword ( this instance ) : string
instance this The the instance to check.
return string

GetTags() public static method

Returns a string with all of the tags for the instance.
public static GetTags ( this instance ) : string
instance this The instance to inspect.
return string

GetWindowsInstanceInfo() public static method

Returns the instance information for this instance, if it is a Windows instance.
public static GetWindowsInstanceInfo ( this instance ) : WindowsInstanceInfo
instance this The instance to inspect.
return WindowsInstanceInfo

GetZoneName() public static method

Returns the zone name where the instance is located.
public static GetZoneName ( this instance ) : string
instance this The the instance to check.
return string

HasSqlServerPassword() public static method

Returns whether the given instance has SQL server password defined or not.
public static HasSqlServerPassword ( this instance ) : bool
instance this The the instance to check.
return bool

IsAppEngineFlexInstance() public static method

Determines if the given instance is an App Engine Flex instance.
public static IsAppEngineFlexInstance ( this instance ) : bool
instance this The instance to check.
return bool

IsAspnetInstance() public static method

Determines if the given instance is an ASP.NET instance.
public static IsAspnetInstance ( this instance ) : bool
instance this The instance to check.
return bool

IsRunning() public static method

Returns whether the given instance is in the running state.
public static IsRunning ( this instance ) : bool
instance this The the instance to check.
return bool

IsWindowsInstance() public static method

Determines if the given instance is a Windows instance.
public static IsWindowsInstance ( this instance ) : bool
instance this The instance to check.
return bool