BuildEnvironment.TryGetEnvironment Method

Checks whether it is possible to get the environment of the specified object.

Namespace: Microsoft.TeamFoundation.Build.Workflow
Assembly: Microsoft.TeamFoundation.Build.Workflow (in Microsoft.TeamFoundation.Build.Workflow.dll)


Public Shared Function TryGetEnvironment ( _
    instance As Object, _
    <OutAttribute> ByRef environment As HostEnvironmentOption _
) As Boolean
public static bool TryGetEnvironment(
    Object instance,
    out HostEnvironmentOption environment
static bool TryGetEnvironment(
    Object^ instance, 
    [OutAttribute] HostEnvironmentOption% environment
static member TryGetEnvironment : 
        instance:Object * 
        environment:HostEnvironmentOption byref -> bool
public static function TryGetEnvironment(
    instance : Object, 
    environment : HostEnvironmentOption
) : boolean


  • instance
    Type: System.Object

    The object of which the host environment is desired.

Return Value

Type: System.Boolean
True if it is possible to get the host environment of instance; otherwise, false.

.NET Framework Security

See Also


BuildEnvironment Class

Microsoft.TeamFoundation.Build.Workflow Namespace