Skip to content

019a5306 fbe4 99fe 1afd 5c3ff989869b

Kim Hugener-Ohlsen edited this page May 28, 2016 · 2 revisions

SpatialExtensions.ToArea(TValue) Method

Gets the value as the specified unit.

Namespace: Sundew.Quantities.Spatial
Assembly: Sundew.Quantities (in Sundew.Quantities.dll) Version: 1.0.2.0 (1.0.2.0)

Syntax

C#

public static Area ToArea<TValue>(
	this TValue value,
	SelectUnit<DistanceUnitSelector> unitSelector
)
where TValue : struct, new(), IComparable, IFormattable

C#

public static Area ToArea<TValue>(
	this TValue value,
	SelectUnit<DistanceUnitSelector> unitSelector
)
where TValue : struct, new(), IComparable, IFormattable

VB

<ExtensionAttribute>
Public Shared Function ToArea(Of TValue As {Structure, New, IComparable, IFormattable}) ( 
	value As TValue,
	unitSelector As SelectUnit(Of DistanceUnitSelector)
) As Area

VB

<ExtensionAttribute>
Public Shared Function ToArea(Of TValue As {Structure, New, IComparable, IFormattable}) ( 
	value As TValue,
	unitSelector As SelectUnit(Of DistanceUnitSelector)
) As Area

C++

public:
[ExtensionAttribute]
generic<typename TValue>
where TValue : value class, gcnew(), IComparable, IFormattable
static Area^ ToArea(
	TValue value, 
	SelectUnit<DistanceUnitSelector^>^ unitSelector
)

C++

public:
[ExtensionAttribute]
generic<typename TValue>
where TValue : value class, gcnew(), IComparable, IFormattable
static Area^ ToArea(
	TValue value, 
	SelectUnit<DistanceUnitSelector^>^ unitSelector
)

F#

[<ExtensionAttribute>]
static member ToArea : 
        value : 'TValue * 
        unitSelector : SelectUnit<DistanceUnitSelector> -> Area  when 'TValue : struct, new() and IComparable and IFormattable

F#

[<ExtensionAttribute>]
static member ToArea : 
        value : 'TValue * 
        unitSelector : SelectUnit<DistanceUnitSelector> -> Area  when 'TValue : struct, new() and IComparable and IFormattable

Parameters

 

value
Type: TValue
The area value.
unitSelector
Type: Sundew.Quantities.Engine.UnitSelection.SelectUnit(DistanceUnitSelector)
The unit selector.

Type Parameters

 

TValue
The type of the value.

Return Value

Type: Area
A new Area.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type . When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also

Reference

SpatialExtensions Class
Sundew.Quantities.Spatial Namespace

Clone this wiki locally