TriEngine  v0.0.16
General-purpose engine in C#/OpenGL
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events
TriDevs.TriEngine.Extensions.DecimalExtensions Class Reference

Extensions for System.Decimal. More...

Static Public Member Functions

static decimal Clamp (this decimal value, decimal min, decimal max)
 Clamps the specified decimal between a minimum and maximum value. More...
 

Detailed Description

Extensions for System.Decimal.

Member Function Documentation

static decimal TriDevs.TriEngine.Extensions.DecimalExtensions.Clamp ( this decimal  value,
decimal  min,
decimal  max 
)
static

Clamps the specified decimal between a minimum and maximum value.

Parameters
valueValue to clamp.
minIf the specified decimal is below this value, then this will be returned.
maxIf the specified decimal is above this value, then this will be returned.
Returns
The clamped value of the decimal.
39  {
40  return Helpers.Math.Clamp(value, min, max);
41  }

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following file: