Namespaces

Functions

  • int64_t Divide (int64_t inDividend, int64_t inDivisor)

    Performs signed 64-bit divided by 64-bit operation and returns the quotient.

    Parameters

    inDividend [in] The dividend in this function.
    inDivisor [in] The divisor in this function.

    Returns

    The quotient of inDividend divided by inDivisor

  • uint32_t DivideBy1000 (uint64_t inDividend)

    Divide a 64-bit unsigned dividend by 1000 producing a 32-bit value.

    Parameters

    inDividend [in] 64-bit value to be divided
  • uint32_t RoundDown (uint32_t a, uint32_t b)

    Performs rounding towards 0.

    Parameters

    a [in] Value to be rounded.
    b [in] Rounding granularity.

    Returns

    Value rounded down to the nearest multiple of rounding granularity.

    Defined at line 70 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Support/MathUtils.h

  • uint32_t RoundUp (uint32_t a, uint32_t b)

    Performs rounding away from 0.

    Parameters

    a [in] Value to be rounded.
    b [in] Rounding granularity.

    Returns

    Value rounded up to the nearest multiple of rounding granularity.

    Defined at line 85 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Support/MathUtils.h

  • uint32_t BitsToByteLength (uint32_t aBits)

    Converts value length in bits to length in bytes.

    Parameters

    aBits [in] Value in bits to be converted to bytes.

    Returns

    Length in bytes.

    Defined at line 98 of file x64-shared/gen/third_party/openweave-core/src/include/Weave/Support/MathUtils.h