Method ClampToByte
- Namespace
- Zyl.VectorTraits.Numerics
- Assembly
- VectorTraits.dll
ClampToByte(int)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
public static byte ClampToByte(int value)
Parameters
valueintThe value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(uint)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
[CLSCompliant(false)]
public static byte ClampToByte(uint value)
Parameters
valueuintThe value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(long)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
public static byte ClampToByte(long value)
Parameters
valuelongThe value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(ulong)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
[CLSCompliant(false)]
public static byte ClampToByte(ulong value)
Parameters
valueulongThe value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(ExInt128)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
public static byte ClampToByte(ExInt128 value)
Parameters
valueExInt128The value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(ExUInt128)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
[CLSCompliant(false)]
public static byte ClampToByte(ExUInt128 value)
Parameters
valueExUInt128The value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(Int128)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
public static byte ClampToByte(Int128 value)
Parameters
valueInt128The value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).
ClampToByte(UInt128)
Returns value clamped to the inclusive range of 0 and byte.MaxValue (返回限制在 0 和 byte.MaxValue 范围内的 value).
[CLSCompliant(false)]
public static byte ClampToByte(UInt128 value)
Parameters
valueUInt128The value to be clamped (要限制的值).
Returns
- byte
Returns clamped value (返回限制后的值).