Table of Contents:

Vidyo Legal Copyright Notice

Legend

[PRIVATE] Indicates an interface is private. Private interfaces are subject to change or may be entirely removed without notice. Use of such interfaces is not recommended.

[EXPERIMENTAL] Indicates an interface is experimental. Experimental interfaces represent work in progress and therefore may be incomplete and may be subject to change (both in terms of interface definition and the semantics the interface controls) or even removed entirely in subsequent releases. Use of experimental interfaces should be carefully weighed by the application writer.

[DEPRECATED] Indicates an interface has been deprecated. Deprecated interfaces are subject to removal in subsequent releases. Use of deprecated interfaces in new code is not recommended. Existing uses of deprecated interfaces should be removed as soon as possible.

[REPLACED BY interface ] Indicates an interface has been superseded by interface .

SYMBOLIC Indicates that the constant is a compile-time symbolic replacement of the constants value. Such constants can be used as global initializers, but can not have their address taken. Non-symbolic constant can not be used as global initializers, but can have their address taken.

REFERENCE COUNTED Indicates that objects of the type are reference counted. Calling ConstructCopy or Assign has reference semantics.

Package: Algorithms

Member Of:

Utils

Description:

A set of generic algorithms. Each operates on a range of elements or a pair of ranges.

Member Functions:

LmiAlgorithmFind Find the first item in range equal to the specified value.
LmiAlgorithmFindIf Find the first item in range equal to the specified value as determined by the predicate function.
LmiBinarySearch Find an element in a sorted sequence of elements.
LmiBinarySearchComp Find an element in a sorted sequence of elements.
LmiCopy Copy a range of items from one container to another.
LmiFill Fill a range of items of a container with the specified value.
LmiFillN Fill a range of items of a container with the specified value.
LmiLexicographicalCompare Do a lexicographical comparison of two sequences.
LmiLexicographicalCompareComp Do a lexicographical comparison of two sequences.
LmiMismatch Find the first place where two sequences differ.
LmiMismatchComp Find the first place where two sequences differ.
LmiPartition Partition a range of elements into two groups. The first group shall contain all the elements for which a supplied predicate returns true. The second group shall contain all the elements for which the predicate returns false. This is not a stable partition: the order of the elements in each group may change.
LmiRemoveIf Removes all the elements in a range matching a given condition. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.
LmiReverse Reverse a sequence of elements.
LmiSetIntersection Creates the intersection of two sorted sequences. Each element of the first sequence that has a corresponding equivalent element in the second sequence will appear in the output sequence. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then the first min(m,n) elements from the first sequence are written to the output.
LmiSetIntersectionComp Creates the intersection of two sorted sequences. Each element of the first sequence that has a corresponding equivalent element in the second sequence will appear in the output sequence. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then the first min(m,n) elements from the first sequence are written to the output.
LmiSetIntersectionWithDifferences Calculates simultaneously the set intersection and set differences of two sorted sequences. If all output containers are specified, then each input element will be copied to exactly one of the containers.
LmiSetIntersectionWithDifferencesComp Calculates simultaneously the set intersection and set differences of two sorted sequences. If all output containers are specified, then each input element will be copied to exactly one of the containers.
LmiSetUnion Creates the union of two sorted sequences. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then max(m,n) elements are written to the output. All m elements of the first sequence are written, and then if n>m the elements indexed m+1 through n of the second sequence are written.
LmiSetUnionComp Creates the union of two sorted sequences. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then max(m,n) elements are written to the output. All m elements of the first sequence are written, and then if n>m the elements indexed m+1 through n of the second sequence are written.
LmiSort Sort a range of items of a container.
LmiSortComp Sort a range of items of a container using a comparison function.
LmiUnique Removes adjacent equal elements from a range. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.
LmiUniqueComp Removes adjacent equivalent elements from a range. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.

Package: Allocators

Member Of:

Utils

Description:

Package containing various allocator implementations.

Member Types:

LmiAlignedAllocator Objects which allocate and deallocate memory aligned to a specific n-byte boundary.
LmiAllocator Objects which allocate and deallocate memory.

Package: Assert

Member Of:

Utils

Description:

Functions for asserting conditions.

Member Callbacks:

LmiAssertCallback Report a failing assertion, and terminate program execution.

Member Functions:

LmiAssertSetCallback Set a callback function to be invoked when an assertion fails.

Package: BasicTypes

Member Of:

Utils

Description:

Common base integer types.

Member Types:

LmiBool Boolean type.
LmiDistanceT The distance between two pointer values.
LmiFloat32 Basic 32-bit single precision floating point type.
LmiFloat64 Basic 64-bit double precision floating point type.
LmiInt Basic integer type.
LmiInt16 Basic 16-bit integer type.
LmiInt32 Basic 32-bit integer type.
LmiInt64 Basic 64-bit integer type.
LmiInt8 Basic 8-bit integer type.
LmiIntPtrT A signed integer type as big as an object pointer.
LmiSizeT The size of an object in memory.
LmiUint Basic unsigned integer type.
LmiUint16 Basic 16-bit unsigned integer type.
LmiUint32 Basic 32-bit unsigned integer type.
LmiUint64 Basic 64-bit unsigned integer type.
LmiUint8 Basic 8-bit unsigned integer type.
LmiUintPtrT An unsigned integer type as big as an object pointer.
LmiVoidPtr A generic object pointer.
LmiWideChar Wide character type, holding UCS4 (32-bit) Unicode characters.

Member Functions:

Package: Containers

Member Of:

Utils

Description:

A package of basic parameterized container classes.

Member Packages:

Member Types:

LmiStringVector LmiStringVector is an instantiation of LmiVector over LmiString.
LmiVector A parameterized vector container class.

Package: CrashHandler

Member Of:

Utils

Description:

Functions and callbacks for handling crashes.

Member Callbacks:

Member Functions:

Package: Iterators

Member Of:

Utils

Description:

A package of generalized pointer concepts.

Member Types:

LmiBaseIterator The base iterator concept.
LmiBidirectionalIterator The bidirectional iterator concept. Adds decrement property to the forward iterator concept.
LmiForwardIterator The forward iterator concept. Adds output properties to the input iterator concept.
LmiInputIterator The input iterator concept. Adds increment property to the trivial iterator concept.
LmiOutputIterator The output iterator concept. Adds increment and content-of properties to the base iterator concept.
LmiRandomAccessIterator The random access iterator concept. Adds less-than, at, increment-by-N, decrement-by-N, add, and subtract properties to the bidirectional iterator concept.
LmiReverseBidirectionalIterator The reverse bidirectional iterator concept.
LmiReverseRandomAccessIterator The reverse random access iterator concept.
LmiTrivialIterator The trivial iterator concept. Adds equality, exceptional state, and content-of properties to the base iterator concept.

Package: Utils

Member Of:

Lmi

Description:

A package of OS independent utility types, classes and functions.

Member Packages:

Algorithms A set of generic algorithms. Each operates on a range of elements or a pair of ranges.
Allocators Package containing various allocator implementations.
Assert Functions for asserting conditions.
BasicTypes Common base integer types.
Containers A package of basic parameterized container classes.
CrashHandler Functions and callbacks for handling crashes.
Iterators A package of generalized pointer concepts.

Member Types:

LmiCommandLineEnum Holds a name-value pair mapping an enumeration string to its integer value.
LmiCommandLineOption Represents an optional command line argument to search for in a program's argument vector.
LmiCommandLineParameter Represents a command line parameter in a program's argument vector.
LmiConstAccelMotionProfile A motion profile where the magnitude of the acceleration is either 0 or some fixed value.
LmiConstJerkMotionProfile A motion profile where the magnitude of the jerk (rate of change of acceleration) is either 0 or some fixed value.
LmiConstVelMotionProfile A constant velocity motion profile.
LmiDifferenceType The difference type of the container type T_.
LmiInitTable Holds an initialization function and its corresponding uninitialization function.
LmiLinearMotion Calculates points along a line in any number of dimensions. Given an LmiMotionProfile, this class can be used to calculate the position as a function of time for an object moving smoothly along a line.
LmiLinearProgramming This class implements the linear programming solver.
LmiLocation An object that represents a geographic location.
LmiMatrix A parameterized matrix class.
LmiMediaFormat Uniquely identifies a media format.
LmiMediaType Media type.
LmiMotionProfile Abstract base class used to customize the speed of an object as it travels along a path. This class allows the smoothness of an animation to be controlled independent of the actual path followed.
LmiMotionProfilePlugIn Object used for customizing the behavior of an LmiMotionProfile object.
LmiPair An object that contains two other objects, possibly of different types.
LmiPredicate The predicate concept. Given template parameter type X_, defines a type of pointer to function LmiBool (*)(const X_*, void*)
LmiProperty This class implements a Property.
LmiRectangle Defines a rectangular region on an integer grid. This is useful for representing rectangular regions of pixels on a screen.
LmiResolution Represents the dimensions of a rectangle.
LmiSizeType The size type of the container type T_.
LmiSourceType Describes the source type of a media stream.
LmiString Class representing C strings. Interface largely based on C++'s std::string class.
LmiUri Universal Resource Identifiers.
LmiVariableSimulator An object that simulates random variables with various distributions. Separate instances of this class may each have their own source of random bits. These sources may differ in the quality of the random numbers and the time required to generate them.
LmiVersion A data type that describes a version.
LmiWideString Class representing C wide strings. Interface largely based on C++'s std::wstring (i.e., std::basic_string<wchar_t>) class.

Member Functions:

LmiInitTableInitialize Calls the initialization functions specified in an LmiInitTable sequentially. If any initialization function returns LMI_FALSE, no further initialization functions are called and any initialization functions that have already returned LMI_TRUE are rolled back by calling the matching uninitialization functions in reverse order.
LmiInitTableInitializeEx An extension of LmiInitTableInitialize used to ensure that the initialization functions specified in an LmiInitTable are not called more than once (without intervening uninitializations).
LmiInitTableUninitialize Calls the uninitialization functions specified in an LmiInitTable in reverse order. This function will properly uninitialize all initialization done by a successful call to LmiInitTableInitialize taking the same parameters.
LmiInitTableUninitializeEx An extension of LmiInitTableUninitialize used to ensure that the initialization functions specified in an LmiInitTable are not called more than once (without intervening uninitializations).
LmiUtilsGetVersion Gets the version of the utilities library.
LmiUtilsGetVersionString Gets the version of the utilities library, as a human readable string.
LmiUtilsInitialize Initialize all operating-system-independent components of the Vidyo SDK.
LmiUtilsUninitialize Uninitialize all operating-system-independent components of the Vidyo SDK.

Type: LmiAlignedAllocator

Member Of:

Allocators

Description:

Objects which allocate and deallocate memory aligned to a specific n-byte boundary.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Member Functions:

LmiAlignedAllocatorConstruct Construct a new LmiAlignedAllocator.
LmiAlignedAllocatorConstructCopy ConstructCopy a new LmiAlignedAllocator.
LmiAlignedAllocatorDestruct Destruct an aligned allocator.
LmiAlignedAllocatorGetAlignment Obtain the alignment in bytes.
LmiAlignedAllocatorGetAllocator Get the aligned allocator's allocator.
LmiAlignedAllocatorGetBase Get the aligned allocator's base allocator.
LmiAlignedAllocatorGetMaxSize Obtain the size of the largest block of memory allocatable with a given allocator.

Type: LmiAllocator

Member Of:

Allocators

Description:

Objects which allocate and deallocate memory.

Include:

Lmi/Utils/LmiAllocator.h

Member Callbacks:

LmiAllocatorAllocateCallback Allocate memory using a given allocator.
LmiAllocatorDeallocateCallback Free memory previously allocated with the given allocator.

Member Functions:

LmiAllocatorAllocate Allocate memory from a given allocator.
LmiAllocatorConstruct Construct an LmiAllocator.
LmiAllocatorDeallocate Deallocate memory previously allocated with the given allocator.
LmiAllocatorDestruct Destruct an LmiAllocator.
LmiAllocatorGetMaxSize Obtain the size of the largest block of memory allocatable with a given allocator.
LmiAllocatorGetUserData Get an allocator's user data.

Type: LmiBaseIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Description:

The base iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Member Functions:

LmiBaseIteratorAssign Copy one iterator to another.
LmiBaseIteratorConstructCopy Constructs an iterator from another iterator.
LmiBaseIteratorDestruct Destructs an iterator.
LmiBaseIteratorSwap Swap two iterators.

Type: LmiBidirectionalIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiForwardIterator

Description:

The bidirectional iterator concept. Adds decrement property to the forward iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Member Functions:

LmiBidirectionalIteratorDecrement Decrements the iterator to point at the previous object in the container. No checking is perform to ensure that the iterator is in range of the container after the operation.

Type: LmiBool

Member Of:

BasicTypes

Description:

Boolean type.

Include:

Lmi/Utils/LmiTypes.h

Values:

LMI_FALSE A false value of LmiBool.
LMI_TRUE A true value of LmiBool.

Member Functions:

LmiBoolAssign Assign the value of one LmiBool object to another one.
LmiBoolConstruct Construct a default instance of an LmiBool object.
LmiBoolConstructCopy Construct a new LmiBool object as a copy of an existing one.
LmiBoolDestruct Destruct an LmiBool object.
LmiBoolEqual Compare the values of two LmiBool objects for equality.
LmiBoolLess Compare the values of two LmiBool objects for ordering.
LmiBoolSwap Swap the contents of two LmiBool objects.

Type: LmiCommandLineEnum

Member Of:

Utils

Description:

Holds a name-value pair mapping an enumeration string to its integer value.

Include:

Lmi/Utils/LmiCommandLineOption.h

Member Variables:

name const char * The enumeration name.
value LmiInt The enumeration value.

Type: LmiCommandLineOption

Member Of:

Utils

Description:

Represents an optional command line argument to search for in a program's argument vector.

Include:

Lmi/Utils/LmiCommandLineOption.h

Member Types:

LmiCommandLineOptionParseStatus Indicates the status of a call to LmiCommandLineOptionParse.

Member Functions:

LmiCommandLineOptionConstruct Constructs a command line option.
LmiCommandLineOptionConstructBoolean Constructs a command line option that has no parameters.
LmiCommandLineOptionConstructBooleanEx Constructs a command line option that has no parameters.
LmiCommandLineOptionConstructEnum Constructs a command line option that has one parameter that is an enumerated type.
LmiCommandLineOptionConstructEx Constructs a command line option.
LmiCommandLineOptionConstructInteger Constructs a command line option that has one unsigned integer parameter.
LmiCommandLineOptionConstructIntegerRange Constructs a command line option that has one unsigned integer parameter. The integer must lie within a specified range.
LmiCommandLineOptionConstructSignedInteger Constructs a command line option that has one signed integer parameter.
LmiCommandLineOptionConstructSignedIntegerRange Constructs a command line option that has one signed integer parameter. The integer must lie within a specified range.
LmiCommandLineOptionConstructString Constructs a command line option that has one string parameter.
LmiCommandLineOptionDestruct Destructs a command line option.
LmiCommandLineOptionGetTag Gets the name of a command line option.
LmiCommandLineOptionParse Search for optional command line arguments in a program's argument vector.

Type: LmiCommandLineOptionParseStatus

Member Of:

LmiCommandLineOption

Description:

Indicates the status of a call to LmiCommandLineOptionParse.

Include:

Lmi/Utils/LmiCommandLineOption.h

Values:

LMI_COMMANDLINEOPTIONPARSESTATUS_SUCCESS The parse was successful. The parse terminated either because all arguments were parsed, or the next argument found did not match any of the command line options.
LMI_COMMANDLINEOPTIONPARSESTATUS_MISSINGPARAMETER The parse failed. A command line option was expected to be followed by one or more parameters, but there were not enough parameters present.
LMI_COMMANDLINEOPTIONPARSESTATUS_INVALIDPARAMETER The parse failed. A command line option expected a parameter to be of a certain format, but the parameter did not parse successfully. This could be: An integer parameter was expected but the parameter was not numeric. An enumerated type was expected but the parameter did not match any of the allowed values.
LMI_COMMANDLINEOPTIONPARSESTATUS_OUTOFRANGE The parse failed. A command line option expected an integer parameter within a certain range, but the parameter was not within the range.

Type: LmiCommandLineParameter

Member Of:

Utils

Description:

Represents a command line parameter in a program's argument vector.

Include:

Lmi/Utils/LmiCommandLineOption.h

Member Functions:

LmiCommandLineParameterConstructEnum Constructs a command line parameter expecting one of a fixed set of strings. Each string has an associated integer value. This object can be used to retrieve a value for an enumerated type.
LmiCommandLineParameterConstructInteger Constructs a command line parameter expecting an unsigned integer for input.
LmiCommandLineParameterConstructIntegerRange Constructs a command line parameter expecting an unsigned integer for input. The integer must lie within a specified range.
LmiCommandLineParameterConstructSignedInteger Constructs a command line parameter expecting a signed integer for input.
LmiCommandLineParameterConstructSignedIntegerRange Constructs a command line parameter expecting a signed integer for input. The integer must lie within a specified range.
LmiCommandLineParameterConstructString Constructs a command line parameter expecting string input.
LmiCommandLineParameterDestruct Destructs a command line parameter object.

Type: LmiConstAccelMotionProfile

Member Of:

Utils

Derivation Of:

LmiMotionProfile

Description:

A motion profile where the magnitude of the acceleration is either 0 or some fixed value.

Include:

Lmi/Utils/LmiMotionProfile.h

Member Functions:

LmiConstAccelMotionProfileConstruct Constructs an LmiConstAccelMotionProfile object with default parameters. The acceleration and deceleration stages will each be 1/4 of the total time for the move.
LmiConstAccelMotionProfileConstructEx Constructs an LmiConstAccelMotionProfile object with custom parameters.
LmiConstAccelMotionProfileDestruct Destructs an LmiConstAccelMotionProfile object.
LmiConstAccelMotionProfileGetBase Returns the LmiMotionProfile base class pointer for an LmiConstAccelMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.
LmiConstAccelMotionProfileGetDefault Returns an LmiConstAccelMotionProfile object with default parameters.

Type: LmiConstJerkMotionProfile

Member Of:

Utils

Derivation Of:

LmiMotionProfile

Description:

A motion profile where the magnitude of the jerk (rate of change of acceleration) is either 0 or some fixed value.

Include:

Lmi/Utils/LmiMotionProfile.h

Member Functions:

LmiConstJerkMotionProfileConstruct Constructs an LmiConstJerkMotionProfile object with default parameters. The acceleration and deceleration stages will each be 3/8 of the total time for the move. The periods of nonzero jerk will each be 1/8 of the total time for the move.
LmiConstJerkMotionProfileConstructEx Constructs an LmiConstJerkMotionProfile object with custom parameters.
LmiConstJerkMotionProfileDestruct Destructs an LmiConstJerkMotionProfile object.
LmiConstJerkMotionProfileGetBase Returns the LmiMotionProfile base class pointer for an LmiConstJerkMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.
LmiConstJerkMotionProfileGetDefault Returns an LmiConstJerkMotionProfile object with default parameters.

Type: LmiConstVelMotionProfile

Member Of:

Utils

Derivation Of:

LmiMotionProfile

Description:

A constant velocity motion profile.

Include:

Lmi/Utils/LmiMotionProfile.h

Member Functions:

LmiConstVelMotionProfileConstruct Constructs an LmiConstVelMotionProfile object.
LmiConstVelMotionProfileDestruct Destructs an LmiConstVelMotionProfile object.
LmiConstVelMotionProfileGetBase Returns the LmiMotionProfile base class pointer for an LmiConstVelMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.
LmiConstVelMotionProfileGetDefault Returns an LmiConstVelMotionProfile object with default parameters.

Type: LmiDifferenceType (T_)

Member Of:

Utils

Description:

The difference type of the container type T_.

Include:

Lmi/Utils/LmiNames.h

Template Parameters:

T_ The container type.

Type: LmiDistanceT

Member Of:

BasicTypes

Description:

The distance between two pointer values.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiDistanceTAssign Assign the value of one LmiDistanceT object to another one.
LmiDistanceTConstruct Construct a default instance of an LmiDistanceT object.
LmiDistanceTConstructCopy Construct a new LmiDistanceT object as a copy of an existing one.
LmiDistanceTDestruct Destruct an LmiDistanceT object.
LmiDistanceTEqual Compare the values of two LmiDistanceT objects for equality.
LmiDistanceTLess Compare the values of two LmiDistanceT objects for ordering.
LmiDistanceTSwap Swap the contents of two LmiDistanceT objects.

Note 1:

This is an unsigned integer type.

Type: LmiFloat32

Member Of:

BasicTypes

Description:

Basic 32-bit single precision floating point type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiFloat32Assign Assign the value of one LmiFloat32 object to another one.
LmiFloat32Construct Construct a default instance of an LmiFloat32 object.
LmiFloat32ConstructCopy Construct a new LmiFloat32 object as a copy of an existing one.
LmiFloat32Destruct Destruct an LmiFloat32 object.
LmiFloat32Equal Compare the values of two LmiFloat32 objects for equality.
LmiFloat32Less Compare the values of two LmiFloat32 objects for ordering.
LmiFloat32Swap Swap the contents of two LmiFloat32 objects.

Type: LmiFloat64

Member Of:

BasicTypes

Description:

Basic 64-bit double precision floating point type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiFloat64Assign Assign the value of one LmiFloat64 object to another one.
LmiFloat64Construct Construct a default instance of an LmiFloat64 object.
LmiFloat64ConstructCopy Construct a new LmiFloat64 object as a copy of an existing one.
LmiFloat64Destruct Destruct an LmiFloat64 object.
LmiFloat64Equal Compare the values of two LmiFloat64 objects for equality.
LmiFloat64Less Compare the values of two LmiFloat64 objects for ordering.
LmiFloat64Swap Swap the contents of two LmiFloat64 objects.

Type: LmiForwardIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiInputIterator

Description:

The forward iterator concept. Adds output properties to the input iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Type: LmiInitTable

Member Of:

Utils

Description:

Holds an initialization function and its corresponding uninitialization function.

Include:

Lmi/Utils/LmiMisc.h

Member Variables:

init LmiBool (*)(void) The initialization function. The function should return LMI_TRUE on success and LMI_FALSE on failure. A value of NULL is equivalent to an empty function returning LMI_TRUE.
uninit void (*)(void) The uninitialization function. A value of NULL is equivalent to an empty function.

Type: LmiInputIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiTrivialIterator

Description:

The input iterator concept. Adds increment property to the trivial iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Member Functions:

LmiInputIteratorIncrement Increments the iterator to point at the next object in the container. No checking is performed to ensure that the iterator is in range of the container after the operation.

Type: LmiInt

Member Of:

BasicTypes

Description:

Basic integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiIntAbsoluteValue Get the absolute value of an integer.
LmiIntAssign Assign the value of one LmiInt object to another one.
LmiIntConstruct Construct a default instance of an LmiInt object.
LmiIntConstructCopy Construct a new LmiInt object as a copy of an existing one.
LmiIntDestruct Destruct an LmiInt object.
LmiIntEqual Compare the values of two LmiInt objects for equality.
LmiIntLess Compare the values of two LmiInt objects for ordering.
LmiIntSwap Swap the contents of two LmiInt objects.

Type: LmiInt16

Member Of:

BasicTypes

Description:

Basic 16-bit integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiInt16Assign Assign the value of one LmiInt16 object to another one.
LmiInt16Construct Construct a default instance of an LmiInt16 object.
LmiInt16ConstructCopy Construct a new LmiInt16 object as a copy of an existing one.
LmiInt16Destruct Destruct an LmiInt16 object.
LmiInt16Equal Compare the values of two LmiInt16 objects for equality.
LmiInt16Less Compare the values of two LmiInt16 objects for ordering.
LmiInt16Swap Swap the contents of two LmiInt16 objects.

Type: LmiInt32

Member Of:

BasicTypes

Description:

Basic 32-bit integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiInt32Assign Assign the value of one LmiInt32 object to another one.
LmiInt32Construct Construct a default instance of an LmiInt32 object.
LmiInt32ConstructCopy Construct a new LmiInt32 object as a copy of an existing one.
LmiInt32Destruct Destruct an LmiInt32 object.
LmiInt32Equal Compare the values of two LmiInt32 objects for equality.
LmiInt32Less Compare the values of two LmiInt32 objects for ordering.
LmiInt32Swap Swap the contents of two LmiInt32 objects.

Type: LmiInt64

Member Of:

BasicTypes

Description:

Basic 64-bit integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiInt64Assign Assign the value of one LmiInt64 object to another one.
LmiInt64Construct Construct a default instance of an LmiInt64 object.
LmiInt64ConstructCopy Construct a new LmiInt64 object as a copy of an existing one.
LmiInt64Destruct Destruct an LmiInt64 object.
LmiInt64Equal Compare the values of two LmiInt64 objects for equality.
LmiInt64Less Compare the values of two LmiInt64 objects for ordering.
LmiInt64Swap Swap the contents of two LmiInt64 objects.

Type: LmiInt8

Member Of:

BasicTypes

Description:

Basic 8-bit integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiInt8Assign Assign the value of one LmiInt8 object to another one.
LmiInt8Construct Construct a default instance of an LmiInt8 object.
LmiInt8ConstructCopy Construct a new LmiInt8 object as a copy of an existing one.
LmiInt8Destruct Destruct an LmiInt8 object.
LmiInt8Equal Compare the values of two LmiInt8 objects for equality.
LmiInt8Less Compare the values of two LmiInt8 objects for ordering.
LmiInt8Swap Swap the contents of two LmiInt8 objects.

Type: LmiIntPtrT

Member Of:

BasicTypes

Description:

A signed integer type as big as an object pointer.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiIntPtrTAssign Assign the value of one LmiIntPtrT object to another one.
LmiIntPtrTConstruct Construct a default instance of an LmiIntPtrT object.
LmiIntPtrTConstructCopy Construct a new LmiIntPtrT object as a copy of an existing one.
LmiIntPtrTDestruct Destruct an LmiIntPtrT object.
LmiIntPtrTEqual Compare the values of two LmiIntPtrT objects for equality.
LmiIntPtrTLess Compare the values of two LmiIntPtrT objects for ordering.
LmiIntPtrTSwap Swap the contents of two LmiIntPtrT objects.

Type: LmiLinearMotion

Member Of:

Utils

Description:

Calculates points along a line in any number of dimensions. Given an LmiMotionProfile, this class can be used to calculate the position as a function of time for an object moving smoothly along a line.

Include:

Lmi/Utils/LmiLinearMotion.h

Member Functions:

LmiLinearMotionConstruct Constructs an LmiLinearMotion object. This defines the number of axes and the initial position of the moving object.
LmiLinearMotionDestruct Destructs an LmiLinearMotion object.
LmiLinearMotionGetPosition Gets the current position of a moving object as a function of time.
LmiLinearMotionMoveTo Move in a straight line to a new position in a specified amount of time.
LmiLinearMotionSetPosition Sets the current position for an LmiLinearMotion object. This terminates any move in progress and instantaneously moves the object to a new position.

Type: LmiLinearProgramming

Member Of:

Utils

Description:

This class implements the linear programming solver.

Include:

Lmi/Utils/LmiLinearProgramming.h

Member Types:

LmiLinearProgrammingConstraint This class represents a linear programming constraint.
LmiLinearProgrammingResultType This class represents linear programming result.
LmiLinearProgrammingVariable This class represents linear programming variable.
LmiLinearProgrammingVariableAccessType This class represents variable access type.
LmiLinearProgrammingVariableType This class represents linear programming variable type.

Member Functions:

LmiLinearProgrammingConstruct Construct a linear programming object.
LmiLinearProgrammingConstructDefault Construct a default linear programming object.
LmiLinearProgrammingDestruct Destruct the linear programming object.
LmiLinearProgrammingGetNumConstraints Get number of decision variables on linear programming object.
LmiLinearProgrammingGetNumVars Get number of decision variables on linear programming object.
LmiLinearProgrammingGetObjectiveValue Get the object value of linear programming problem solution.
LmiLinearProgrammingGetVariableValues Get the decision variable values of linear programming problem solution.
LmiLinearProgrammingRemoveConstraint Remove a constraint by id from the linear programming object.
LmiLinearProgrammingSetConstraint Set a constraint by id to the linear programming object.
LmiLinearProgrammingSetConstraintByIndex Set a constraint by index of variables to the linear programming object.
LmiLinearProgrammingSetConstraintByName Set constraint by name of variables on the linear programming object.
LmiLinearProgrammingSetNumVars Set number of decision variables on linear programming object.
LmiLinearProgrammingSetObjective Set the objective coefficients of decision variables by names to the linear programming object.
LmiLinearProgrammingSetObjectiveByIndex Set the objective coefficients of decision variables by index to the linear programming object.
LmiLinearProgrammingSetVariableInfo Set variable names to decision variables of linear programming object.
LmiLinearProgrammingSolve Solve the linear programming problem.

Type: LmiLinearProgrammingConstraint

Member Of:

LmiLinearProgramming

Description:

This class represents a linear programming constraint.

Include:

Lmi/Utils/LmiLinearProgramming.h

Member Functions:

LmiLinearProgrammingConstraintAssign Assign a linear programming constraint object from another object.
LmiLinearProgrammingConstraintConstruct Construct a linear programming constraint object by providing variable coefficients by name of variables.
LmiLinearProgrammingConstraintConstructCopy Construct copy a linear programming constraint object from another object.
LmiLinearProgrammingConstraintConstructIndex Construct a linear programming constraint object by providing variable coefficients by index.
LmiLinearProgrammingConstraintDestruct Destruct the linear programming constraint object.
LmiLinearProgrammingConstraintEqual Check for the equality of two linear programming constraint objects.
LmiLinearProgrammingConstraintGetRhs Get the RHS of the linear programming constraint.
LmiLinearProgrammingConstraintGetVariableAccessType Get variable access type of the linear programming constraint object.
LmiLinearProgrammingConstraintGetVariablesCoefficientsByIndex Get the variable coefficients of the linear programming constraint object by index of variables.
LmiLinearProgrammingConstraintGetVariablesCoefficientsByName Get the variable coefficients of the linear programming constraint object by name of variables.
LmiLinearProgrammingConstraintLess Check whether a linear programming constraint object is less than another object.

Type: LmiLinearProgrammingResultType

Member Of:

LmiLinearProgramming

Description:

This class represents linear programming result.

Include:

Lmi/Utils/LmiLinearProgramming.h

Type: LmiLinearProgrammingVariable

Member Of:

LmiLinearProgramming

Description:

This class represents linear programming variable.

Include:

Lmi/Utils/LmiLinearProgramming.h

Member Functions:

LmiLinearProgrammingVariableAssign Assign a linear programming variable object from another object.
LmiLinearProgrammingVariableConstruct Construct a linear programming variable object.
LmiLinearProgrammingVariableConstructCopy Construct copy a linear programming variable object from another object.
LmiLinearProgrammingVariableConstructDefault Construct a default linear programming variable object.
LmiLinearProgrammingVariableDestruct Destruct the linear programming variable object.
LmiLinearProgrammingVariableEqual Check for the equality of two linear programming variable objects.
LmiLinearProgrammingVariableGetIndex Get index of the linear programming variable object.
LmiLinearProgrammingVariableGetName Get name of the linear programming variable object.
LmiLinearProgrammingVariableGetType Get type of the linear programming variable object.
LmiLinearProgrammingVariableLess Check whether a linear programming variable object is less than another object.
LmiLinearProgrammingVariableSetIndex Set index on the linear programming variable object.
LmiLinearProgrammingVariableSetName Set name on the linear programming variable object.
LmiLinearProgrammingVariableSetType Set type on the linear programming variable object.

Type: LmiLinearProgrammingVariableAccessType

Member Of:

LmiLinearProgramming

Description:

This class represents variable access type.

Include:

Lmi/Utils/LmiLinearProgramming.h

Type: LmiLinearProgrammingVariableType

Member Of:

LmiLinearProgramming

Description:

This class represents linear programming variable type.

Include:

Lmi/Utils/LmiLinearProgramming.h

Type: LmiLocation

Member Of:

Utils

Description:

An object that represents a geographic location.

Include:

Lmi/Utils/LmiLocation.h

Member Functions:

LmiLocationAssign Assign one geographic location object the value of another.
LmiLocationConstruct Construct an LmiLocation object.
LmiLocationConstructCopy Construct a geographic location object as a copy of an existing object.
LmiLocationConstructDefault Construct an LmiLocation object with an arbitrary location.
LmiLocationDestruct Destruct an LmiLocation object.
LmiLocationGetAltitude Get the altitude from a geographic location object.
LmiLocationGetLatitude Get the latitude from a geographic location object.
LmiLocationGetLongitude Get the longitude from a geographic location object.

Type: LmiMatrix (T_)

Member Of:

Utils

Description:

A parameterized matrix class.

Include:

Lmi/Utils/LmiMatrix.h

Template Parameters:

T_ The type of matrix elements.

Member Functions:

Declare_LmiMatrix Declare a parameterized matrix.
Define_LmiMatrix Define a parameterized matrix.
LmiMatrixAdd Add two matrices.
LmiMatrixAssign Copy one matrix to another.
LmiMatrixAt Retrieve a pointer to the element of the matrix at index row,col .
LmiMatrixConstruct Construct a matrix.
LmiMatrixConstructCopy Construct a matrix from another matrix.
LmiMatrixConstructCopyRange Construct a matrix as a sub-matrix of another matrix.
LmiMatrixConstructDefault Construct an empty matrix.
LmiMatrixConstructIdentity Construct an identity matrix.
LmiMatrixCopyRange Construct a matrix as a sub-matrix of another matrix.
LmiMatrixDestruct Destruct a matrix.
LmiMatrixEqual Test two matrices for equality.
LmiMatrixGetAllocator Gets a pointer to the matrix's allocator.
LmiMatrixGetNumColumns Get the number of columns of the matrix.
LmiMatrixGetNumRows Get the number of rows of the matrix.
LmiMatrixInverse Inverse a matrix.
LmiMatrixLess Test whether one matrix is lexicographically less than another.
LmiMatrixMultiply Multiply two matrices.
LmiMatrixMultiplyScalar Multiply a matrix by a scalar.
LmiMatrixReset Reset of content of the matrix.
LmiMatrixResize Resize a matrix.
LmiMatrixSetVal Set the value of an element of the matrix at index row,col .
LmiMatrixSubtract Subtract two matrices.
LmiMatrixSwap Swap two matrices.
LmiMatrixSwapColumn Swap a column of two matrices.
LmiMatrixSwapRow Swap a row of two matrices.
LmiMatrixTranspose Transpose a matrix.

Note 1:

The macro Declare_LmiMatrix must be called before declaring an object of this type.

Type: LmiMediaFormat

Member Of:

Utils

Description:

Uniquely identifies a media format.

Include:

Lmi/Utils/LmiMediaFormat.h

Constants:

LMI_MEDIAFORMAT_NULL SYMBOLIC LmiMediaFormat Media format for null (empty) objects.
LMI_MEDIAFORMAT_WPCM SYMBOLIC LmiMediaFormat Media Format for FourCC 'WPCM' data.
LMI_MEDIAFORMAT_I420 SYMBOLIC LmiMediaFormat Media Format for FourCC 'I420' data.
LMI_MEDIAFORMAT_YU12 SYMBOLIC LmiMediaFormat Media Format for FourCC 'YU12' data.
LMI_MEDIAFORMAT_YUYV SYMBOLIC LmiMediaFormat Media Format for FourCC 'YUYV' data.
LMI_MEDIAFORMAT_YUY2 SYMBOLIC LmiMediaFormat Media Format for FourCC 'YUY2' data.
LMI_MEDIAFORMAT_yuvs SYMBOLIC LmiMediaFormat Media Format for FourCC 'YUY2' data.
LMI_MEDIAFORMAT_2vuy SYMBOLIC LmiMediaFormat Media Format for FourCC 'yuvs' data.
LMI_MEDIAFORMAT_UYVY SYMBOLIC LmiMediaFormat Media Format for FourCC '2vuy' data.
LMI_MEDIAFORMAT_HDYC SYMBOLIC LmiMediaFormat Media Format for FourCC 'HDYC' data.
LMI_MEDIAFORMAT_yuv2 SYMBOLIC LmiMediaFormat Media Format for FourCC 'yuv2' data.
LMI_MEDIAFORMAT_yuvu SYMBOLIC LmiMediaFormat Media Format for FourCC 'yuvu' data.
LMI_MEDIAFORMAT_NV12 SYMBOLIC LmiMediaFormat Media Format for FourCC 'NV12' data.
LMI_MEDIAFORMAT_NV21 SYMBOLIC LmiMediaFormat Media Format for FourCC 'NV21' data.
LMI_MEDIAFORMAT_24BG SYMBOLIC LmiMediaFormat Media Format for FourCC '24BG' data.
LMI_MEDIAFORMAT_raw SYMBOLIC LmiMediaFormat Media Format for FourCC 'raw ' data.
LMI_MEDIAFORMAT_BGRA SYMBOLIC LmiMediaFormat Media Format for FourCC 'BGRA' data.
LMI_MEDIAFORMAT_RGBA SYMBOLIC LmiMediaFormat Media Format for FourCC 'RGBA' data.
LMI_MEDIAFORMAT_ARGB SYMBOLIC LmiMediaFormat Media Format for FourCC 'ARGB' data.
LMI_MEDIAFORMAT_BYR1 SYMBOLIC LmiMediaFormat Media Format for FourCC 'BYR1' data.
LMI_MEDIAFORMAT_BYR2 SYMBOLIC LmiMediaFormat Media Format for FourCC 'BYR2' data.
LMI_MEDIAFORMAT_JPEG SYMBOLIC LmiMediaFormat Media Format for FourCC 'JPEG' data.
LMI_MEDIAFORMAT_MJPG SYMBOLIC LmiMediaFormat Media Format for FourCC 'MJPG' data.
LMI_MEDIAFORMAT_dmb1 SYMBOLIC LmiMediaFormat Media Format for FourCC 'dmb1' data.
LMI_MEDIAFORMAT_dvsd SYMBOLIC LmiMediaFormat Media Format for FourCC 'dvsd' data.
LMI_MEDIAFORMAT_dvhd SYMBOLIC LmiMediaFormat Media Format for FourCC 'dvhd' data.
LMI_MEDIAFORMAT_dvsl SYMBOLIC LmiMediaFormat Media Format for FourCC 'dvsl' data.
LMI_MEDIAFORMAT_dv25 SYMBOLIC LmiMediaFormat Media Format for FourCC 'dv25' data.
LMI_MEDIAFORMAT_dv50 SYMBOLIC LmiMediaFormat Media Format for FourCC 'dv50' data.
LMI_MEDIAFORMAT_dvh1 SYMBOLIC LmiMediaFormat Media Format for FourCC 'dvh1' data.
LMI_MEDIAFORMAT_dv SYMBOLIC LmiMediaFormat Media Format for FourCC 'dv ' data.
LMI_MEDIAFORMAT_M420 SYMBOLIC LmiMediaFormat Media Format for FourCC 'M420' data.
LMI_MEDIAFORMAT_420f SYMBOLIC LmiMediaFormat Media Format for FourCC '420f' data.
LMI_MEDIAFORMAT_420v SYMBOLIC LmiMediaFormat Media Format for FourCC '420v' data.
LMI_MEDIAFORMAT_Y8 SYMBOLIC LmiMediaFormat Media Format for FourCC 'Y8 ' data.
LMI_MEDIAFORMAT_in16 SYMBOLIC LmiMediaFormat Media Format for FourCC 'in16' data: PCM audio in 16-bit signed integer in native byte order.
LMI_MEDIAFORMAT_fl32 SYMBOLIC LmiMediaFormat Media Format for FourCC 'fl32' data: PCM audio in 32-bit native single-precision floating-point.
lmiMediaFormat_NULL LmiMediaFormat Media format for null (empty) objects.
lmiMediaFormat_WPCM LmiMediaFormat Media Format for FourCC 'WPCM' data.
lmiMediaFormat_I420 LmiMediaFormat Media Format for FourCC 'I420' data.
lmiMediaFormat_YU12 LmiMediaFormat Media Format for FourCC 'YU12' data.
lmiMediaFormat_YUYV LmiMediaFormat Media Format for FourCC 'YUYV' data.
lmiMediaFormat_YUY2 LmiMediaFormat Media Format for FourCC 'YUY2' data.
lmiMediaFormat_yuvs LmiMediaFormat Media Format for FourCC 'YUY2' data.
lmiMediaFormat_2vuy LmiMediaFormat Media Format for FourCC 'yuvs' data.
lmiMediaFormat_UYVY LmiMediaFormat Media Format for FourCC '2vuy' data.
lmiMediaFormat_HDYC LmiMediaFormat Media Format for FourCC 'HDYC' data.
lmiMediaFormat_yuv2 LmiMediaFormat Media Format for FourCC 'yuv2' data.
lmiMediaFormat_yuvu LmiMediaFormat Media Format for FourCC 'yuvu' data.
lmiMediaFormat_NV12 LmiMediaFormat Media Format for FourCC 'NV12' data.
lmiMediaFormat_NV21 LmiMediaFormat Media Format for FourCC 'NV21' data.
lmiMediaFormat_24BG LmiMediaFormat Media Format for FourCC '24BG' data.
lmiMediaFormat_raw LmiMediaFormat Media Format for FourCC 'raw ' data.
lmiMediaFormat_BGRA LmiMediaFormat Media Format for FourCC 'BGRA' data.
lmiMediaFormat_RGBA LmiMediaFormat Media Format for FourCC 'RGBA' data.
lmiMediaFormat_ARGB LmiMediaFormat Media Format for FourCC 'ARGB' data.
lmiMediaFormat_BYR1 LmiMediaFormat Media Format for FourCC 'BYR1' data.
lmiMediaFormat_BYR2 LmiMediaFormat Media Format for FourCC 'BYR2' data.
lmiMediaFormat_JPEG LmiMediaFormat Media Format for FourCC 'JPEG' data.
lmiMediaFormat_MJPG LmiMediaFormat Media Format for FourCC 'MJPG' data.
lmiMediaFormat_dmb1 LmiMediaFormat Media Format for FourCC 'dmb1' data.
lmiMediaFormat_dvsd LmiMediaFormat Media Format for FourCC 'dvsd' data.
lmiMediaFormat_dvhd LmiMediaFormat Media Format for FourCC 'dvhd' data.
lmiMediaFormat_dvsl LmiMediaFormat Media Format for FourCC 'dvsl' data.
lmiMediaFormat_dv25 LmiMediaFormat Media Format for FourCC 'dv25' data.
lmiMediaFormat_dv50 LmiMediaFormat Media Format for FourCC 'dv50' data.
lmiMediaFormat_dvh1 LmiMediaFormat Media Format for FourCC 'dvh1' data.
lmiMediaFormat_dv LmiMediaFormat Media Format for FourCC 'dv ' data.
lmiMediaFormat_M420 LmiMediaFormat Media Format for FourCC 'M420' data.
lmiMediaFormat_420f LmiMediaFormat Media Format for FourCC '420f' data.
lmiMediaFormat_420v LmiMediaFormat Media Format for FourCC '420v' data.
lmiMediaFormat_Y8 LmiMediaFormat Media Format for FourCC 'Y8 ' data.
lmiMediaFormat_in16 LmiMediaFormat Media Format for FourCC 'in16' data: PCM audio in 16-bit signed integer in native byte order.
lmiMediaFormat_fl32 LmiMediaFormat Media Format for FourCC 'fl32' data: PCM audio in 32-bit native single-precision floating-point.

Member Functions:

LmiMediaFormatAssign Copy the content of one media format object to another.
LmiMediaFormatConstruct Constructs a media format object and initializes it from a FourCC value.
LmiMediaFormatConstructCopy Construct a media format object from another media format instance.
LmiMediaFormatConstructFromCStr Constructs a media format object from a C string representation of a FourCC value.
LmiMediaFormatConstructFromNative Constructs a media format object and initializes it from a native-format FourCC value.
LmiMediaFormatDestruct Destructs a media format object.
LmiMediaFormatEqual Compares two media format objects for equality.
LmiMediaFormatLess Checks if the media format x is less than media format y
LmiMediaFormatSwap Swap the content of one media format object with another.
LmiMediaFormatToCStr Converts a media format object to a C string representation of a FourCC value.
LmiMediaFormatToFourCC Converts a media format object to a FourCC value.
LmiMediaFormatToNativeFourCC Converts a media format object to a native-format FourCC value.

Note 1:

The "LMI_MEDIAFORMAT_" constants are compile-time symbolic constants (suitable for initializers); the "lmiMediaFormat_" constants are constant objects (so pointers to them can be passed to functions).

Type: LmiMediaType

Member Of:

Utils

Description:

Media type.

Include:

Lmi/Utils/LmiMediaType.h

Values:

LMI_MEDIATYPE_Audio audio
LMI_MEDIATYPE_Video video
LMI_MEDIATYPE_Application application
LMI_MEDIATYPE_Message message
LMI_MEDIATYPE_Text text

Type: LmiMotionProfile

Member Of:

Utils

Description:

Abstract base class used to customize the speed of an object as it travels along a path. This class allows the smoothness of an animation to be controlled independent of the actual path followed.

Include:

Lmi/Utils/LmiMotionProfile.h

Member Functions:

LmiMotionProfileConstructBase Constructs an LmiMotionProfile object. Use this function when creating an object of a class derived from LmiMotionProfile.
LmiMotionProfileDestruct Destructs an LmiMotionProfile object.
LmiMotionProfileGetPosition Gets the fraction of the total distance traveled as a function of the fraction of total time elapsed.

Type: LmiMotionProfilePlugIn

Member Of:

Utils

Description:

Object used for customizing the behavior of an LmiMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Member Callbacks:

LmiMotionProfilePlugInGetPositionCallback A callback returning the fraction of the total distance traveled as a function of the fraction of total time elapsed. This callback can be used to customize the smoothness of a motion. Other effects can be also be achieved, such as overshooting the target and snapping back to it. The function should return 0 at t=0 and 1 at t=1. A continuous function should be used in most instances, otherwise the animated object will appear to be teleported.

Member Functions:

LmiMotionProfilePlugInConstruct Constructs an LmiMotionProfilePlugIn object.
LmiMotionProfilePlugInDestruct Destructs an LmiMotionProfilePlugIn object.

Type: LmiOutputIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiBaseIterator

Description:

The output iterator concept. Adds increment and content-of properties to the base iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Type: LmiPair (T1_, T2_)

Member Of:

Utils

Description:

An object that contains two other objects, possibly of different types.

Include:

Lmi/Utils/LmiUtility.h

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Member Variables:

first T1_ The first item of the pair.
second T2_ The second item of the pair.

Member Functions:

LmiPairAssign Assign the value of one pair to another pair.
LmiPairConstruct Constructs a pair.
LmiPairConstructCopy Constructs a pair, initializing it with the value of another pair.
LmiPairDestruct Destructs a pair.
LmiPairEqual Compare two pairs for equality.
LmiPairLess Compare whether one pair is lexicographically less than another.
LmiPairSwap Swap the value of two pairs.

Type: LmiPredicate (X_)

Member Of:

Utils

Description:

The predicate concept. Given template parameter type X_, defines a type of pointer to function LmiBool (*)(const X_*, void*)

Include:

Lmi/Utils/LmiConcepts.h

Template Parameters:

X_ The value type of the predicate.

Note 1:

The macro Declare_LmiPredicate must be called before declaring an object of this type.

Type: LmiProperty

Member Of:

Utils

Description:

This class implements a Property.

Include:

Lmi/Utils/LmiProperty.h

Member Functions:

LmiPropertyAssign Assignment operator.
LmiPropertyConstruct Constructor with initial values.
LmiPropertyConstructCStr Constructor with initial values (in CStr format).
LmiPropertyConstructCopy Copy constructor.
LmiPropertyDestruct Destructor.
LmiPropertyGetName To get the name of an LmiProperty object.
LmiPropertyGetNameCStr To get the name of an LmiProperty object in CStr format.
LmiPropertyGetValue To get the value of an LmiProperty object.
LmiPropertyGetValueCStr To get the value of an LmiProperty object in CStr format.
LmiPropertyIsEqual To check whether the name of the LmiProperty object matches the given string.
LmiPropertyIsEqualCStr To check whether the name of the LmiProperty object matches the given string (in CStr format).
LmiPropertySetValue To change the value of an LmiProperty object.
LmiPropertySetValueCStr To change the value of an LmiProperty object.

Type: LmiRandomAccessIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiBidirectionalIterator

Description:

The random access iterator concept. Adds less-than, at, increment-by-N, decrement-by-N, add, and subtract properties to the bidirectional iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Member Functions:

LmiRandomAccessIteratorAdd Return an iterator to the element n elements from the iterator.
LmiRandomAccessIteratorAt Retrieve a pointer to an element of the iterator's value type at an offset from the iterator.
LmiRandomAccessIteratorDecrementN Decrement the iterator by n .
LmiRandomAccessIteratorIncrementN Increment the iterator by n .
LmiRandomAccessIteratorLess Test whether one iterator is lexicographically less than another.
LmiRandomAccessIteratorSubtract Find the distance between two iterators.

Type: LmiRectangle

Member Of:

Utils

Description:

Defines a rectangular region on an integer grid. This is useful for representing rectangular regions of pixels on a screen.

Include:

Lmi/Utils/LmiRectangle.h

Member Functions:

LmiRectangleAssign Assigns one LmiRectangle object the value of another.
LmiRectangleClip Reduce the size of a rectangle such that it does not intersect another rectangle. This may be useful for calculating the new shape of a window when it is desired to keep the whole window visible in the presence of another screen element. If there is more than one way to accomplish this, the resulting rectangle with the largest area is chosen. If there is no way to do this (because the rectangle r lies entirely within the other rectangle), then r is left unchanged.
LmiRectangleConstruct Constructs a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.
LmiRectangleConstructCopy Constructs an LmiRectangle object as a copy of another.
LmiRectangleConstructDefault Constructs a rectangle.
LmiRectangleConstructMaxAndSize Constructs a rectangle by specifying the maximum values for each coordinate, and also the rectangle's width and height.
LmiRectangleConstructMinAndMax Constructs a rectangle by specifying the minimum and maximum values for each coordinate.
LmiRectangleConstructMinAndSize Constructs a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.
LmiRectangleContains Determine if a point is located within a rectangle. Note that points lying on the rectangle's maximum x and y coordinates will be considered outside the rectangle. When the rectangle is used to represent a grid of pixels, this convention ensures that the proper number of pixels are determined to lie within the rectangle.
LmiRectangleDestruct Destructs an LmiRectangle object.
LmiRectangleEnclose Finds the smallest rectangle that contains two specified rectangles.
LmiRectangleEqual Checks whether two rectangles are equivalent, meaning they have the same size and location.
LmiRectangleGetArea Gets the area of a rectangle.
LmiRectangleGetBottom Gets the maximum y coordinate for a rectangle. When the rectangle represents a region in a coordinate system whose y values increase as you move downward, this value corresponds to the bottom edge of the rectangle.
LmiRectangleGetHeight Gets the height of a rectangle.
LmiRectangleGetLeft Gets the x coordinate of the left edge of a rectangle.
LmiRectangleGetMaxX Gets the maximum x coordinate for a rectangle.
LmiRectangleGetMaxY Gets the maximum y coordinate for a rectangle.
LmiRectangleGetMinX Gets the minimum x coordinate for a rectangle.
LmiRectangleGetMinY Gets the minimum y coordinate for a rectangle.
LmiRectangleGetRight Gets the x coordinate of the right edge of a rectangle.
LmiRectangleGetTop Gets the minimum y coordinate for a rectangle. When the rectangle represents a region in a coordinate system whose y values increase as you move downward, this value corresponds to the top edge of the rectangle.
LmiRectangleGetWidth Gets the width of a rectangle.
LmiRectangleIntersect Finds the intersection between two rectangles.
LmiRectangleIntersects Determines if two rectangles intersect. Rectangles are considered intersecting if they have nonzero common area. Two rectangles sharing boundaries only will not be considered intersecting.
LmiRectangleMoveTo Moves a rectangle without changing its size. Specify the new minimum values for each coordinate.
LmiRectangleMoveToMax Moves a rectangle without changing its size. Specify the new maximum values for each coordinate.
LmiRectangleMoveToMin Moves a rectangle without changing its size. Specify the new minimum values for each coordinate.
LmiRectangleResizeFromMax Resizes a rectangle, keeping the maximum values for each coordinate unchanged. The minimum values are adjusted as necessary.
LmiRectangleResizeFromMin Resizes a rectangle, keeping the minimum values for each coordinate unchanged. The maximum values are adjusted as necessary.
LmiRectangleResizeToAspectRatio Resizes a rectangle so that it has the specified aspect ratio. The center position of the rectangle is left unchanged.
LmiRectangleScale Scale a rectangle by a constant factor. Both its position and size are scaled by this amount.
LmiRectangleSetBottom Changes the maximum y coordinate. The minimum y coordinate is left unchanged. If a new value is provided, the height of the rectangle will change.
LmiRectangleSetHeight Changes the height of a rectangle, keeping the minimum y coordinate unchanged. The maximum y coordinate is adjusted as necessary.
LmiRectangleSetLeft Changes the minimum x coordinate. The maximum x coordinate is left unchanged. If a new value is provided, the width of the rectangle will change.
LmiRectangleSetMax Changes the maximum values for each coordinate. The minimum values are left unchanged. If new maximum values are provided, the size of the rectangle will change.
LmiRectangleSetMaxAndSize Modifies a rectangle by specifying the maximum values for each coordinate, and also the rectangle's width and height.
LmiRectangleSetMin Changes the minimum values for each coordinate. The maximum values are left unchanged. If new minimum values are provided, the size of the rectangle will change.
LmiRectangleSetMinAndMax Modifies a rectangle by specifying the minimum and maximum values for each coordinate.
LmiRectangleSetMinAndSize Modifies a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.
LmiRectangleSetRight Changes the maximum x coordinate. The minimum x coordinate is left unchanged. If a new value is provided, the width of the rectangle will change.
LmiRectangleSetTop Changes the minimum y coordinate. The maximum y coordinate is left unchanged. If a new value is provided, the height of the rectangle will change.
LmiRectangleSetWidth Changes the width of a rectangle, keeping the minimum x coordinate unchanged. The maximum x coordinate is adjusted as necessary.

Type: LmiResolution

Member Of:

Utils

Description:

Represents the dimensions of a rectangle.

Include:

Lmi/Utils/LmiResolution.h

Member Functions:

LmiResolutionAssign To assign an instance of LmiResolution to another instance
LmiResolutionConstruct To construct an instance of an LmiResolution object.
LmiResolutionConstructCopy Construct a LmiResolution object from another instance.
LmiResolutionDestruct To destruct a LmiResolution.
LmiResolutionGetHeight Get height from LmiResolution.
LmiResolutionGetWidth Get width from LmiResolution.
LmiResolutionSetHeight To modify height in a LmiResolution
LmiResolutionSetWidth To modify width in a LmiResolution

Type: LmiReverseBidirectionalIterator (X_, F_, T_)

Member Of:

Iterators

Description:

The reverse bidirectional iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (reverse iterator type).
F_ The forward iterator type upon which the reverse iterator is to be based.
T_ The value type of the iterator.

Member Functions:

LmiReverseBidirectionalIteratorAssign Copy one iterator to another.
LmiReverseBidirectionalIteratorConstructCopy Constructs an iterator from another iterator.
LmiReverseBidirectionalIteratorConstructExceptional Constructs an exception iterator. Exceptional iterators are used to indicate failure in cases where the normal return is an iterator.
LmiReverseBidirectionalIteratorContentOf Gets the content of the object pointed to by the iterator.
LmiReverseBidirectionalIteratorContentOfConst Gets the read-only content of the object pointed to by the iterator.
LmiReverseBidirectionalIteratorDecrement Decrements the iterator to point at the previous object in the reverse container. No checking is perform to ensure that the iterator is in range of the container after the operation.
LmiReverseBidirectionalIteratorDestruct Destructs an iterator.
LmiReverseBidirectionalIteratorEqual Compares two iterators for equality.
LmiReverseBidirectionalIteratorIncrement Increments the iterator to point at the next object in the reverse container. No checking is perform to ensure that the iterator is in range of the container after the operation.
LmiReverseBidirectionalIteratorIsExceptional Determines whether or not the iterator has encountered an exception.
LmiReverseBidirectionalIteratorSwap Swap two iterators.

Type: LmiReverseRandomAccessIterator (X_, F_, T_)

Member Of:

Iterators

Description:

The reverse random access iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (reverse iterator type).
F_ The forward iterator type upon which the reverse iterator is to be based.
T_ The value type of the iterator.

Member Functions:

LmiReverseRandomAccessIteratorAdd Return an iterator to the element n elements from the iterator.
LmiReverseRandomAccessIteratorAt Retrieve a pointer to an element of the iterator's value type at an offset from the iterator.
LmiReverseRandomAccessIteratorDecrementN Decrement the iterator by n .
LmiReverseRandomAccessIteratorIncrementN Increment the iterator by n .
LmiReverseRandomAccessIteratorLess Test whether one iterator is lexicographically less than another.
LmiReverseRandomAccessIteratorSubtract Find the distance between two iterators.

Type: LmiSizeT

Member Of:

BasicTypes

Description:

The size of an object in memory.

Include:

Lmi/Utils/LmiTypes.h

Constants:

LMI_SIZET_MAX SYMBOLIC LmiSizeT The maximum value of an LmiSizeT.
LMI_SIZE_T_MAX SYMBOLIC [REPLACED BY LMI_SIZET_MAX] LmiSizeT The maximum value of an LmiSizeT (deprecated).

Member Functions:

LmiSizeTAssign Assign the value of one LmiSizeT object to another one.
LmiSizeTConstruct Construct a default instance of an LmiSizeT object.
LmiSizeTConstructCopy Construct a new LmiSizeT object as a copy of an existing one.
LmiSizeTDestruct Destruct an LmiSizeT object.
LmiSizeTEqual Compare the values of two LmiSizeT objects for equality.
LmiSizeTLess Compare the values of two LmiSizeT objects for ordering.
LmiSizeTSwap Swap the contents of two LmiSizeT objects.

Note 1:

This is an unsigned integer type.

Type: LmiSizeType (T_)

Member Of:

Utils

Description:

The size type of the container type T_.

Include:

Lmi/Utils/LmiNames.h

Template Parameters:

T_ The container type.

Type: LmiSourceType

Member Of:

Utils

Description:

Describes the source type of a media stream.

Include:

Lmi/Utils/LmiSourceType.h

Values:

LMI_SOURCETYPE_InteractiveAudio An interactive audio source.
LMI_SOURCETYPE_NoninteractiveAudio A non-interactive audio source.
LMI_SOURCETYPE_InteractiveVideo An interactive video source.
LMI_SOURCETYPE_NoninteractiveVideo A non-interactive video source (a.k.a. content).
LMI_SOURCETYPE_InteractiveOther An interactive application-specific source type.
LMI_SOURCETYPE_NoninteractiveOther A non-interactive application-specific source type.

Type: LmiString

Member Of:

Utils

Description:

Class representing C strings. Interface largely based on C++'s std::string class.

Include:

Lmi/Utils/LmiString.h

Constants:

LMI_STRING_NPOS SYMBOLIC LmiSizeT For value parameters, an invalid value used to represent "no position".

Member Types:

LmiStringConstIterator The read-only iterator type of a string.
LmiStringConstReverseIterator The read-only reverse iterator type of a string.
LmiStringIterator The iterator type of a string.
LmiStringReverseIterator The reverse iterator type of a string.

Member Functions:

LmiStringAppend Append the contents of one LmiString to another.
LmiStringAppendCStr Append a NUL-terminated C string to an LmiString.
LmiStringAppendCStrLen Append a C string of a given length to an LmiString.
LmiStringAppendChar Append a single character to an LmiString.
LmiStringAppendFormatted Append a printf-style formatted string to an LmiString.
LmiStringAppendN Append multiple copies of a character to an LmiString.
LmiStringAppendRange Append a range of characters to a string.
LmiStringAppendSubstring Append a substring of one LmiString to another.
LmiStringAppendUcs4 Append the UTF8-encoded values of a UCS4-encoded wide C string to a string.
LmiStringAppendUtf16 Append the UTF8-encoded values of a UTF16-encoded C string to a string.
LmiStringAppendVFormatted Append a vprintf-style formatted string to an LmiString.
LmiStringAssign Assign the value of one LmiString to another. The previous data stored in the destination is overwritten.
LmiStringAssignCStr Assign a NUL-terminated C string as the new value of an LmiString.
LmiStringAssignCStrLen Assign a C string of a given length as the new value of an LmiString.
LmiStringAssignChar Assign a single character as the new value of an LmiString.
LmiStringAssignFormatted Assign a printf-style formatted string as the new value of an LmiString.
LmiStringAssignRange Assign a range of characters as the new value of an LmiString.
LmiStringAssignSubstring Assign a substring of one LmiString as the new value of another.
LmiStringAssignUcs4 Assign a string to have the UTF8-encoded values of a UCS4-encoded wide C string.
LmiStringAssignUtf16 Assign a string to have the UTF8-encoded values of a UTF16-encoded C string.
LmiStringAssignVFormatted Assign a vprintf-style formatted string as the new value of an LmiString.
LmiStringAt Get a pointer to the character stored at a specific position in a string.
LmiStringAtConst Get a constant pointer to the character stored at a specific position in a string.
LmiStringBack Return a pointer to the last character in a string.
LmiStringBackConst Return a pointer to the last character in a const string.
LmiStringBegin Get an iterator referring to the beginning of a string.
LmiStringBeginConst Get an iterator referring to the beginning of a const string.
LmiStringCStr Get a NUL-terminated C string corresponding to the contents of a string.
LmiStringCapacity Get the size of the allocated storage of an LmiString.
LmiStringClear Erase the contents of a string.
LmiStringCompare Compare the values of two LmiStrings for ordering.
LmiStringCompareCStr Compare the value of an LmiString with that of a C string for ordering.
LmiStringCompareCStrLen Compare the value of an LmiString with that of a C string of a given length for ordering.
LmiStringConstructCStr Construct an LmiString based on a NUL-terminated C string.
LmiStringConstructCStrLen Construct an LmiString based on a C string of a given length.
LmiStringConstructCopy Construct a copy of an LmiString.
LmiStringConstructDefault Construct an empty LmiString.
LmiStringConstructFormatted Construct an LmiString based on a printf-style formatted string.
LmiStringConstructRange Construct an LmiString based on a range of another LmiString.
LmiStringConstructSubstring Construct an LmiString based on a substring of another LmiString.
LmiStringConstructUcs4 Construct a string to have the UTF8-encoded values of a UCS4-encoded wide C string.
LmiStringConstructUtf16 Construct a string to have the UTF8-encoded values of a UTF16-encoded C string.
LmiStringConstructVFormatted Construct an LmiString based on a vprintf-style formatted string.
LmiStringData Get a read-only buffer corresponding to the contents of a string.
LmiStringDestruct Destruct an LmiString, freeing all associated storage.
LmiStringEmpty Determine whether a string is empty.
LmiStringEnd Get an iterator referring to the end of a string.
LmiStringEndConst Get an iterator referring to the end of a const string.
LmiStringEqual Compare the values of two LmiStrings for equality.
LmiStringEqualCStr Compare the value of an LmiString with that of a C string for equality.
LmiStringEqualCStrLen Compare the value of an LmiString with that of a C string of a given length for equality.
LmiStringErase Remove a single character from a string.
LmiStringEraseRange Remove a range from a string.
LmiStringEraseSubstring Remove a substring from a string.
LmiStringFind Find a substring.
LmiStringFindCStr Find a substring.
LmiStringFindCStrLen Find a substring.
LmiStringFindFirstNotOf Find first location in a string where one of the characters in a second string does not occur.
LmiStringFindFirstNotOfCStr Find first location in a string where one of the characters in a C string does not occur.
LmiStringFindFirstNotOfChar Find first location in a string where a given character does not occur.
LmiStringFindFirstOf Find first location in a string where one of the characters in a second string occurs.
LmiStringFindFirstOfCStr Find first location in a string where one of the characters in a C string occurs.
LmiStringFindFirstOfChar Find first location in a string where a given character occurs.
LmiStringFindLastNotOfCStr Find last location in a string where one of the characters in a C string does not occur.
LmiStringFindLastNotOfChar Find last location in a string where a given character does not occur.
LmiStringFindLastOfCStr Find last location in a string where one of the characters in a C string occurs.
LmiStringFindLastOfChar Find last location in a string where a given character occurs.
LmiStringFront Return a pointer to the first character in a string.
LmiStringFrontConst Return a pointer to the first character in a const string.
LmiStringGetAllocator Get the allocator of an LmiString.
LmiStringGetBuffer Get a writeable buffer into which data can be written outside the control of the LmiString object.
LmiStringHash Hashes a string into an integer.
LmiStringInsert Insert a single character into a string.
LmiStringInsertCStr Insert a NUL-terminated C string into an LmiString.
LmiStringInsertCStrLen Insert a C string of a given length into an LmiString.
LmiStringInsertChar Insert a single character in an LmiString.
LmiStringInsertFormatted Insert a printf-style formatted string into an LmiString.
LmiStringInsertRange Insert a range of characters into a string.
LmiStringInsertString Insert the contents of one LmiString into another.
LmiStringInsertSubstring Insert part of the content of one LmiString into another.
LmiStringInsertVFormatted Insert a vprintf-style formatted string into an LmiString.
LmiStringLength Get the length of an LmiString.
LmiStringLess Compare the values of two LmiStrings for ordering.
LmiStringMaxSize Get the maximum supported length of an LmiString.
LmiStringPopBack Pop a single character from the end of a string.
LmiStringPushBack Push a single character onto the end of a string.
LmiStringRBegin Get a reverse iterator referring to the reversed beginning (end) of a string.
LmiStringRBeginConst Get an iterator referring to the reversed beginning (end) of a const string.
LmiStringREnd Get an iterator referring to the reversed end (beginning) of a string.
LmiStringREndConst Get an iterator referring to the reversed end (beginning) of a const string.
LmiStringReleaseBuffer Release a writeable buffer previously acquired with LmiStringGetBuffer.
LmiStringReplaceCStr Replace part of an LmiString with a C string.
LmiStringReplaceCStrLen Replace part of an LmiString with a C string of a given length.
LmiStringReplaceChar Replace part of an LmiString with a single character.
LmiStringReplaceFormatted Replace part of an LmiString with a printf-style formatted string.
LmiStringReplaceRange Replace a range of an LmiString with a different range of string iterators.
LmiStringReplaceString Replace part of an LmiString with another LmiString.
LmiStringReplaceSubstring Replace part of an LmiString with part of another LmiString.
LmiStringReplaceVFormatted Replace part of an LmiString with a vprintf-style formatted string.
LmiStringReserve Reserve storage for a string.
LmiStringResize Alters the length of an LmiString, either by truncating it or extending it.
LmiStringSize Get the size of an LmiString.
LmiStringSwap Swap the values of two LmiStrings.
LmiStringWriteUtf16 Encode the contents of a string as UTF-16 into a buffer.

Type: LmiStringConstIterator

Member Of:

LmiString

Description:

The read-only iterator type of a string.

Include:

Lmi/Utils/LmiString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiStringConstReverseIterator

Member Of:

LmiString

Description:

The read-only reverse iterator type of a string.

Include:

Lmi/Utils/LmiString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiStringIterator

Member Of:

LmiString

Description:

The iterator type of a string.

Include:

Lmi/Utils/LmiString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiStringReverseIterator

Member Of:

LmiString

Description:

The reverse iterator type of a string.

Include:

Lmi/Utils/LmiString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiStringVector

Member Of:

Containers

Description:

LmiStringVector is an instantiation of LmiVector over LmiString.

Include:

Lmi/Utils/LmiStringVector.h

Member Functions:

LmiStringVectorAdd To add an element to an LmiStringVector object. Optionally, check for uniqueness while adding.
LmiStringVectorAddCStr To add an element in C-string format to an LmiStringVector object. Optionally, check for uniqueness while adding.
LmiStringVectorIsAMember To test the membership in an LmiStringVector.
LmiStringVectorIsAMemberCStr To test the membership (of a C-style string) in an LmiStringVector.
LmiStringVectorRemove To remove an element from an LmiStringVector object.
LmiStringVectorRemoveCStr To remove an element (specified as a C-string) from an LmiStringVector object.

Note 1:

See LmiVector, and the STL std::vector template, for descriptions of LmiStringVector's member functions.

Type: LmiTrivialIterator (X_, T_, CT_, D_)

Member Of:

Iterators

Derivation Of:

LmiBaseIterator

Description:

The trivial iterator concept. Adds equality, exceptional state, and content-of properties to the base iterator concept.

Include:

Lmi/Utils/LmiIterators.h

Template Parameters:

X_ The model name (iterator type).
T_ The value type of the iterator.
CT_ The read-only value type of the iterator.
D_ The distance type of the iterator.

Member Functions:

LmiTrivialIteratorConstructExceptional Constructs an exception iterator. Exceptional iterators are used to indicate failure in cases where the normal return is an iterator.
LmiTrivialIteratorContentOf Gets the content of the object pointed to by the iterator.
LmiTrivialIteratorContentOfConst Gets the read-only content of the object pointed to by the iterator.
LmiTrivialIteratorEqual Compares two iterators for equality.
LmiTrivialIteratorIsExceptional Determines whether or not the iterator has encountered an exception.

Type: LmiUint

Member Of:

BasicTypes

Description:

Basic unsigned integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiUintAssign Assign the value of one LmiUint object to another one.
LmiUintConstruct Construct a default instance of an LmiUint object.
LmiUintConstructCopy Construct a new LmiUint object as a copy of an existing one.
LmiUintDestruct Destruct an LmiUint object.
LmiUintEqual Compare the values of two LmiUint objects for equality.
LmiUintLess Compare the values of two LmiUint objects for ordering.
LmiUintSwap Swap the contents of two LmiUint objects.

Type: LmiUint16

Member Of:

BasicTypes

Description:

Basic 16-bit unsigned integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiUint16Assign Assign the value of one LmiUint16 object to another one.
LmiUint16Construct Construct a default instance of an LmiUint16 object.
LmiUint16ConstructCopy Construct a new LmiUint16 object as a copy of an existing one.
LmiUint16Destruct Destruct an LmiUint16 object.
LmiUint16Equal Compare the values of two LmiUint16 objects for equality.
LmiUint16Less Compare the values of two LmiUint16 objects for ordering.
LmiUint16Swap Swap the contents of two LmiUint16 objects.

Type: LmiUint32

Member Of:

BasicTypes

Description:

Basic 32-bit unsigned integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiUint32Assign Assign the value of one LmiUint32 object to another one.
LmiUint32Construct Construct a default instance of an LmiUint32 object.
LmiUint32ConstructCopy Construct a new LmiUint32 object as a copy of an existing one.
LmiUint32Destruct Destruct an LmiUint32 object.
LmiUint32Equal Compare the values of two LmiUint32 objects for equality.
LmiUint32Less Compare the values of two LmiUint32 objects for ordering.
LmiUint32Swap Swap the contents of two LmiUint32 objects.

Type: LmiUint64

Member Of:

BasicTypes

Description:

Basic 64-bit unsigned integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LMI_INT64_C A macro that expands to a signed 64-bit integer constant.
LMI_UINT64_C A macro that expands to an unsigned 64-bit integer constant.
LmiUint64Assign Assign the value of one LmiUint64 object to another one.
LmiUint64Construct Construct a default instance of an LmiUint64 object.
LmiUint64ConstructCopy Construct a new LmiUint64 object as a copy of an existing one.
LmiUint64Destruct Destruct an LmiUint64 object.
LmiUint64Equal Compare the values of two LmiUint64 objects for equality.
LmiUint64Less Compare the values of two LmiUint64 objects for ordering.
LmiUint64Swap Swap the contents of two LmiUint64 objects.

Type: LmiUint8

Member Of:

BasicTypes

Description:

Basic 8-bit unsigned integer type.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiUint8Assign Assign the value of one LmiUint8 object to another one.
LmiUint8Construct Construct a default instance of an LmiUint8 object.
LmiUint8ConstructCopy Construct a new LmiUint8 object as a copy of an existing one.
LmiUint8Destruct Destruct an LmiUint8 object.
LmiUint8Equal Compare the values of two LmiUint8 objects for equality.
LmiUint8Less Compare the values of two LmiUint8 objects for ordering.
LmiUint8Swap Swap the contents of two LmiUint8 objects.

Type: LmiUintPtrT

Member Of:

BasicTypes

Description:

An unsigned integer type as big as an object pointer.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiUintPtrTAssign Assign the value of one LmiUintPtrT object to another one.
LmiUintPtrTConstruct Construct a default instance of an LmiUintPtrT object.
LmiUintPtrTConstructCopy Construct a new LmiUintPtrT object as a copy of an existing one.
LmiUintPtrTDestruct Destruct an LmiUintPtrT object.
LmiUintPtrTEqual Compare the values of two LmiUintPtrT objects for equality.
LmiUintPtrTLess Compare the values of two LmiUintPtrT objects for ordering.
LmiUintPtrTSwap Swap the contents of two LmiUintPtrT objects.

Type: LmiUri

Member Of:

Utils

Description:

Universal Resource Identifiers.

Include:

Lmi/Utils/LmiUri.h

Member Functions:

LmiUriAddAuthorityParameter Gets an authority parameter from a URI by name.
LmiUriAddPath Adds a path to a URI.
LmiUriAddPathParameter Adds a parameter into a given path index of a URI.
LmiUriAddQueryParameter Adds a query parameter into a given URI.
LmiUriAppendPathQueryFragmentToString Appends the path query and fragment components of a URI to the LmiString.
LmiUriAppendPathToString Appends the full path of a URI without parameters or a leading slash to the LmiString.
LmiUriAppendToString Appends the encoding of a URI to an LmiString.
LmiUriAsStr Encodes a URI to a buffer.
LmiUriAsString Encodes a URI to an LmiString.
LmiUriAssign Assigns the value of one URI object to another
LmiUriCStr Gets the URI as an CStr.
LmiUriClearAuthorityParameters Removes all parameters from a URI.
LmiUriConstruct Constructs a URI object.
LmiUriConstructCStr Constructs a URI object from a NULL-terminated C string representation of that URI.
LmiUriConstructCopy Constructs a URI object as a copy of an existing URI object.
LmiUriConstructDefault Constructs a default LmiUri object.
LmiUriConstructStr Constructs a URI object based on a LMI string representation of that URI.
LmiUriDestruct Destructs a URI object
LmiUriEqual Compares two URI objects for equality
LmiUriGetAddress Gets the address portion of a URI.
LmiUriGetAddressStr Gets the address portion of a URI as an LmiString.
LmiUriGetAuthority Gets the authority of a URI in a buffer.
LmiUriGetAuthorityParameter Gets an authority parameter from a URI by name.
LmiUriGetAuthorityParameterStr Gets an authority parameter from a URI by name.
LmiUriGetAuthorityStr Gets the authority of a URI as an LmiString.
LmiUriGetFragment Gets the fragment field from a URI object.
LmiUriGetFragmentStr Gets the fragment field from a URI object as an LmiString.
LmiUriGetHost Gets the host name from a URI.
LmiUriGetHostStr Gets the host name from a URI as an LmiString.
LmiUriGetName Gets the name field from a URI object.
LmiUriGetNameStr Gets the name field from a URI object as an LmiString.
LmiUriGetPathCount Gets the number of paths in a URI.
LmiUriGetPathName Gets the name of a path in a URI by index.
LmiUriGetPathNameStr Gets the name of a path in a URI by index.
LmiUriGetPathParameter Gets a parameter of a path with the position index and a name from a URI.
LmiUriGetPathParameterStr Gets a parameter of a path with the position index and a name from a URI.
LmiUriGetPort Gets the port number from a URI.
LmiUriGetQueryCount Gets the number of queries in a URI.
LmiUriGetQueryName Gets the name of a query in a URI by index.
LmiUriGetQueryNameStr Gets the name of a query in a URI by index.
LmiUriGetQueryParameter Gets a parameter from a query in a URI by name.
LmiUriGetQueryParameterStr Gets a parameter from a query in a URI by name.
LmiUriGetScheme Gets the scheme of a URI.
LmiUriGetSchemeStr Gets the scheme of a URI as an LmiString.
LmiUriSetFragment Sets the fragment field in a URI object.
LmiUriSetHost Sets the host name in a URI.
LmiUriSetName Sets the name field in a URI object.
LmiUriSetPort Sets the port number in a URI.
LmiUriSetScheme Sets the scheme field in a URI object.
LmiUriString Gets the URI as an LmiString.

Type: LmiVariableSimulator

Member Of:

Utils

Description:

An object that simulates random variables with various distributions. Separate instances of this class may each have their own source of random bits. These sources may differ in the quality of the random numbers and the time required to generate them.

Include:

Lmi/Utils/LmiRandomVars.h

Member Functions:

LmiVariableSimulatorGetDiscreteUniform Simulate a discrete uniform variable. Each of the values between 0 and (n-1) inclusive are equally likely to be selected.
LmiVariableSimulatorGetDiscreteUniformInRange Simulate a discrete uniform variable. Each of the values between min_ and max_ inclusive are equally likely to be selected.
LmiVariableSimulatorGetExponential Simulate a random variable with an exponential distribution. This distribution may be useful to model events that happen independently and with a constant average rate.
LmiVariableSimulatorGetStandardUniform Simulate a standard uniform variable. This is a continuous uniform variable over the range 0 to 1.
LmiVariableSimulatorGetUniform Simulate a continuous uniform variable over a specified range.

Type: LmiVector (T_)

Member Of:

Containers

Description:

A parameterized vector container class.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Member Types:

LmiVectorConstIterator The read-only iterator type of a vector.
LmiVectorConstReverseIterator The read-only reverse iterator type of a vector.
LmiVectorDifferenceType The difference type of a vector. It is equivalent to the type LmiDistanceT.
LmiVectorIterator The iterator type of a vector.
LmiVectorReverseIterator The reverse iterator type of a vector.
LmiVectorSizeType The size type of a vector. It is equivalent to the type LmiSizeT.

Member Functions:

Declare_LmiVector Declare a parameterized vector container and its subtypes.
Define_LmiVector Define a parameterized vector container and its subtypes.
LmiVectorAssign Copy one vector to another.
LmiVectorAt Retrieve a pointer to the element of the vector at index n .
LmiVectorAtConst Retrieve a read-only pointer to the element of the vector at index n .
LmiVectorBack Retrieve a pointer to the last element of the vector.
LmiVectorBackConst Retrieve a read-only pointer to the last element of the vector.
LmiVectorBegin Gets an iterator to the first element in the vector.
LmiVectorBeginConst Gets a read-only iterator to the first element in the vector.
LmiVectorCapacity Gets the number of elements for which memory has been allocated in the vector.
LmiVectorClear Erase all elements from the vector.
LmiVectorConstructCopy Construct a vector from another vector.
LmiVectorConstructDefault Construct an empty vector.
LmiVectorConstructN Construct a vector and initialize the first n entries in the vector with copies of t .
LmiVectorConstructRange Construct a vector and initialize it with the range specified.
LmiVectorConstructRangeOther Construct a vector from a range of another container type.
LmiVectorDestruct Destruct a vector.
LmiVectorEmpty Test whether or not a vector is empty.
LmiVectorEnd Gets an iterator to the element one past the last element in the vector.
LmiVectorEndConst Gets a read-only iterator to the element one past the last element in the vector.
LmiVectorEqual Test two vectors for equality.
LmiVectorErase Erase the element at a given position from the vector.
LmiVectorEraseRange Erase the elements in the range [ first , last ) from the vector.
LmiVectorFront Retrieve a pointer to the first element of the vector.
LmiVectorFrontConst Retrieve a read-only pointer to the first element of the vector.
LmiVectorGetAllocator Gets a pointer to the vector's allocator.
LmiVectorInsert Insert t into a vector before pos .
LmiVectorInsertN Insert n copies of t into a vector before pos .
LmiVectorInsertRange Insert the elements in the range [ first , last ) into a vector before pos .
LmiVectorLess Test whether one vector is lexicographically less than another.
LmiVectorMaxSize Gets the maximum number of elements the vector could contain.
LmiVectorPopBack Remove the last element from the vector.
LmiVectorPushBack Add an element to the end of the vector.
LmiVectorRBegin Gets a reverse iterator to the first element in the reversed vector.
LmiVectorRBeginConst Gets a read-only reverse iterator to the first element in the reversed vector.
LmiVectorREnd Gets a reverse iterator to the element one past the last element in the reversed vector.
LmiVectorREndConst Gets a read-only reverse iterator to the element one past the last element in the reversed vector.
LmiVectorReserve Reserves memory capacity in the vector. If capacity is less than or equal to LmiVectorCapacity(T) this call has no effect.
LmiVectorResize Resize a vector. If the current size of the vector is less than n then additional copies of t are added to the end of the vector. If the current size of the vector is greater than n then the elements from index n to the end of the vector are erased.
LmiVectorSize Gets the number of elements in the vector.
LmiVectorSwap Swap two vectors.

Note 1:

This is a LmiRandomAccessContainer and LmiBackInsertionSequence; see LmiContainers and the STL.

Note 2:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorConstIterator (T_)

Member Of:

LmiVector

Model Of:

LmiRandomAccessIterator

Description:

The read-only iterator type of a vector.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorConstReverseIterator (T_)

Member Of:

LmiVector

Model Of:

LmiReverseBidirectionalIterator

Description:

The read-only reverse iterator type of a vector.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorDifferenceType (T_)

Member Of:

LmiVector

Description:

The difference type of a vector. It is equivalent to the type LmiDistanceT.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorIterator (T_)

Member Of:

LmiVector

Model Of:

LmiRandomAccessIterator

Description:

The iterator type of a vector.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorReverseIterator (T_)

Member Of:

LmiVector

Model Of:

LmiReverseBidirectionalIterator

Description:

The reverse iterator type of a vector.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVectorSizeType (T_)

Member Of:

LmiVector

Description:

The size type of a vector. It is equivalent to the type LmiSizeT.

Include:

Lmi/Utils/LmiVector.h

Template Parameters:

T_ The type stored in the vector.

Note 1:

The macro Declare_LmiVector must be called before declaring an object of this type.

Type: LmiVersion

Member Of:

Utils

Description:

A data type that describes a version.

Include:

Lmi/Utils/LmiVersion.h

Member Functions:

LmiVersionAsString Gets the version as a human readable string.
LmiVersionGetEngineering Gets the engineering revision field of a version.
LmiVersionGetMajor Gets the major revision field of a version.
LmiVersionGetMinor Gets the minor revision field of a version.
LmiVersionGetPatch Gets the patch revision field of a version.

Type: LmiVoidPtr

Member Of:

BasicTypes

Description:

A generic object pointer.

Include:

Lmi/Utils/LmiTypes.h

Member Functions:

LmiVoidPtrAssign Assign the value of one LmiVoidPtr object to another one.
LmiVoidPtrConstruct Construct a default instance of an LmiVoidPtr object.
LmiVoidPtrConstructCopy Construct a new LmiVoidPtr object as a copy of an existing one.
LmiVoidPtrDestruct Destruct an LmiVoidPtr object.
LmiVoidPtrEqual Compare the values of two LmiVoidPtr objects for equality.
LmiVoidPtrLess Compare the values of two LmiVoidPtr objects for ordering.
LmiVoidPtrSwap Swap the contents of two LmiVoidPtr objects.

Type: LmiWideChar

Member Of:

BasicTypes

Description:

Wide character type, holding UCS4 (32-bit) Unicode characters.

Include:

Lmi/Utils/LmiTypes.h

Type: LmiWideString

Member Of:

Utils

Description:

Class representing C wide strings. Interface largely based on C++'s std::wstring (i.e., std::basic_string<wchar_t>) class.

Include:

Lmi/Utils/LmiWideString.h

Constants:

LMI_WIDE_STRING_NPOS SYMBOLIC LmiSizeT For value parameters, an invalid value used to represent "no position".

Member Types:

LmiWideStringConstIterator The read-only iterator type of a string.
LmiWideStringConstReverseIterator The read-only reverse iterator type of a string.
LmiWideStringIterator The iterator type of a string.
LmiWideStringReverseIterator The reverse iterator type of a string.

Member Functions:

LmiWideStringAppend Append the contents of one LmiWideString to another.
LmiWideStringAppendCStr Append a NUL-terminated C wide string to an LmiWideString.
LmiWideStringAppendCStrLen Append a C wide string of a given length to an LmiWideString.
LmiWideStringAppendChar Append a single character to an LmiWideString.
LmiWideStringAppendN Append multiple copies of a character to an LmiWideString.
LmiWideStringAppendRange Append a range of characters to a string.
LmiWideStringAppendSubstring Append a substring of one LmiWideString to another.
LmiWideStringAssign Assign the value of one LmiWideString to another. The previous data stored in the destination is overwritten.
LmiWideStringAssignCStr Assign a NUL-terminated C wide string as the new value of an LmiWideString.
LmiWideStringAssignCStrLen Assign a C wide string of a given length as the new value of an LmiWideString.
LmiWideStringAssignChar Assign a single character as the new value of an LmiWideString.
LmiWideStringAssignRange Assign a range of characters as the new value of an LmiWideString.
LmiWideStringAssignSubstring Assign a substring of one LmiWideString as the new value of another.
LmiWideStringAssignUtf16 Assign a wide string to have the Unicode values of a UTF16-encoded C string.
LmiWideStringAssignUtf8 Assign a wide string to have the Unicode values of a UTF8-encoded narrow C string.
LmiWideStringAssignUtf8Len Assign a wide string to have the Unicode values of a UTF8-encoded narrow C string of a given length.
LmiWideStringAt Get a pointer to the character stored at a specific position in a string.
LmiWideStringAtConst Get a constant pointer to the character stored at a specific position in a string.
LmiWideStringBack Return a pointer to the last character in a string.
LmiWideStringBackConst Return a pointer to the last character in a const string.
LmiWideStringBegin Get an iterator referring to the beginning of a string.
LmiWideStringBeginConst Get an iterator referring to the beginning of a const string.
LmiWideStringCStr Get a NUL-terminated C wide string corresponding to the contents of a string.
LmiWideStringCapacity Get the size of the allocated storage of an LmiWideString.
LmiWideStringClear Erase the contents of a string.
LmiWideStringCompare Compare the values of two LmiWideStrings for ordering.
LmiWideStringCompareCStr Compare the value of an LmiWideString with that of a C wide string for ordering.
LmiWideStringCompareCStrLen Compare the value of an LmiWideString with that of a C wide string of a given length for ordering.
LmiWideStringConstructCStr Construct an LmiWideString based on a NUL-terminated C wide string.
LmiWideStringConstructCStrLen Construct an LmiWideString based on a C wide string of a given length.
LmiWideStringConstructCopy Construct a copy of an LmiWideString.
LmiWideStringConstructDefault Construct an empty LmiWideString.
LmiWideStringConstructRange Construct an LmiWideString based on a range of another LmiWideString.
LmiWideStringConstructSubstring Construct an LmiWideString based on a substring of another LmiWideString.
LmiWideStringConstructUtf16 Construct a wide string to have the Unicode values of a UTF16-encoded C string.
LmiWideStringConstructUtf8 Construct a wide string to have the Unicode values of a UTF8-encoded narrow C string.
LmiWideStringConstructUtf8Len Construct a wide string to have the Unicode values of a UTF8-encoded narrow C string of a given length.
LmiWideStringData Get a read-only buffer corresponding to the contents of a string.
LmiWideStringDestruct Destruct an LmiWideString, freeing all associated storage.
LmiWideStringEmpty Determine whether a string is empty.
LmiWideStringEnd Get an iterator referring to the end of a string.
LmiWideStringEndConst Get an iterator referring to the end of a const string.
LmiWideStringEqual Compare the values of two LmiWideStrings for equality.
LmiWideStringEqualCStr Compare the value of an LmiWideString with that of a C wide string for equality.
LmiWideStringEqualCStrLen Compare the value of an LmiWideString with that of a C wide string of a given length for equality.
LmiWideStringErase Remove a single character from a string.
LmiWideStringEraseRange Remove a range from a string.
LmiWideStringEraseSubstring Remove a substring from a string.
LmiWideStringFindFirstNotOf Find first location in a string where one of the characters in a second string does not occur.
LmiWideStringFindFirstNotOfCStr Find first location in a string where one of the characters in a C wide string does not occur.
LmiWideStringFindFirstNotOfChar Find first location in a string where a given character does not occur.
LmiWideStringFindFirstOf Find first location in a string where one of the characters in a second string occurs.
LmiWideStringFindFirstOfCStr Find first location in a string where one of the characters in a C wide string occurs.
LmiWideStringFindFirstOfChar Find first location in a string where a given character occurs.
LmiWideStringFindLastOfCStr Find last location in a string where one of the characters in a C wide string occurs.
LmiWideStringFindLastOfChar Find last location in a string where a given character occurs.
LmiWideStringFront Return a pointer to the first character in a string.
LmiWideStringFrontConst Return a pointer to the first character in a const string.
LmiWideStringGetAllocator Get the allocator of an LmiWideString.
LmiWideStringGetBuffer Get a writeable buffer into which data can be written outside the control of the LmiWideString object.
LmiWideStringHash Hashes a string into an integer.
LmiWideStringInsert Insert a single character into a string.
LmiWideStringInsertCStr Insert a NUL-terminated C wide string into an LmiWideString.
LmiWideStringInsertCStrLen Insert a C wide string of a given length into an LmiWideString.
LmiWideStringInsertChar Insert a single character in an LmiWideString.
LmiWideStringInsertRange Insert a range of characters into a string.
LmiWideStringInsertString Insert the contents of one LmiWideString into another.
LmiWideStringInsertSubstring Insert part of the content of one LmiWideString into another.
LmiWideStringLength Get the length of an LmiWideString.
LmiWideStringLess Compare the values of two LmiWideStrings for ordering.
LmiWideStringMaxSize Get the maximum supported length of an LmiWideString.
LmiWideStringPopBack Pop a single character from the end of a string.
LmiWideStringPushBack Push a single character onto the end of a string.
LmiWideStringRBegin Get a reverse iterator referring to the reversed beginning (end) of a string.
LmiWideStringRBeginConst Get an iterator referring to the reversed beginning (end) of a const string.
LmiWideStringREnd Get an iterator referring to the reversed end (beginning) of a string.
LmiWideStringREndConst Get an iterator referring to the reversed end (beginning) of a const string.
LmiWideStringReleaseBuffer Release a writeable buffer previously acquired with LmiWideStringGetBuffer.
LmiWideStringReplaceCStr Replace part of an LmiWideString with a C wide string.
LmiWideStringReplaceCStrLen Replace part of an LmiWideString with a C wide string of a given length.
LmiWideStringReplaceChar Replace part of an LmiWideString with a single character.
LmiWideStringReplaceRange Replace a range of an LmiWideString with a different range of string iterators.
LmiWideStringReplaceString Replace part of an LmiWideString with another LmiWideString.
LmiWideStringReplaceSubstring Replace part of an LmiWideString with part of another LmiWideString.
LmiWideStringReserve Reserve storage for a string.
LmiWideStringResize Alters the length of an LmiWideString, either by truncating it or extending it.
LmiWideStringSize Get the size of an LmiWideString.
LmiWideStringSwap Swap the values of two LmiWideStrings.

Type: LmiWideStringConstIterator

Member Of:

LmiWideString

Description:

The read-only iterator type of a string.

Include:

Lmi/Utils/LmiWideString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiWideStringConstReverseIterator

Member Of:

LmiWideString

Description:

The read-only reverse iterator type of a string.

Include:

Lmi/Utils/LmiWideString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiWideStringIterator

Member Of:

LmiWideString

Description:

The iterator type of a string.

Include:

Lmi/Utils/LmiWideString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Type: LmiWideStringReverseIterator

Member Of:

LmiWideString

Description:

The reverse iterator type of a string.

Include:

Lmi/Utils/LmiWideString.h

Note 1:

This is a model of LmiRandomAccessIterator.

Callback: LmiAllocatorAllocateCallback

Member Of:

LmiAllocator

Description:

Allocate memory using a given allocator.

Include:

Lmi/Utils/LmiAllocator.h

Syntax:

LmiVoidPtr (*LmiAllocatorAllocateCallback)(LmiAllocator* allocator, LmiSizeT size)

Parameters:

allocator The allocator from which to allocate the memory.
size Bytes of memory to allocate.

Returns:

The memory allocated, or NULL on failure.

Callback: LmiAllocatorDeallocateCallback

Member Of:

LmiAllocator

Description:

Free memory previously allocated with the given allocator.

Include:

Lmi/Utils/LmiAllocator.h

Syntax:

void (*LmiAllocatorDeallocateCallback)(LmiAllocator* allocator, LmiVoidPtr ptr, LmiSizeT sizeHint)

Parameters:

allocator The allocator from which memory was allocated.
ptr The memory to free.
sizeHint The size of the original block of memory allocated, or LMI_SIZE_T_MAX if unknown.

Note 1:

This has no return value; it must always succeed.

Callback: LmiAssertCallback

Member Of:

Assert

Description:

Report a failing assertion, and terminate program execution.

Include:

Lmi/Utils/LmiAssert.h

Syntax:

void (*LmiAssertCallback)(const char* expression, const char* function, const char* file, LmiInt line)

Parameters:

expression A string containing the literal contents, in the source code, of the failing call to LmiAssert.
function The name of the function containing the failing call to LmiAssert, if available from the compiler. Otherwise, the empty string "".
file The name of the file containing the failing call to LmiAssert.
line The line number of the failing call to LmiAssert.

Note 1:

This function terminates program execution; it should not return.

Callback: LmiMotionProfilePlugInGetPositionCallback

Member Of:

LmiMotionProfilePlugIn

Description:

A callback returning the fraction of the total distance traveled as a function of the fraction of total time elapsed. This callback can be used to customize the smoothness of a motion. Other effects can be also be achieved, such as overshooting the target and snapping back to it. The function should return 0 at t=0 and 1 at t=1. A continuous function should be used in most instances, otherwise the animated object will appear to be teleported.

Include:

Lmi/Utils/LmiMotionProfile.h

Syntax:

LmiFloat64 (*LmiMotionProfilePlugInGetPositionCallback)(LmiMotionProfile *mp, LmiFloat64 t)

Parameters:

mp The LmiMotionProfile object.
t A value between 0 and 1 representing the fraction of the total time allotted for the move that has elapsed.

Returns:

A value between 0 and 1 representing the fraction of the total distance that has been traveled so far.

Function: Declare_LmiMatrix

Member Of:

LmiMatrix

Description:

Declare a parameterized matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

void Declare_LmiMatrix(Type T)

Parameters:

T The type of matrix elements.

Note 1:

Must be called at global scope.

Example 1:

				
		/* Instantiate a matrix of integers */
		Declare_LmiMatrix(LmiInt)
		LmiMatrix(LmiInt) numbers;
	
			

Function: Declare_LmiVector

Member Of:

LmiVector

Description:

Declare a parameterized vector container and its subtypes.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

void Declare_LmiVector(Type T)

Parameters:

T The type stored in the vector.

Note 1:

Must be called at global scope.

Example 1:

				
		/* Instantiate a vector of integers */
		Declare_LmiVector(LmiInt)
		LmiVector(LmiInt) numbers;
	
			

Function: Define_LmiMatrix

Member Of:

LmiMatrix

Description:

Define a parameterized matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

void Define_LmiMatrix(Type T)

Parameters:

T The type of matrix elements.

Example 1:

				
		/* Instantiate a matrix of integers container class */
		Define_LmiMatrix(LmiInt)
		void func() {
			LmiMatrix(LmiInt) numbers;
			LmiInt i;
			LmiMatrixConstructDefault(LmiInt)(&numbers, LmiMallocAllocatorGetDefault());
			for (i = 0; i < 10; ++i)
				for (j = 0; j < 10; ++j)
					LmiMatrixSetVal(LmiInt)(&numbers, i, j, i+j);
			LmiMatrixDestruct(LmiInt)(&numbers);
		}
	
			

Function: Define_LmiVector

Member Of:

LmiVector

Description:

Define a parameterized vector container and its subtypes.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

void Define_LmiVector(Type T)

Parameters:

T The type stored in the vector.

Example 1:

				
		/* Instantiate a vector of integers container class */
		Define_LmiVector(LmiInt)
		void func() {
			LmiVector(LmiInt) numbers;
			LmiInt i;
			LmiVectorConstructDefault(LmiInt)(&numbers, LmiMallocAllocatorGetDefault());
			for (i = 0; i < 10; ++i)
				LmiVectorPushBack(LmiInt)(&numbers, &i);
			LmiVectorDestruct(LmiInt)(&numbers);
		}
	
			

Function: LMI_INT64_C

Member Of:

LmiUint64

Description:

A macro that expands to a signed 64-bit integer constant.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt64 LMI_INT64_C(LmiInt64 val)

Parameters:

val A signed decimal, octal, or hexadecimal constant, with a value no greater than 2^63 - 1 and no less than -(2^63).

Returns:

Expands to a signed integer constant with the value val and the type LmiInt64. For example, if LmiInt64 is a name for the C type long long int, then LMI_INT64_C(0x123) might expand to the integer constant 0x123LL.

Function: LMI_UINT64_C

Member Of:

LmiUint64

Description:

A macro that expands to an unsigned 64-bit integer constant.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint64 LMI_UINT64_C(LmiUint64 val)

Parameters:

val An unsigned decimal, octal, or hexadecimal constant, with a value no greater than 2^64 - 1.

Returns:

Expands to an unsigned integer constant with the value val and the type LmiUint64. For example, if LmiUint64 is a name for the C type unsigned long long int, then LMI_UINT64_C(0x123) might expand to the integer constant 0x123ULL.

Function: LmiAlgorithmFind

Member Of:

Algorithms

Description:

Find the first item in range equal to the specified value.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

InputIterator_ LmiAlgorithmFind(InputIterator_, T_)(InputIterator_ first_, InputIterator_ last_, const T_* value_)

Template Parameters:

InputIterator_ The iterator type of the container containing the items to be searched. The iterator type must be a model of LmiInputIterator.
T_ The type stored in the container. The type must be a model of LmiEqualityComparable.

Parameters:

first_ An iterator to the first item in the container to be searched.
last_ An iterator to one past the last item in the container to be searched.
value_ The value to find.

Returns:

An iterator to the first item in the range whose value is equal to the value specified.

Note 1:

The macro Define_LmiAlgorithmFind must be called at global scope before calling this function.

Example 1:

				
		Define_LmiAlgorithmFind(LmiVectorConstIterator(LmiInt),  LmiInt)
		LmiVectorConstIterator find_vector(const LmiVector(LmiInt)* v, LmiInt value) {
			return LmiAlgorithmFind(LmiVectorConstIterator(LmiInt), LmiInt)(LmiVectorBeginConst(LmiInt)(&v), LmiVectorEndConst(LmiInt)(&v), &value);
		}
	
			

Function: LmiAlgorithmFindIf

Member Of:

Algorithms

Description:

Find the first item in range equal to the specified value as determined by the predicate function.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

InputIterator_ LmiAlgorithmFindIf(InputIterator_, T_)(InputIterator_ first_, InputIterator_ last_, LmiPredicate(T_) predicate_, void* data_)

Template Parameters:

InputIterator_ The iterator type of the container containing the items to be searched. The iterator type must be a model of LmiInputIterator.
T_ The type stored in the container. The type must be a model of LmiEqualityComparable.

Parameters:

first_ An iterator to the first item in the container to be searched.
last_ An iterator to one past the last item in the container to be searched.
predicate_ The predicate function. The function must be a model of LmiPredicate.
data_ A user data pointer.

Returns:

An iterator to the first item in the range for which the predicate returns true.

Note 1:

The macro Define_LmiAlgorithmFindIf must be called at global scope before calling this function.

Example 1:

				
		LmiBool greater_than_n(LmiInt* x, void* data) {
			LmiInt n = *(LmiInt*)data;
			return *x > n;
		}
		Define_LmiAlgorithmFindIf(LmiVectorConstIterator(LmiInt), LmiInt)
		LmiVectorConstIterator findif_vector(const LmiVector(LmiInt)* v) {
			LmiInt n = 99;
			return LmiAlgorithmFindIf(LmiVectorConstIterator(LmiInt), LmiInt)(LmiVectorBeginConst(LmiInt)(&v), LmiVectorEndConst(LmiInt)(&v), greater_than_n, &n);
		}
	
			

Function: LmiAlignedAllocatorConstruct

Member Of:

LmiAlignedAllocator

Description:

Construct a new LmiAlignedAllocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiAlignedAllocator *LmiAlignedAllocatorConstruct(LmiAlignedAllocator *x, LmiUint8 alignment, LmiAllocator *a)

Parameters:

x A pointer to an uninitialized LmiAlignedAllocator.
alignment The alignment (in bytes) to be used when allocating memory. The value specified must be a power of 2. If this value is 0, LMI_ALIGNEDALLOCATOR_DefaultAlignment will be used.
a A pointer to an initialized LmiAllocator. Actual memory allocation will be done through this allocator.

Returns:

The constructed allocator or NULL on failure.

Function: LmiAlignedAllocatorConstructCopy

Member Of:

LmiAlignedAllocator

Description:

ConstructCopy a new LmiAlignedAllocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiAlignedAllocator *LmiAlignedAllocatorConstructCopy(LmiAlignedAllocator *x, const LmiAlignedAllocator *y)

Parameters:

x A pointer to an uninitialized LmiAlignedAllocator.
y A pointer to an initialized LmiAlignedAllocator.

Returns:

The constructed allocator or NULL on failure.

Function: LmiAlignedAllocatorDestruct

Member Of:

LmiAlignedAllocator

Description:

Destruct an aligned allocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

void LmiAlignedAllocatorDestruct(LmiAlignedAllocator *x)

Parameters:

x A pointer to an LmiAlignedAllocator to destruct.

Function: LmiAlignedAllocatorGetAlignment

Member Of:

LmiAlignedAllocator

Description:

Obtain the alignment in bytes.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiUint8 LmiAlignedAllocatorGetAlignment(const LmiAlignedAllocator *x)

Parameters:

x The aligned allocator to query.

Returns:

The align size in bytes.

Function: LmiAlignedAllocatorGetAllocator

Member Of:

LmiAlignedAllocator

Description:

Get the aligned allocator's allocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiAllocator *LmiAlignedAllocatorGetAllocator(LmiAlignedAllocator *x)

Parameters:

x The aligned allocator object from which to get the allocator.

Returns:

base allocator.

Function: LmiAlignedAllocatorGetBase

Member Of:

LmiAlignedAllocator

Description:

Get the aligned allocator's base allocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiAllocator *LmiAlignedAllocatorGetBase(LmiAlignedAllocator *x)

Parameters:

x The aligned allocator object from which to get the base allocator.

Returns:

base allocator.

Function: LmiAlignedAllocatorGetMaxSize

Member Of:

LmiAlignedAllocator

Description:

Obtain the size of the largest block of memory allocatable with a given allocator.

Include:

Lmi/Utils/LmiAlignedAllocator.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiAlignedAllocatorGetMaxSize(const LmiAlignedAllocator *x)

Parameters:

x The aligned allocator to query.

Returns:

The size of the largest allocatable block.

Function: LmiAllocatorAllocate

Member Of:

LmiAllocator

Description:

Allocate memory from a given allocator.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

LmiVoidPtr LmiAllocatorAllocate(LmiAllocator* allocator, LmiSizeT size)

Parameters:

allocator The allocator from which to allocate the memory.
size Bytes of memory to allocate.

Returns:

The memory allocated, or NULL on failure.

Function: LmiAllocatorConstruct

Member Of:

LmiAllocator

Description:

Construct an LmiAllocator.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

LmiAllocator* LmiAllocatorConstruct(LmiAllocator* allocator, LmiAllocatorAllocateCallback allocate, LmiAllocatorDeallocateCallback deallocate, LmiSizeT maxSize, LmiVoidPtr userData)

Parameters:

allocator A pointer to an uninitialized LmiAllocator object.
allocate The function to be called when the allocator allocates memory.
deallocate The function to be called when the allocator deallocates memory.
maxSize The maximum size block allocatable with the allocator.
userData Internal data for use by the allocator.

Returns:

The initialized allocator, or NULL on failure.

Function: LmiAllocatorDeallocate

Member Of:

LmiAllocator

Description:

Deallocate memory previously allocated with the given allocator.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

void LmiAllocatorDeallocate(LmiAllocator* allocator, LmiVoidPtr ptr, LmiSizeT sizeHint)

Parameters:

allocator The allocator from which memory was allocated.
ptr The memory to deallocate.
sizeHint The size of the original block of memory allocated, or LMI_SIZE_T_MAX if unknown.

Note 1:

This has no return value; it must always succeed.

Function: LmiAllocatorDestruct

Member Of:

LmiAllocator

Description:

Destruct an LmiAllocator.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

void LmiAllocatorDestruct(LmiAllocator* allocator)

Parameters:

allocator The allocator object to destruct.

Note 1:

This does not do deallocate any memory associated with the allocator's user data field. As such, this function should generally be considered "protected", i.e. it should only be called by specific allocators' destruct functions.

Function: LmiAllocatorGetMaxSize

Member Of:

LmiAllocator

Description:

Obtain the size of the largest block of memory allocatable with a given allocator.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiAllocatorGetMaxSize(const LmiAllocator* allocator)

Parameters:

allocator The allocator to query.

Returns:

The size of the largest allocatable block.

Note 1:

If the allocator has no intrinsic maximum size, e.g. it is limited only by available memory, this will return LMI_SIZE_T_MAX.

Function: LmiAllocatorGetUserData

Member Of:

LmiAllocator

Description:

Get an allocator's user data.

Include:

Lmi/Utils/LmiAllocator.h

Library:

LmiUtils

Syntax:

LmiVoidPtr LmiAllocatorGetUserData(LmiAllocator* allocator)

Parameters:

allocator The allocator object from which to get the user data.

Returns:

The allocator object's user data.

Note 1:

This function should generally only be called by the implementations of specific allocators.

Function: LmiAssertSetCallback

Member Of:

Assert

Description:

Set a callback function to be invoked when an assertion fails.

Include:

Lmi/Utils/LmiAssert.h

Library:

LmiUtils

Syntax:

void LmiAssertSetCallback(LmiAssertCallback callback)

Parameters:

callback The callback to be invoked, or NULL. If NULL, a system-dependent operation will be performed when an assertion fails.

Note 1:

This function is not thread-safe. The assert callback should generally be set at program startup time and not modified thereafter.

Function: LmiBaseIteratorAssign

Member Of:

LmiBaseIterator

Description:

Copy one iterator to another.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBaseIterator(T_)* LmiBaseIteratorAssign(T_)(LmiBaseIterator(T_)* x, const LmiBaseIterator(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The iterator to assign to.
y The iterator to assign from.

Returns:

A pointer to the assigned to iterator or NULL on error.

Function: LmiBaseIteratorConstructCopy

Member Of:

LmiBaseIterator

Description:

Constructs an iterator from another iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBaseIterator(T_)* LmiBaseIteratorConstructCopy(T_)(LmiBaseIterator(T_)* x, const LmiBaseIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be constructed.
y The iterator to use to initialize the iterator being constructed.

Returns:

A pointer to the constructed iterator or NULL on error.

Function: LmiBaseIteratorDestruct

Member Of:

LmiBaseIterator

Description:

Destructs an iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

void LmiBaseIteratorDestruct(T_)(LmiBaseIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be destructed.

Function: LmiBaseIteratorSwap

Member Of:

LmiBaseIterator

Description:

Swap two iterators.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiBaseIteratorSwap(T_)(LmiBaseIterator(T_)* x, LmiBaseIterator(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The iterator to swap.
y The other iterator to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Function: LmiBidirectionalIteratorDecrement

Member Of:

LmiBidirectionalIterator

Description:

Decrements the iterator to point at the previous object in the container. No checking is perform to ensure that the iterator is in range of the container after the operation.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBidirectionalIterator(T_)* LmiBidirectionalIteratorDecrement(T_)(LmiBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be incremented.

Returns:

A pointer to the iterator after it has been decremented.

Function: LmiBinarySearch

Member Of:

Algorithms

Description:

Find an element in a sorted sequence of elements.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

I LmiBinarySearch(I, T)(I begin, I end, const T *val)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiRandomAccessIterator.
T The type of the elements in the sequence.

Parameters:

begin Points to the first item in the sequence.
end Points to one past the last item in the sequence.
val The element to search for.

Returns:

Returns an iterator pointing to an element equivalent to the specified one. Returns end if no such element exists.

Note 1:

The macro Define_LmiBinarySearch must be called at global scope before calling this function.

Function: LmiBinarySearchComp

Member Of:

Algorithms

Description:

Find an element in a sorted sequence of elements.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

I LmiBinarySearchComp(I, T, Comp)(I begin, I end, const T *val)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiRandomAccessIterator.
T The type of the elements in the sequence.
Comp The comparison function for elements.

Parameters:

begin Points to the first item in the sequence.
end Points to one past the last item in the sequence.
val The element to search for.

Returns:

Returns an iterator pointing to an element equivalent to the specified one. Returns end if no such element exists.

Note 1:

The macro Define_LmiBinarySearchComp must be called at global scope before calling this function.

Function: LmiBoolAssign

Member Of:

LmiBool

Description:

Assign the value of one LmiBool object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool* LmiBoolAssign(LmiBool* dst, const LmiBool* src)

Parameters:

dst A pointer to the LmiBool object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiBool object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiBool assignment will not fail.

Function: LmiBoolConstruct

Member Of:

LmiBool

Description:

Construct a default instance of an LmiBool object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool* LmiBoolConstruct(LmiBool* obj)

Parameters:

obj A pointer to the LmiBool object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiBool object is initialized with the value 0. LmiBool construction will not fail.

Function: LmiBoolConstructCopy

Member Of:

LmiBool

Description:

Construct a new LmiBool object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool* LmiBoolConstructCopy(LmiBool* dst, const LmiBool* src)

Parameters:

dst A pointer to the LmiBool object to initialize as a copy.
src An existing LmiBool object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiBool construction will not fail.

Function: LmiBoolDestruct

Member Of:

LmiBool

Description:

Destruct an LmiBool object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiBoolDestruct(LmiBool* obj)

Parameters:

obj A pointer to the LmiBool object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiBoolEqual

Member Of:

LmiBool

Description:

Compare the values of two LmiBool objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiBoolEqual(const LmiBool* a, const LmiBool* b)

Parameters:

a A pointer to the first LmiBool object to be compared.
b A pointer to the second LmiBool object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiBoolLess

Member Of:

LmiBool

Description:

Compare the values of two LmiBool objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiBoolLess(const LmiBool* a, const LmiBool* b)

Parameters:

a A pointer to the first LmiBool object to be compared.
b A pointer to the second LmiBool object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiBoolSwap

Member Of:

LmiBool

Description:

Swap the contents of two LmiBool objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiBoolSwap(LmiBool* a, LmiBool* b)

Parameters:

a A pointer to the first LmiBool object to be swapped.
b A pointer to the second LmiBool object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiBool swapping will not fail.

Function: LmiCommandLineOptionConstruct

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstruct(LmiCommandLineOption *opt, const char *tag, LmiCommandLineParameter *parameters, LmiInt numParameters)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
parameters An array of parameters expected for the option. Can be NULL if the option has no parameters.
numParameters The number of parameters in the array.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructBoolean

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has no parameters.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructBoolean(LmiCommandLineOption *opt, const char *tag, LmiBool *ptr)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr This boolean variable will be set to LMI_TRUE if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructBooleanEx

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has no parameters.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructBooleanEx(LmiCommandLineOption *opt, const char *tag, LmiBool *ptr, LmiBool value)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr A boolean variable that will be written to if the option is found.
value The value that should be written into *ptr if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructEnum

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one parameter that is an enumerated type.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructEnum(LmiCommandLineOption *opt, const char *tag, LmiInt *ptr, const LmiCommandLineEnum *enums, LmiSizeT numEnums)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The numeric value of the parameter will be written into this variable if the option is found.
enums An array containing the set of enumerated values for this option.
numEnums The number of values in the array.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructEx

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructEx(LmiCommandLineOption *opt, const char *tag, LmiCommandLineParameter *parameters, LmiInt numParameters, LmiBool *found, LmiBool foundValue)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
parameters An array of parameters expected for the option. Can be NULL if the option has no parameters.
numParameters The number of parameters in the array.
found A boolean variable that will be written to if the option is found.
foundValue The value that should be written into *found if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructInteger

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one unsigned integer parameter.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructInteger(LmiCommandLineOption *opt, const char *tag, LmiUint *ptr)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The value of the parameter will be written into this variable if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructIntegerRange

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one unsigned integer parameter. The integer must lie within a specified range.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructIntegerRange(LmiCommandLineOption *opt, const char *tag, LmiUint *ptr, LmiUint min, LmiUint max)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The value of the parameter will be written into this variable if the option is found.
min The minimum allowed value for the parameter.
max The maximum allowed value for the parameter.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructSignedInteger

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one signed integer parameter.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructSignedInteger(LmiCommandLineOption *opt, const char *tag, LmiInt *ptr)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The value of the parameter will be written into this variable if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructSignedIntegerRange

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one signed integer parameter. The integer must lie within a specified range.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructSignedIntegerRange(LmiCommandLineOption *opt, const char *tag, LmiInt *ptr, LmiInt min, LmiInt max)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The value of the parameter will be written into this variable if the option is found.
min The minimum allowed value for the parameter.
max The maximum allowed value for the parameter.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionConstructString

Member Of:

LmiCommandLineOption

Description:

Constructs a command line option that has one string parameter.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOption *LmiCommandLineOptionConstructString(LmiCommandLineOption *opt, const char *tag, const char **ptr)

Parameters:

opt The command line option to construct.
tag The name of the command line option. This is not case-sensitive.
ptr The value of the parameter will be written into this variable if the option is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineOptionDestruct

Member Of:

LmiCommandLineOption

Description:

Destructs a command line option.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

void LmiCommandLineOptionDestruct(LmiCommandLineOption *opt)

Parameters:

opt The command line option to destruct.

Function: LmiCommandLineOptionGetTag

Member Of:

LmiCommandLineOption

Description:

Gets the name of a command line option.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

const char *LmiCommandLineOptionGetTag(const LmiCommandLineOption *opt)

Parameters:

opt The command line option.

Returns:

The name of the command line option.

Function: LmiCommandLineOptionParse

Member Of:

LmiCommandLineOption

Description:

Search for optional command line arguments in a program's argument vector.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineOptionParseStatus LmiCommandLineOptionParse(const LmiCommandLineOption *options, LmiSizeT numOptions, LmiInt argc, char **argv, LmiInt *nextArg, const LmiCommandLineOption **badOption)

Parameters:

options An array of command line options to search for.
numOptions The number of command line options in the array.
argc The number of program arguments passed to main().
argv The vector of program arguments passed to main().
nextArg If the function returns LMI_COMMANDLINEOPTIONPARSESTATUS_SUCCESS, the index of the first unparsed argument will be written into this variable. The caller can begin the processing of required options at this index.
badOption If the function returns a status other than LMI_COMMANDLINEOPTIONPARSESTATUS_SUCCESS, the address of the option whose parameters could not be parsed will be written into this variable.

Returns:

An LmiCommandLineOptionParseStatus value indicating the result of the parse.

Function: LmiCommandLineParameterConstructEnum

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting one of a fixed set of strings. Each string has an associated integer value. This object can be used to retrieve a value for an enumerated type.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructEnum(LmiCommandLineParameter *p, LmiInt *ptr, const LmiCommandLineEnum *enums, LmiSizeT numEnums)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if a valid parameter is found.
enums An array containing the set of enumerated values for this parameter.
numEnums The number of values in the array.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterConstructInteger

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting an unsigned integer for input.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructInteger(LmiCommandLineParameter *p, LmiUint *ptr)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if a valid parameter is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterConstructIntegerRange

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting an unsigned integer for input. The integer must lie within a specified range.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructIntegerRange(LmiCommandLineParameter *p, LmiUint *ptr, LmiUint min, LmiUint max)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if a valid parameter is found.
min The minimum allowed value for the parameter.
max The maximum allowed value for the parameter.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterConstructSignedInteger

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting a signed integer for input.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructSignedInteger(LmiCommandLineParameter *p, LmiInt *ptr)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if a valid parameter is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterConstructSignedIntegerRange

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting a signed integer for input. The integer must lie within a specified range.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructSignedIntegerRange(LmiCommandLineParameter *p, LmiInt *ptr, LmiInt min, LmiInt max)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if a valid parameter is found.
min The minimum allowed value for the parameter.
max The maximum allowed value for the parameter.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterConstructString

Member Of:

LmiCommandLineParameter

Description:

Constructs a command line parameter expecting string input.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

LmiCommandLineParameter *LmiCommandLineParameterConstructString(LmiCommandLineParameter *p, const char **ptr)

Parameters:

p The command line parameter object to construct.
ptr The value of the parameter will be written into this variable if the parameter is found.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiCommandLineParameterDestruct

Member Of:

LmiCommandLineParameter

Description:

Destructs a command line parameter object.

Include:

Lmi/Utils/LmiCommandLineOption.h

Library:

LmiUtils

Syntax:

void LmiCommandLineParameterDestruct(LmiCommandLineParameter *p)

Parameters:

p The command line parameter object to destruct.

Function: LmiConstAccelMotionProfileConstruct

Member Of:

LmiConstAccelMotionProfile

Description:

Constructs an LmiConstAccelMotionProfile object with default parameters. The acceleration and deceleration stages will each be 1/4 of the total time for the move.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiConstAccelMotionProfile *LmiConstAccelMotionProfileConstruct(LmiConstAccelMotionProfile *p)

Parameters:

p The LmiConstAccelMotionProfile object to construct.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Note 1:

It should not be necessary to call this function directly. One LmiConstAccelMotionProfile object with default parameters is prebuilt, which can be accessed by calling LmiConstAccelMotionProfileGetDefault. Use LmiConstAccelMotionProfileConstructEx to create the object with custom parameters.

Function: LmiConstAccelMotionProfileConstructEx

Member Of:

LmiConstAccelMotionProfile

Description:

Constructs an LmiConstAccelMotionProfile object with custom parameters.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiConstAccelMotionProfile *LmiConstAccelMotionProfileConstructEx(LmiConstAccelMotionProfile *p, LmiFloat64 tAccel)

Parameters:

p The LmiConstAccelMotionProfile object to construct.
tAccel Represents the duration of the acceleration stage of the profile as a fraction of the total time for the move. (The same duration will be used for the deceleration stage.) Must be greater than 0 and less than 0.5.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiConstAccelMotionProfileDestruct

Member Of:

LmiConstAccelMotionProfile

Description:

Destructs an LmiConstAccelMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

void LmiConstAccelMotionProfileDestruct(LmiConstAccelMotionProfile *p)

Parameters:

p The LmiConstAccelMotionProfile object to destruct.

Function: LmiConstAccelMotionProfileGetBase

Member Of:

LmiConstAccelMotionProfile

Description:

Returns the LmiMotionProfile base class pointer for an LmiConstAccelMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstAccelMotionProfileGetBase(LmiConstAccelMotionProfile *p)

Parameters:

p The LmiConstAccelMotionProfile object.

Returns:

The LmiMotionProfile base class pointer.

Function: LmiConstAccelMotionProfileGetDefault

Member Of:

LmiConstAccelMotionProfile

Description:

Returns an LmiConstAccelMotionProfile object with default parameters.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstAccelMotionProfileGetDefault(void)

Returns:

A default LmiConstAccelMotionProfile object.

Function: LmiConstJerkMotionProfileConstruct

Member Of:

LmiConstJerkMotionProfile

Description:

Constructs an LmiConstJerkMotionProfile object with default parameters. The acceleration and deceleration stages will each be 3/8 of the total time for the move. The periods of nonzero jerk will each be 1/8 of the total time for the move.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiConstJerkMotionProfile *LmiConstJerkMotionProfileConstruct(LmiConstJerkMotionProfile *p)

Parameters:

p The LmiConstAccelMotionProfile object to construct.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Note 1:

It should not be necessary to call this function directly. One LmiConstJerkMotionProfile object with default parameters is prebuilt, which can be accessed by calling LmiConstJerkMotionProfileGetDefault. Use LmiConstJerkMotionProfileConstructEx to create the object with custom parameters.

Function: LmiConstJerkMotionProfileConstructEx

Member Of:

LmiConstJerkMotionProfile

Description:

Constructs an LmiConstJerkMotionProfile object with custom parameters.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiConstJerkMotionProfile *LmiConstJerkMotionProfileConstructEx(LmiConstJerkMotionProfile *p, LmiFloat64 tAccel, LmiFloat64 tJerk)

Parameters:

p The LmiConstAccelMotionProfile object to construct.
tAccel Represents the duration of the acceleration stages of the profile as a fraction of the total time for the move. (The same duration will be used for the deceleration stages.) Must be greater than 0 and less than 0.5.
tJerk Represents the duration of each of the stages where the acceleration is changing, as a fraction of the total time for the move. Must be greater than 0 and less than (tAccel / 2).

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiConstJerkMotionProfileDestruct

Member Of:

LmiConstJerkMotionProfile

Description:

Destructs an LmiConstJerkMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

void LmiConstJerkMotionProfileDestruct(LmiConstJerkMotionProfile *p)

Parameters:

p The LmiConstJerkMotionProfile object to destruct.

Function: LmiConstJerkMotionProfileGetBase

Member Of:

LmiConstJerkMotionProfile

Description:

Returns the LmiMotionProfile base class pointer for an LmiConstJerkMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstJerkMotionProfileGetBase(LmiConstJerkMotionProfile *p)

Parameters:

p The LmiConstJerkMotionProfile object.

Returns:

The LmiMotionProfile base class pointer.

Function: LmiConstJerkMotionProfileGetDefault

Member Of:

LmiConstJerkMotionProfile

Description:

Returns an LmiConstJerkMotionProfile object with default parameters.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstJerkMotionProfileGetDefault(void)

Returns:

A default LmiConstJerkMotionProfile object.

Function: LmiConstVelMotionProfileConstruct

Member Of:

LmiConstVelMotionProfile

Description:

Constructs an LmiConstVelMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiConstVelMotionProfile *LmiConstVelMotionProfileConstruct(LmiConstVelMotionProfile *p)

Parameters:

p The LmiConstVelMotionProfile object to construct.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Note 1:

It should not be necessary to call this function directly. All LmiConstVelMotionProfile objects behave the same, so only one is necessary. One is prebuilt, which can be accessed by calling LmiConstVelMotionProfileGetDefault.

Function: LmiConstVelMotionProfileDestruct

Member Of:

LmiConstVelMotionProfile

Description:

Destructs an LmiConstVelMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

void LmiConstVelMotionProfileDestruct(LmiConstVelMotionProfile *p)

Parameters:

p The LmiConstVelMotionProfile object to destruct.

Function: LmiConstVelMotionProfileGetBase

Member Of:

LmiConstVelMotionProfile

Description:

Returns the LmiMotionProfile base class pointer for an LmiConstVelMotionProfile object. The base class pointer may be passed to functions that use LmiMotionProfile objects in a generic fashion.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstVelMotionProfileGetBase(LmiConstVelMotionProfile *p)

Parameters:

p The LmiConstVelMotionProfile object.

Returns:

The LmiMotionProfile base class pointer.

Function: LmiConstVelMotionProfileGetDefault

Member Of:

LmiConstVelMotionProfile

Description:

Returns an LmiConstVelMotionProfile object with default parameters.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiConstVelMotionProfileGetDefault(void)

Returns:

A default LmiConstVelMotionProfile object.

Function: LmiCopy

Member Of:

Algorithms

Description:

Copy a range of items from one container to another.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

OutputIterator_ LmiCopy(InputIterator_, OutputIterator_, T_)(InputIterator_ first_, InputIterator_ last_, OutputIterator_ d_)

Template Parameters:

InputIterator_ The iterator type of the container containing the items to be copied. The iterator type must be a model of LmiInputIterator.
OutputIterator_ The iterator type of the container to which items are to be copied. The iterator type must be a model of LmiOutputIterator.
T_ The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

first_ An iterator to the first item in the container to copy.
last_ An iterator to one past the last item in the container to copy.
d_ An iterator into the destination container where the items are to be copied.

Returns:

An iterator to the item one past the last item copied in the destination container or the exceptional iterator (0) on error.

Note 1:

The macro Define_LmiCopy must be called at global scope before calling this function.

Example 1:

				
		Define_LmiCopy(LmiConstVectorIterator(LmiInt), LmiVectorIterator(LmiInt), LmiInt)
		void copy_vector(const LmiVector(LmiInt)* src, LmiVector(LmiInt)* dst) {
			LmiCopy(LmiConstVectorIterator(LmiInt), LmiVectorIterator(LmiInt), LmiInt)(LmiVectorBeginConst(LmiInt)(&src), LmiVectorEndConst(LmiInt)(&src), LmiVectorBegin(LmiInt)(&dst));
		}
	
			

Function: LmiDistanceTAssign

Member Of:

LmiDistanceT

Description:

Assign the value of one LmiDistanceT object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiDistanceT* LmiDistanceTAssign(LmiDistanceT* dst, const LmiDistanceT* src)

Parameters:

dst A pointer to the LmiDistanceT object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiDistanceT object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiDistanceT assignment will not fail.

Function: LmiDistanceTConstruct

Member Of:

LmiDistanceT

Description:

Construct a default instance of an LmiDistanceT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiDistanceT* LmiDistanceTConstruct(LmiDistanceT* obj)

Parameters:

obj A pointer to the LmiDistanceT object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiDistanceT object is initialized with the value 0. LmiDistanceT construction will not fail.

Function: LmiDistanceTConstructCopy

Member Of:

LmiDistanceT

Description:

Construct a new LmiDistanceT object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiDistanceT* LmiDistanceTConstructCopy(LmiDistanceT* dst, const LmiDistanceT* src)

Parameters:

dst A pointer to the LmiDistanceT object to initialize as a copy.
src An existing LmiDistanceT object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiDistanceT construction will not fail.

Function: LmiDistanceTDestruct

Member Of:

LmiDistanceT

Description:

Destruct an LmiDistanceT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiDistanceTDestruct(LmiDistanceT* obj)

Parameters:

obj A pointer to the LmiDistanceT object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiDistanceTEqual

Member Of:

LmiDistanceT

Description:

Compare the values of two LmiDistanceT objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiDistanceTEqual(const LmiDistanceT* a, const LmiDistanceT* b)

Parameters:

a A pointer to the first LmiDistanceT object to be compared.
b A pointer to the second LmiDistanceT object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiDistanceTLess

Member Of:

LmiDistanceT

Description:

Compare the values of two LmiDistanceT objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiDistanceTLess(const LmiDistanceT* a, const LmiDistanceT* b)

Parameters:

a A pointer to the first LmiDistanceT object to be compared.
b A pointer to the second LmiDistanceT object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiDistanceTSwap

Member Of:

LmiDistanceT

Description:

Swap the contents of two LmiDistanceT objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiDistanceTSwap(LmiDistanceT* a, LmiDistanceT* b)

Parameters:

a A pointer to the first LmiDistanceT object to be swapped.
b A pointer to the second LmiDistanceT object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiDistanceT swapping will not fail.

Function: LmiFill

Member Of:

Algorithms

Description:

Fill a range of items of a container with the specified value.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

LmiBool LmiFill(ForwardIterator_, T_)(ForwardIterator_ first_, ForwardIterator_ last_, const T_* t_)

Template Parameters:

ForwardIterator_ The iterator type of the container containing the items to be filled. The iterator type must be a model of LmiForwardIterator.
T_ The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

first_ An iterator to the first item in the container to filled.
last_ An iterator to one past the last item in the container to filled.
t_ The fill value.

Returns:

LMI_TRUE if successful, or LMI_FALSE otherwise.

Note 1:

The macro Define_LmiFill must be called at global scope before calling this function.

Example 1:

				
		Define_LmiFill(LmiVectorIterator(LmiInt), LmiInt)
		void fill_vector(LmiVector(LmiInt)* v, LmiInt value) {
			LmiFill(LmiVectorIterator(LmiInt), LmiInt)(LmiVectorBegin(LmiInt)(&v), LmiVectorEnd(LmiInt)(&v), value);
		}
	
			

Function: LmiFillN

Member Of:

Algorithms

Description:

Fill a range of items of a container with the specified value.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

LmiBool LmiFillN(ForwardIterator_, Size_, T_)(ForwardIterator_ first_, Size_ n_, const T_* t_)

Template Parameters:

ForwardIterator_ The iterator type of the container containing the items to be filled. The iterator type must be a model of LmiForwardIterator.
Size_ The size type of T_.
T_ The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

first_ An iterator to the first item in the container to filled.
n_ The number of items to fill.
t_ The fill value.

Returns:

LMI_TRUE if successful, or LMI_FALSE otherwise.

Note 1:

The macro Define_LmiFillN must be called at global scope before calling this function.

Example 1:

				
		Define_LmiFillN(LmiVectorIterator(LmiInt), LmiSizeT, LmiInt)
		void filln_vector(LmiVector(LmiInt)* v, LmiSizeT n, LmiInt value) {
			LmiFillN(LmiVectorIterator(LmiInt), LmiInt)(LmiVectorBegin(LmiInt)(&v), n, &value);
		}
	
			

Function: LmiFloat32Assign

Member Of:

LmiFloat32

Description:

Assign the value of one LmiFloat32 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat32* LmiFloat32Assign(LmiFloat32* dst, const LmiFloat32* src)

Parameters:

dst A pointer to the LmiFloat32 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiFloat32 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiFloat32 assignment will not fail.

Function: LmiFloat32Construct

Member Of:

LmiFloat32

Description:

Construct a default instance of an LmiFloat32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat32* LmiFloat32Construct(LmiFloat32* obj)

Parameters:

obj A pointer to the LmiFloat32 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiFloat32 object is initialized with the value 0. LmiFloat32 construction will not fail.

Function: LmiFloat32ConstructCopy

Member Of:

LmiFloat32

Description:

Construct a new LmiFloat32 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat32* LmiFloat32ConstructCopy(LmiFloat32* dst, const LmiFloat32* src)

Parameters:

dst A pointer to the LmiFloat32 object to initialize as a copy.
src An existing LmiFloat32 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiFloat32 construction will not fail.

Function: LmiFloat32Destruct

Member Of:

LmiFloat32

Description:

Destruct an LmiFloat32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiFloat32Destruct(LmiFloat32* obj)

Parameters:

obj A pointer to the LmiFloat32 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiFloat32Equal

Member Of:

LmiFloat32

Description:

Compare the values of two LmiFloat32 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat32Equal(const LmiFloat32* a, const LmiFloat32* b)

Parameters:

a A pointer to the first LmiFloat32 object to be compared.
b A pointer to the second LmiFloat32 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiFloat32Less

Member Of:

LmiFloat32

Description:

Compare the values of two LmiFloat32 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat32Less(const LmiFloat32* a, const LmiFloat32* b)

Parameters:

a A pointer to the first LmiFloat32 object to be compared.
b A pointer to the second LmiFloat32 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiFloat32Swap

Member Of:

LmiFloat32

Description:

Swap the contents of two LmiFloat32 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat32Swap(LmiFloat32* a, LmiFloat32* b)

Parameters:

a A pointer to the first LmiFloat32 object to be swapped.
b A pointer to the second LmiFloat32 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiFloat32 swapping will not fail.

Function: LmiFloat64Assign

Member Of:

LmiFloat64

Description:

Assign the value of one LmiFloat64 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat64* LmiFloat64Assign(LmiFloat64* dst, const LmiFloat64* src)

Parameters:

dst A pointer to the LmiFloat64 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiFloat64 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiFloat64 assignment will not fail.

Function: LmiFloat64Construct

Member Of:

LmiFloat64

Description:

Construct a default instance of an LmiFloat64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat64* LmiFloat64Construct(LmiFloat64* obj)

Parameters:

obj A pointer to the LmiFloat64 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiFloat64 object is initialized with the value 0. LmiFloat64 construction will not fail.

Function: LmiFloat64ConstructCopy

Member Of:

LmiFloat64

Description:

Construct a new LmiFloat64 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiFloat64* LmiFloat64ConstructCopy(LmiFloat64* dst, const LmiFloat64* src)

Parameters:

dst A pointer to the LmiFloat64 object to initialize as a copy.
src An existing LmiFloat64 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiFloat64 construction will not fail.

Function: LmiFloat64Destruct

Member Of:

LmiFloat64

Description:

Destruct an LmiFloat64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiFloat64Destruct(LmiFloat64* obj)

Parameters:

obj A pointer to the LmiFloat64 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiFloat64Equal

Member Of:

LmiFloat64

Description:

Compare the values of two LmiFloat64 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat64Equal(const LmiFloat64* a, const LmiFloat64* b)

Parameters:

a A pointer to the first LmiFloat64 object to be compared.
b A pointer to the second LmiFloat64 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiFloat64Less

Member Of:

LmiFloat64

Description:

Compare the values of two LmiFloat64 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat64Less(const LmiFloat64* a, const LmiFloat64* b)

Parameters:

a A pointer to the first LmiFloat64 object to be compared.
b A pointer to the second LmiFloat64 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiFloat64Swap

Member Of:

LmiFloat64

Description:

Swap the contents of two LmiFloat64 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiFloat64Swap(LmiFloat64* a, LmiFloat64* b)

Parameters:

a A pointer to the first LmiFloat64 object to be swapped.
b A pointer to the second LmiFloat64 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiFloat64 swapping will not fail.

Function: LmiInitTableInitialize

Member Of:

Utils

Description:

Calls the initialization functions specified in an LmiInitTable sequentially. If any initialization function returns LMI_FALSE, no further initialization functions are called and any initialization functions that have already returned LMI_TRUE are rolled back by calling the matching uninitialization functions in reverse order.

Include:

Lmi/Utils/LmiMisc.h

Library:

LmiUtils

Syntax:

LmiBool LmiInitTableInitialize(const LmiInitTable* t, LmiSizeT n)

Parameters:

t An array of LmiInitTable structures, each containing an initialization function and its corresponding uninitialization function.
n The number of elements in the LmiInitTable array.

Returns:

A boolean set to LMI_TRUE if and only if all initialization functions returned LMI_TRUE.

Function: LmiInitTableInitializeEx

Member Of:

Utils

Description:

An extension of LmiInitTableInitialize used to ensure that the initialization functions specified in an LmiInitTable are not called more than once (without intervening uninitializations).

Include:

Lmi/Utils/LmiMisc.h

Library:

LmiUtils

Syntax:

LmiBool LmiInitTableInitializeEx(const LmiInitTable* t, LmiSizeT n, LmiInt* initCount)

Parameters:

t An array of LmiInitTable structures, each containing an initialization function and its corresponding uninitialization function.
n The number of elements in the LmiInitTable array.
initCount The address of an integer variable that will contain the number of calls to LmiInitTableInitializeEx for this LmiInitTable that have not been matched by a call to LmiInitTableUninitializeEx. The variable should be initialized to 0 and passed to each call of LmiInitTableInitializeEx and LmiInitTableUninitializeEx operating on this LmiInitTable.

Returns:

Returns LMI_TRUE if the initializations specified in the LmiInitTable were completed successfully, either just now or in a previous call to LmiInitTableInitializeEx. Returns LMI_FALSE if some initialization functions returned LMI_FALSE.

Note 1:

This function is not reentrant.

Function: LmiInitTableUninitialize

Member Of:

Utils

Description:

Calls the uninitialization functions specified in an LmiInitTable in reverse order. This function will properly uninitialize all initialization done by a successful call to LmiInitTableInitialize taking the same parameters.

Include:

Lmi/Utils/LmiMisc.h

Library:

LmiUtils

Syntax:

void LmiInitTableUninitialize(const LmiInitTable *t, LmiSizeT n)

Parameters:

t An array of LmiInitTable structures, each containing an initialization function and its corresponding uninitialization function.
n The number of elements in the LmiInitTable array.

Function: LmiInitTableUninitializeEx

Member Of:

Utils

Description:

An extension of LmiInitTableUninitialize used to ensure that the initialization functions specified in an LmiInitTable are not called more than once (without intervening uninitializations).

Include:

Lmi/Utils/LmiMisc.h

Library:

LmiUtils

Syntax:

void LmiInitTableUninitializeEx(const LmiInitTable* t, LmiSizeT n, LmiInt* initCount)

Parameters:

t An array of LmiInitTable structures, each containing an initialization function and its corresponding uninitialization function.
n The number of elements in the LmiInitTable array.
initCount The address of an integer variable that will contain the number of calls to LmiInitTableInitializeEx for this LmiInitTable that have not been matched by a call to LmiInitTableUninitializeEx. The variable should be initialized to 0 and passed to each call of LmiInitTableInitializeEx and LmiInitTableUninitializeEx operating on this LmiInitTable.

Note 1:

This function is not reentrant.

Function: LmiInputIteratorIncrement

Member Of:

LmiInputIterator

Description:

Increments the iterator to point at the next object in the container. No checking is performed to ensure that the iterator is in range of the container after the operation.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiInputIterator(T_)* LmiInputIteratorIncrement(T_)(LmiInputIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be incremented.

Returns:

A pointer to the iterator after it has been incremented.

Function: LmiInt16Assign

Member Of:

LmiInt16

Description:

Assign the value of one LmiInt16 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt16* LmiInt16Assign(LmiInt16* dst, const LmiInt16* src)

Parameters:

dst A pointer to the LmiInt16 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiInt16 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiInt16 assignment will not fail.

Function: LmiInt16Construct

Member Of:

LmiInt16

Description:

Construct a default instance of an LmiInt16 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt16* LmiInt16Construct(LmiInt16* obj)

Parameters:

obj A pointer to the LmiInt16 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiInt16 object is initialized with the value 0. LmiInt16 construction will not fail.

Function: LmiInt16ConstructCopy

Member Of:

LmiInt16

Description:

Construct a new LmiInt16 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt16* LmiInt16ConstructCopy(LmiInt16* dst, const LmiInt16* src)

Parameters:

dst A pointer to the LmiInt16 object to initialize as a copy.
src An existing LmiInt16 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiInt16 construction will not fail.

Function: LmiInt16Destruct

Member Of:

LmiInt16

Description:

Destruct an LmiInt16 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiInt16Destruct(LmiInt16* obj)

Parameters:

obj A pointer to the LmiInt16 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiInt16Equal

Member Of:

LmiInt16

Description:

Compare the values of two LmiInt16 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt16Equal(const LmiInt16* a, const LmiInt16* b)

Parameters:

a A pointer to the first LmiInt16 object to be compared.
b A pointer to the second LmiInt16 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiInt16Less

Member Of:

LmiInt16

Description:

Compare the values of two LmiInt16 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt16Less(const LmiInt16* a, const LmiInt16* b)

Parameters:

a A pointer to the first LmiInt16 object to be compared.
b A pointer to the second LmiInt16 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiInt16Swap

Member Of:

LmiInt16

Description:

Swap the contents of two LmiInt16 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt16Swap(LmiInt16* a, LmiInt16* b)

Parameters:

a A pointer to the first LmiInt16 object to be swapped.
b A pointer to the second LmiInt16 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiInt16 swapping will not fail.

Function: LmiInt32Assign

Member Of:

LmiInt32

Description:

Assign the value of one LmiInt32 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt32* LmiInt32Assign(LmiInt32* dst, const LmiInt32* src)

Parameters:

dst A pointer to the LmiInt32 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiInt32 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiInt32 assignment will not fail.

Function: LmiInt32Construct

Member Of:

LmiInt32

Description:

Construct a default instance of an LmiInt32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt32* LmiInt32Construct(LmiInt32* obj)

Parameters:

obj A pointer to the LmiInt32 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiInt32 object is initialized with the value 0. LmiInt32 construction will not fail.

Function: LmiInt32ConstructCopy

Member Of:

LmiInt32

Description:

Construct a new LmiInt32 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt32* LmiInt32ConstructCopy(LmiInt32* dst, const LmiInt32* src)

Parameters:

dst A pointer to the LmiInt32 object to initialize as a copy.
src An existing LmiInt32 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiInt32 construction will not fail.

Function: LmiInt32Destruct

Member Of:

LmiInt32

Description:

Destruct an LmiInt32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiInt32Destruct(LmiInt32* obj)

Parameters:

obj A pointer to the LmiInt32 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiInt32Equal

Member Of:

LmiInt32

Description:

Compare the values of two LmiInt32 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt32Equal(const LmiInt32* a, const LmiInt32* b)

Parameters:

a A pointer to the first LmiInt32 object to be compared.
b A pointer to the second LmiInt32 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiInt32Less

Member Of:

LmiInt32

Description:

Compare the values of two LmiInt32 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt32Less(const LmiInt32* a, const LmiInt32* b)

Parameters:

a A pointer to the first LmiInt32 object to be compared.
b A pointer to the second LmiInt32 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiInt32Swap

Member Of:

LmiInt32

Description:

Swap the contents of two LmiInt32 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt32Swap(LmiInt32* a, LmiInt32* b)

Parameters:

a A pointer to the first LmiInt32 object to be swapped.
b A pointer to the second LmiInt32 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiInt32 swapping will not fail.

Function: LmiInt64Assign

Member Of:

LmiInt64

Description:

Assign the value of one LmiInt64 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt64* LmiInt64Assign(LmiInt64* dst, const LmiInt64* src)

Parameters:

dst A pointer to the LmiInt64 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiInt64 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiInt64 assignment will not fail.

Function: LmiInt64Construct

Member Of:

LmiInt64

Description:

Construct a default instance of an LmiInt64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt64* LmiInt64Construct(LmiInt64* obj)

Parameters:

obj A pointer to the LmiInt64 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiInt64 object is initialized with the value 0. LmiInt64 construction will not fail.

Function: LmiInt64ConstructCopy

Member Of:

LmiInt64

Description:

Construct a new LmiInt64 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt64* LmiInt64ConstructCopy(LmiInt64* dst, const LmiInt64* src)

Parameters:

dst A pointer to the LmiInt64 object to initialize as a copy.
src An existing LmiInt64 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiInt64 construction will not fail.

Function: LmiInt64Destruct

Member Of:

LmiInt64

Description:

Destruct an LmiInt64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiInt64Destruct(LmiInt64* obj)

Parameters:

obj A pointer to the LmiInt64 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiInt64Equal

Member Of:

LmiInt64

Description:

Compare the values of two LmiInt64 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt64Equal(const LmiInt64* a, const LmiInt64* b)

Parameters:

a A pointer to the first LmiInt64 object to be compared.
b A pointer to the second LmiInt64 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiInt64Less

Member Of:

LmiInt64

Description:

Compare the values of two LmiInt64 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt64Less(const LmiInt64* a, const LmiInt64* b)

Parameters:

a A pointer to the first LmiInt64 object to be compared.
b A pointer to the second LmiInt64 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiInt64Swap

Member Of:

LmiInt64

Description:

Swap the contents of two LmiInt64 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt64Swap(LmiInt64* a, LmiInt64* b)

Parameters:

a A pointer to the first LmiInt64 object to be swapped.
b A pointer to the second LmiInt64 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiInt64 swapping will not fail.

Function: LmiInt8Assign

Member Of:

LmiInt8

Description:

Assign the value of one LmiInt8 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt8* LmiInt8Assign(LmiInt8* dst, const LmiInt8* src)

Parameters:

dst A pointer to the LmiInt8 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiInt8 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiInt8 assignment will not fail.

Function: LmiInt8Construct

Member Of:

LmiInt8

Description:

Construct a default instance of an LmiInt8 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt8* LmiInt8Construct(LmiInt8* obj)

Parameters:

obj A pointer to the LmiInt8 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiInt8 object is initialized with the value 0. LmiInt8 construction will not fail.

Function: LmiInt8ConstructCopy

Member Of:

LmiInt8

Description:

Construct a new LmiInt8 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt8* LmiInt8ConstructCopy(LmiInt8* dst, const LmiInt8* src)

Parameters:

dst A pointer to the LmiInt8 object to initialize as a copy.
src An existing LmiInt8 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiInt8 construction will not fail.

Function: LmiInt8Destruct

Member Of:

LmiInt8

Description:

Destruct an LmiInt8 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiInt8Destruct(LmiInt8* obj)

Parameters:

obj A pointer to the LmiInt8 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiInt8Equal

Member Of:

LmiInt8

Description:

Compare the values of two LmiInt8 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt8Equal(const LmiInt8* a, const LmiInt8* b)

Parameters:

a A pointer to the first LmiInt8 object to be compared.
b A pointer to the second LmiInt8 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiInt8Less

Member Of:

LmiInt8

Description:

Compare the values of two LmiInt8 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt8Less(const LmiInt8* a, const LmiInt8* b)

Parameters:

a A pointer to the first LmiInt8 object to be compared.
b A pointer to the second LmiInt8 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiInt8Swap

Member Of:

LmiInt8

Description:

Swap the contents of two LmiInt8 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiInt8Swap(LmiInt8* a, LmiInt8* b)

Parameters:

a A pointer to the first LmiInt8 object to be swapped.
b A pointer to the second LmiInt8 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiInt8 swapping will not fail.

Function: LmiIntAbsoluteValue

Member Of:

LmiInt

Description:

Get the absolute value of an integer.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt LmiIntAbsoluteValue(const LmiInt* x)

Parameters:

x A pointer to an LmiInt object.

Returns:

An LmiInt containing the absolute value of the LmiInt pointed to by x.

Function: LmiIntAssign

Member Of:

LmiInt

Description:

Assign the value of one LmiInt object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt* LmiIntAssign(LmiInt* dst, const LmiInt* src)

Parameters:

dst A pointer to the LmiInt object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiInt object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiInt assignment will not fail.

Function: LmiIntConstruct

Member Of:

LmiInt

Description:

Construct a default instance of an LmiInt object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt* LmiIntConstruct(LmiInt* obj)

Parameters:

obj A pointer to the LmiInt object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiInt object is initialized with the value 0. LmiInt construction will not fail.

Function: LmiIntConstructCopy

Member Of:

LmiInt

Description:

Construct a new LmiInt object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiInt* LmiIntConstructCopy(LmiInt* dst, const LmiInt* src)

Parameters:

dst A pointer to the LmiInt object to initialize as a copy.
src An existing LmiInt object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiInt construction will not fail.

Function: LmiIntDestruct

Member Of:

LmiInt

Description:

Destruct an LmiInt object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiIntDestruct(LmiInt* obj)

Parameters:

obj A pointer to the LmiInt object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiIntEqual

Member Of:

LmiInt

Description:

Compare the values of two LmiInt objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntEqual(const LmiInt* a, const LmiInt* b)

Parameters:

a A pointer to the first LmiInt object to be compared.
b A pointer to the second LmiInt object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiIntLess

Member Of:

LmiInt

Description:

Compare the values of two LmiInt objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntLess(const LmiInt* a, const LmiInt* b)

Parameters:

a A pointer to the first LmiInt object to be compared.
b A pointer to the second LmiInt object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiIntPtrTAssign

Member Of:

LmiIntPtrT

Description:

Assign the value of one LmiIntPtrT object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiIntPtrT* LmiIntPtrTAssign(LmiIntPtrT* dst, const LmiIntPtrT* src)

Parameters:

dst A pointer to the LmiIntPtrT object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiIntPtrT object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiIntPtrT assignment will not fail.

Function: LmiIntPtrTConstruct

Member Of:

LmiIntPtrT

Description:

Construct a default instance of an LmiIntPtrT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiIntPtrT* LmiIntPtrTConstruct(LmiIntPtrT* obj)

Parameters:

obj A pointer to the LmiIntPtrT object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiIntPtrT object is initialized with the value 0. LmiIntPtrT construction will not fail.

Function: LmiIntPtrTConstructCopy

Member Of:

LmiIntPtrT

Description:

Construct a new LmiIntPtrT object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiIntPtrT* LmiIntPtrTConstructCopy(LmiIntPtrT* dst, const LmiIntPtrT* src)

Parameters:

dst A pointer to the LmiIntPtrT object to initialize as a copy.
src An existing LmiIntPtrT object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiIntPtrT construction will not fail.

Function: LmiIntPtrTDestruct

Member Of:

LmiIntPtrT

Description:

Destruct an LmiIntPtrT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiIntPtrTDestruct(LmiIntPtrT* obj)

Parameters:

obj A pointer to the LmiIntPtrT object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiIntPtrTEqual

Member Of:

LmiIntPtrT

Description:

Compare the values of two LmiIntPtrT objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntPtrTEqual(const LmiIntPtrT* a, const LmiIntPtrT* b)

Parameters:

a A pointer to the first LmiIntPtrT object to be compared.
b A pointer to the second LmiIntPtrT object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiIntPtrTLess

Member Of:

LmiIntPtrT

Description:

Compare the values of two LmiIntPtrT objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntPtrTLess(const LmiIntPtrT* a, const LmiIntPtrT* b)

Parameters:

a A pointer to the first LmiIntPtrT object to be compared.
b A pointer to the second LmiIntPtrT object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiIntPtrTSwap

Member Of:

LmiIntPtrT

Description:

Swap the contents of two LmiIntPtrT objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntPtrTSwap(LmiIntPtrT* a, LmiIntPtrT* b)

Parameters:

a A pointer to the first LmiIntPtrT object to be swapped.
b A pointer to the second LmiIntPtrT object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiIntPtrT swapping will not fail.

Function: LmiIntSwap

Member Of:

LmiInt

Description:

Swap the contents of two LmiInt objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiIntSwap(LmiInt* a, LmiInt* b)

Parameters:

a A pointer to the first LmiInt object to be swapped.
b A pointer to the second LmiInt object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiInt swapping will not fail.

Function: LmiLexicographicalCompare

Member Of:

Algorithms

Description:

Do a lexicographical comparison of two sequences.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

LmiBool LmiLexicographicalCompare(I)(I ai, I ae, I bi, I be)

Template Parameters:

I The iterator type of the containers containing the items to process. The iterator type must be a model of LmiInputIterator.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.

Returns:

Returns LMI_TRUE if the first sequence precedes the second sequence in lexicographical order.

Note 1:

The macro Define_LmiLexicographicalCompare must be called at global scope before calling this function.

Function: LmiLexicographicalCompareComp

Member Of:

Algorithms

Description:

Do a lexicographical comparison of two sequences.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

LmiBool LmiLexicographicalCompareComp(I, Comp)(I ai, I ae, I bi, I be)

Template Parameters:

I The iterator type of the containers containing the items to process. The iterator type must be a model of LmiInputIterator.
Comp The comparison function for elements.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.

Returns:

Returns LMI_TRUE if the first sequence precedes the second sequence in lexicographical order.

Note 1:

The macro Define_LmiLexicographicalCompareComp must be called at global scope before calling this function.

Function: LmiLinearMotionConstruct

Member Of:

LmiLinearMotion

Description:

Constructs an LmiLinearMotion object. This defines the number of axes and the initial position of the moving object.

Include:

Lmi/Utils/LmiLinearMotion.h

Library:

LmiUtils

Syntax:

LmiLinearMotion *LmiLinearMotionConstruct(LmiLinearMotion *lm, const LmiFloat64 *pos, LmiUint numAxes, LmiMotionProfile *profile, LmiAllocator *alloc)

Parameters:

lm The LmiLinearMotion object to construct.
pos An array of values providing the object's initial position. If NULL, this will initialize all values to 0.
numAxes The number of dimensions that the object will be moving through. (This should be the number of elements in the pos array.)
profile The motion profile to use. Controls the smoothness of the motion.
alloc An allocator to use for miscellaneous items.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiLinearMotionDestruct

Member Of:

LmiLinearMotion

Description:

Destructs an LmiLinearMotion object.

Include:

Lmi/Utils/LmiLinearMotion.h

Library:

LmiUtils

Syntax:

void LmiLinearMotionDestruct(LmiLinearMotion *lm)

Parameters:

lm The LmiLinearMotion object to destruct.

Function: LmiLinearMotionGetPosition

Member Of:

LmiLinearMotion

Description:

Gets the current position of a moving object as a function of time.

Include:

Lmi/Utils/LmiLinearMotion.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearMotionGetPosition(LmiLinearMotion *lm, LmiFloat64 t, LmiFloat64 *pos)

Parameters:

lm The LmiLinearMotion object.
t The current time.
pos The object's position at the specified time is written into this array. The array should contain one element for each dimension being tracked. Note: only the last programmed move (via LmiLinearMotionMoveTo) is used to determine the position; no history of previous moves is kept. If the time passed is earlier than the start time of the current move, then the start position of the current move is returned.

Returns:

A boolean indicating whether the current move has been completed.

Function: LmiLinearMotionMoveTo

Member Of:

LmiLinearMotion

Description:

Move in a straight line to a new position in a specified amount of time.

Include:

Lmi/Utils/LmiLinearMotion.h

Library:

LmiUtils

Syntax:

void LmiLinearMotionMoveTo(LmiLinearMotion *lm, LmiFloat64 t0, LmiFloat64 dt, const LmiFloat64 *pos)

Parameters:

lm The LmiLinearMotion object.
t0 The start time of the motion.
dt The duration of the motion.
pos The target position.

Note 1:

Any units for times and positions can be used.

Function: LmiLinearMotionSetPosition

Member Of:

LmiLinearMotion

Description:

Sets the current position for an LmiLinearMotion object. This terminates any move in progress and instantaneously moves the object to a new position.

Include:

Lmi/Utils/LmiLinearMotion.h

Library:

LmiUtils

Syntax:

void LmiLinearMotionSetPosition(LmiLinearMotion *lm, const LmiFloat64 *pos)

Parameters:

lm The LmiLinearMotion object.
pos The new position of the object.

Function: LmiLinearProgrammingConstraintAssign

Member Of:

LmiLinearProgrammingConstraint

Description:

Assign a linear programming constraint object from another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingConstraint* LmiLinearProgrammingConstraintAssign(LmiLinearProgrammingConstraint *x, const LmiLinearProgrammingConstraint *y)

Parameters:

x The LmiLinearProgrammingConstraint object to be assigned.
y The LmiLinearProgrammingConstraint object from which the object need to be assigned.

Returns:

Pointer to the assigned object on success, NULL otherwise.

Function: LmiLinearProgrammingConstraintConstruct

Member Of:

LmiLinearProgrammingConstraint

Description:

Construct a linear programming constraint object by providing variable coefficients by name of variables.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingConstraint* LmiLinearProgrammingConstraintConstruct(LmiLinearProgrammingConstraint *constraint, const LmiVector(LmiPair(LmiString, LmiFloat32)) *variableCoefficients, LmiFloat32 rhs, LmiAllocator *alloc)

Parameters:

constraint The LmiLinearProgrammingConstraint object to be constructed.
variableCoefficients The variable coefficients by name of variables.
rhs The RHS value of the constraint.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingConstraintConstructCopy

Member Of:

LmiLinearProgrammingConstraint

Description:

Construct copy a linear programming constraint object from another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingConstraint* LmiLinearProgrammingConstraintConstructCopy(LmiLinearProgrammingConstraint *x, const LmiLinearProgrammingConstraint *y)

Parameters:

x The LmiLinearProgrammingConstraint object to be constructed.
y The LmiLinearProgrammingConstraint object from which the new object need to be constructed.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingConstraintConstructIndex

Member Of:

LmiLinearProgrammingConstraint

Description:

Construct a linear programming constraint object by providing variable coefficients by index.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingConstraint* LmiLinearProgrammingConstraintConstructIndex(LmiLinearProgrammingConstraint *constraint, const LmiVector(LmiPair(LmiUint, LmiFloat32)) *variableCoefficients, LmiFloat32 rhs, LmiAllocator *alloc)

Parameters:

constraint The LmiLinearProgrammingConstraint object to be constructed.
variableCoefficients The variable coefficients by index.
rhs The RHS value of the constraint.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingConstraintDestruct

Member Of:

LmiLinearProgrammingConstraint

Description:

Destruct the linear programming constraint object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingConstraintDestruct(LmiLinearProgrammingConstraint *constraint)

Parameters:

constraint The LmiLinearProgrammingConstraint object to be destructed.

Function: LmiLinearProgrammingConstraintEqual

Member Of:

LmiLinearProgrammingConstraint

Description:

Check for the equality of two linear programming constraint objects.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingConstraintEqual(const LmiLinearProgrammingConstraint *x, const LmiLinearProgrammingConstraint *y)

Parameters:

x The LmiLinearProgrammingConstraint object.
y The LmiLinearProgrammingConstraint object.

Returns:

LMI_TRUE if equal, LMI_FALSE otherwise.

Function: LmiLinearProgrammingConstraintGetRhs

Member Of:

LmiLinearProgrammingConstraint

Description:

Get the RHS of the linear programming constraint.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiFloat32 LmiLinearProgrammingConstraintGetRhs(const LmiLinearProgrammingConstraint *c)

Parameters:

c The LmiLinearProgrammingConstraint object.

Returns:

The RHS of the constraint.

Function: LmiLinearProgrammingConstraintGetVariableAccessType

Member Of:

LmiLinearProgrammingConstraint

Description:

Get variable access type of the linear programming constraint object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariableAccessType LmiLinearProgrammingConstraintGetVariableAccessType(const LmiLinearProgrammingConstraint *c)

Parameters:

c The LmiLinearProgrammingConstraint object.

Returns:

The variable access type of the constraint.

Function: LmiLinearProgrammingConstraintGetVariablesCoefficientsByIndex

Member Of:

LmiLinearProgrammingConstraint

Description:

Get the variable coefficients of the linear programming constraint object by index of variables.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

const LmiVector(LmiPair(LmiUint, LmiFloat32))* LmiLinearProgrammingConstraintGetVariablesCoefficientsByIndex(const LmiLinearProgrammingConstraint *c)

Parameters:

c The LmiLinearProgrammingConstraint object.

Returns:

The variable coefficients by index of variables.

Function: LmiLinearProgrammingConstraintGetVariablesCoefficientsByName

Member Of:

LmiLinearProgrammingConstraint

Description:

Get the variable coefficients of the linear programming constraint object by name of variables.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

const LmiVector(LmiPair(LmiString, LmiFloat32))* LmiLinearProgrammingConstraintGetVariablesCoefficientsByName(const LmiLinearProgrammingConstraint *c)

Parameters:

c The LmiLinearProgrammingConstraint object.

Returns:

The variable coefficients by name of variables.

Function: LmiLinearProgrammingConstraintLess

Member Of:

LmiLinearProgrammingConstraint

Description:

Check whether a linear programming constraint object is less than another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingConstraintLess(const LmiLinearProgrammingConstraint *x, const LmiLinearProgrammingConstraint *y)

Parameters:

x The LmiLinearProgrammingConstraint object.
y The LmiLinearProgrammingConstraint object.

Returns:

LMI_TRUE if x is less than y, LMI_FALSE otherwise.

Function: LmiLinearProgrammingConstruct

Member Of:

LmiLinearProgramming

Description:

Construct a linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgramming* LmiLinearProgrammingConstruct(LmiLinearProgramming* lp, LmiUint numVars, LmiAllocator *alloc)

Parameters:

lp The LmiLinearProgramming object to be constructed.
numVars Number of decision variables.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingConstructDefault

Member Of:

LmiLinearProgramming

Description:

Construct a default linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgramming* LmiLinearProgrammingConstructDefault(LmiLinearProgramming* lp, LmiAllocator *alloc)

Parameters:

lp The LmiLinearProgramming object to be constructed.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingDestruct

Member Of:

LmiLinearProgramming

Description:

Destruct the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingDestruct(LmiLinearProgramming *lp)

Parameters:

lp The LmiLinearProgramming object to be destructed.

Function: LmiLinearProgrammingGetNumConstraints

Member Of:

LmiLinearProgramming

Description:

Get number of decision variables on linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiUint LmiLinearProgrammingGetNumConstraints(const LmiLinearProgramming* lp)

Parameters:

lp The LmiLinearProgramming object.

Returns:

Number of constraints.

Function: LmiLinearProgrammingGetNumVars

Member Of:

LmiLinearProgramming

Description:

Get number of decision variables on linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiUint LmiLinearProgrammingGetNumVars(const LmiLinearProgramming* lp)

Parameters:

lp The LmiLinearProgramming object.

Returns:

Number of decision variables.

Function: LmiLinearProgrammingGetObjectiveValue

Member Of:

LmiLinearProgramming

Description:

Get the object value of linear programming problem solution.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiFloat32 LmiLinearProgrammingGetObjectiveValue(const LmiLinearProgramming* lp)

Parameters:

lp The LmiLinearProgramming object.

Returns:

The objective value.

Function: LmiLinearProgrammingGetVariableValues

Member Of:

LmiLinearProgramming

Description:

Get the decision variable values of linear programming problem solution.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

const LmiVector(LmiPair(LmiString, LmiFloat32))* LmiLinearProgrammingGetVariableValues(const LmiLinearProgramming* lp)

Parameters:

lp The LmiLinearProgramming object.

Returns:

The values of the decision variables.

Function: LmiLinearProgrammingRemoveConstraint

Member Of:

LmiLinearProgramming

Description:

Remove a constraint by id from the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingRemoveConstraint(LmiLinearProgramming* lp, LmiUint constraintId)

Parameters:

lp The LmiLinearProgramming object.
constraintId The id of the constraint.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetConstraint

Member Of:

LmiLinearProgramming

Description:

Set a constraint by id to the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetConstraint(LmiLinearProgramming* lp, LmiUint constraintId, const LmiLinearProgrammingConstraint *constraint)

Parameters:

lp The LmiLinearProgramming object.
constraintId The id of the constraint.
constraint The LmiLinearProgrammingConstraint object.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetConstraintByIndex

Member Of:

LmiLinearProgramming

Description:

Set a constraint by index of variables to the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetConstraintByIndex(LmiLinearProgramming* lp, LmiUint constraintId, const LmiVector(LmiPair(LmiUint, LmiFloat32)) *constraintValues, LmiFloat32 rhs)

Parameters:

lp The LmiLinearProgramming object.
constraintId The id of the constraint.
constraintValues Coefficient of the decision variables in the constraint. Each element of the vector is a pair of index of the variable and the coefficient of the variable.
rhs Right hand side value of the constraint.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetConstraintByName

Member Of:

LmiLinearProgramming

Description:

Set constraint by name of variables on the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetConstraintByName(LmiLinearProgramming* lp, LmiUint constraintId, const LmiVector(LmiPair(LmiString, LmiFloat32)) *constraintValues, LmiFloat32 rhs)

Parameters:

lp The LmiLinearProgramming object.
constraintId The id of the constraint.
constraintValues Coefficient of the decision variables in the constraint. Each element of the vector is a pair of name of the variable and the coefficient of the variable.
rhs Right hand side value of the constraint.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetNumVars

Member Of:

LmiLinearProgramming

Description:

Set number of decision variables on linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetNumVars(LmiLinearProgramming* lp, LmiUint numVars)

Parameters:

lp The LmiLinearProgramming object.
numVars Number of decision variables.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetObjective

Member Of:

LmiLinearProgramming

Description:

Set the objective coefficients of decision variables by names to the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetObjective(LmiLinearProgramming* lp, const LmiVector(LmiPair(LmiString, LmiFloat32)) *objectiveValues)

Parameters:

lp The LmiLinearProgramming object.
objectiveValues Coefficient of the decision variables in the objective. Each element of the vector is a pair of name of the variable and the coefficient of the variable.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSetObjectiveByIndex

Member Of:

LmiLinearProgramming

Description:

Set the objective coefficients of decision variables by index to the linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingSetObjectiveByIndex(LmiLinearProgramming* lp, const LmiVector(LmiPair(LmiUint, LmiFloat32)) *objectiveValues)

Parameters:

lp The LmiLinearProgramming object.
objectiveValues Coefficient of the decision variables in the objective. Each element of the vector is a pair of index of the variable and the coefficient of the variable.

Function: LmiLinearProgrammingSetVariableInfo

Member Of:

LmiLinearProgramming

Description:

Set variable names to decision variables of linear programming object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingSetVariableInfo(LmiLinearProgramming* lp, LmiUint variableIndex, const LmiString *name, LmiLinearProgrammingVariableType type)

Parameters:

lp The LmiLinearProgramming object.
variableIndex Index of decision variable.
name Name of decision variable.
type Type of decision variable.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingSolve

Member Of:

LmiLinearProgramming

Description:

Solve the linear programming problem.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingResultType LmiLinearProgrammingSolve(LmiLinearProgramming* lp)

Parameters:

lp The LmiLinearProgramming object.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Function: LmiLinearProgrammingVariableAssign

Member Of:

LmiLinearProgrammingVariable

Description:

Assign a linear programming variable object from another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariable* LmiLinearProgrammingVariableAssign(LmiLinearProgrammingVariable *x, const LmiLinearProgrammingVariable *y)

Parameters:

x The LmiLinearProgrammingVariable object to be assigned.
y The LmiLinearProgrammingVariable object from which the object need to be assigned.

Returns:

Pointer to the assigned object on success, NULL otherwise.

Function: LmiLinearProgrammingVariableConstruct

Member Of:

LmiLinearProgrammingVariable

Description:

Construct a linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariable* LmiLinearProgrammingVariableConstruct(LmiLinearProgrammingVariable *variable, LmiLinearProgrammingVariableType type, LmiUint index, const LmiString *name, LmiAllocator *alloc)

Parameters:

variable The LmiLinearProgrammingVariable object to be constructed.
type The LmiLinearProgrammingVariable object to be constructed.
index The index of the variable.
name The name of the variable.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingVariableConstructCopy

Member Of:

LmiLinearProgrammingVariable

Description:

Construct copy a linear programming variable object from another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariable* LmiLinearProgrammingVariableConstructCopy(LmiLinearProgrammingVariable *x, const LmiLinearProgrammingVariable *y)

Parameters:

x The LmiLinearProgrammingVariable object to be constructed.
y The LmiLinearProgrammingVariable object from which the new object need to be constructed.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingVariableConstructDefault

Member Of:

LmiLinearProgrammingVariable

Description:

Construct a default linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariable* LmiLinearProgrammingVariableConstructDefault(LmiLinearProgrammingVariable *variable, LmiAllocator *alloc)

Parameters:

variable The LmiLinearProgrammingVariable object to be constructed.
alloc An allocator to allocate memory.

Returns:

Pointer to the constructed object on success, NULL otherwise.

Function: LmiLinearProgrammingVariableDestruct

Member Of:

LmiLinearProgrammingVariable

Description:

Destruct the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingVariableDestruct(LmiLinearProgrammingVariable *variable)

Parameters:

variable The LmiLinearProgrammingVariable object to be destructed.

Function: LmiLinearProgrammingVariableEqual

Member Of:

LmiLinearProgrammingVariable

Description:

Check for the equality of two linear programming variable objects.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingVariableEqual(const LmiLinearProgrammingVariable *x, const LmiLinearProgrammingVariable *y)

Parameters:

x The LmiLinearProgrammingVariable object.
y The LmiLinearProgrammingVariable object.

Returns:

LMI_TRUE if equal, LMI_FALSE otherwise.

Function: LmiLinearProgrammingVariableGetIndex

Member Of:

LmiLinearProgrammingVariable

Description:

Get index of the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiUint LmiLinearProgrammingVariableGetIndex(const LmiLinearProgrammingVariable *variable)

Parameters:

variable The LmiLinearProgrammingVariable object.

Returns:

The index of the variable.

Function: LmiLinearProgrammingVariableGetName

Member Of:

LmiLinearProgrammingVariable

Description:

Get name of the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

const LmiString* LmiLinearProgrammingVariableGetName(const LmiLinearProgrammingVariable *variable)

Parameters:

variable The LmiLinearProgrammingVariable object.

Returns:

The name of the variable.

Function: LmiLinearProgrammingVariableGetType

Member Of:

LmiLinearProgrammingVariable

Description:

Get type of the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiLinearProgrammingVariableType LmiLinearProgrammingVariableGetType(const LmiLinearProgrammingVariable *variable)

Parameters:

variable The LmiLinearProgrammingVariable object.

Returns:

The type of the variable.

Function: LmiLinearProgrammingVariableLess

Member Of:

LmiLinearProgrammingVariable

Description:

Check whether a linear programming variable object is less than another object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

LmiBool LmiLinearProgrammingVariableLess(const LmiLinearProgrammingVariable *x, const LmiLinearProgrammingVariable *y)

Parameters:

x The LmiLinearProgrammingVariable object.
y The LmiLinearProgrammingVariable object.

Returns:

LMI_TRUE if x is less than y, LMI_FALSE otherwise.

Function: LmiLinearProgrammingVariableSetIndex

Member Of:

LmiLinearProgrammingVariable

Description:

Set index on the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingVariableSetIndex(LmiLinearProgrammingVariable *variable, LmiUint index)

Parameters:

variable The LmiLinearProgrammingVariable object.
index The index of the variable.

Function: LmiLinearProgrammingVariableSetName

Member Of:

LmiLinearProgrammingVariable

Description:

Set name on the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingVariableSetName(LmiLinearProgrammingVariable *variable, const LmiString *name)

Parameters:

variable The LmiLinearProgrammingVariable object.
name The name of the variable.

Function: LmiLinearProgrammingVariableSetType

Member Of:

LmiLinearProgrammingVariable

Description:

Set type on the linear programming variable object.

Include:

Lmi/Utils/LmiLinearProgramming.h

Library:

LmiUtils

Syntax:

void LmiLinearProgrammingVariableSetType(LmiLinearProgrammingVariable *variable, LmiLinearProgrammingVariableType type)

Parameters:

variable The LmiLinearProgrammingVariable object.
type The type of the variable.

Function: LmiLocationAssign

Member Of:

LmiLocation

Description:

Assign one geographic location object the value of another.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiLocation *LmiLocationAssign(LmiLocation *loc, const LmiLocation *other)

Parameters:

loc The location object to assign to.
other The location object to copy.

Returns:

The assigned object or NULL on failure.

Function: LmiLocationConstruct

Member Of:

LmiLocation

Description:

Construct an LmiLocation object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiLocation *LmiLocationConstruct(LmiLocation *loc, LmiFloat64 latitude, LmiFloat64 longitude, LmiFloat64 altitude)

Parameters:

loc The location object to be constructed.
latitude The latitude of the location in degrees.
longitude The longitude of the location in degrees.
altitude The altitude of the location in meters.

Returns:

The constructed object or NULL on failure.

Function: LmiLocationConstructCopy

Member Of:

LmiLocation

Description:

Construct a geographic location object as a copy of an existing object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiLocation *LmiLocationConstructCopy(LmiLocation *loc, const LmiLocation *other)

Parameters:

loc The location object to be constructed.
other The location object to copy.

Returns:

The constructed object or NULL on failure.

Function: LmiLocationConstructDefault

Member Of:

LmiLocation

Description:

Construct an LmiLocation object with an arbitrary location.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiLocation *LmiLocationConstructDefault(LmiLocation *loc)

Parameters:

loc The location object to be constructed.

Returns:

The constructed object or NULL on failure.

Function: LmiLocationDestruct

Member Of:

LmiLocation

Description:

Destruct an LmiLocation object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

void LmiLocationDestruct(LmiLocation *loc)

Parameters:

loc The location object to be destructed.

Function: LmiLocationGetAltitude

Member Of:

LmiLocation

Description:

Get the altitude from a geographic location object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiLocationGetAltitude(const LmiLocation *loc)

Parameters:

loc The location object.

Returns:

The altitude in meters.

Function: LmiLocationGetLatitude

Member Of:

LmiLocation

Description:

Get the latitude from a geographic location object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiLocationGetLatitude(const LmiLocation *loc)

Parameters:

loc The location object.

Returns:

The latitude in degrees.

Function: LmiLocationGetLongitude

Member Of:

LmiLocation

Description:

Get the longitude from a geographic location object.

Include:

Lmi/Utils/LmiLocation.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiLocationGetLongitude(const LmiLocation *loc)

Parameters:

loc The location object.

Returns:

The longitude in degrees.

Function: LmiMatrixAdd

Member Of:

LmiMatrix

Description:

Add two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixAdd(T_)(const LmiMatrix(T_)* x, const LmiMatrix(T_)* y, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x One of the matrix to add.
y Other matrix to add.
result Default constructed matrix to which the result of matrix addition is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The dimensions of both the matrices to add should be the same.

Function: LmiMatrixAssign

Member Of:

LmiMatrix

Description:

Copy one matrix to another.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixAssign(T_)(LmiMatrix(T_)* x, const LmiMatrix(T_)* y)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to assign to.
y The matrix to assign from.

Returns:

A pointer to the assigned to matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

A matrix can be assigned with a matrix of different dimensions.

Function: LmiMatrixAt

Member Of:

LmiMatrix

Description:

Retrieve a pointer to the element of the matrix at index row,col.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

T_ LmiMatrixAt(T_)(const LmiMatrix(T_)* x, LmiUint row, LmiUint col)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix.
row The row index of the element to retrieve.
col The column index of the element to retrieve.

Returns:

The element of the matrix at index row,col.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixConstruct

Member Of:

LmiMatrix

Description:

Construct a matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixConstruct(T_)(LmiMatrix(T_)* x, LmiUint numRows, LmiUint numCols, LmiAllocator* a)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
numRows The number of rows in the matrix to construct.
numCols The number of columns in the matrix to construct.
a The matrix's allocator.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

Number of rows and number of columns both need to be either zero or non-zero.

Function: LmiMatrixConstructCopy

Member Of:

LmiMatrix

Description:

Construct a matrix from another matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixConstructCopy(T_)(LmiMatrix(T_)* x, const LmiMatrix(T_)* y)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
y The matrix to use to initialize the matrix being constructed.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixConstructCopyRange

Member Of:

LmiMatrix

Description:

Construct a matrix as a sub-matrix of another matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixConstructCopyRange(T_)(LmiMatrix(T_)* x, const LmiMatrix(T_)* y, LmiUint sourceRow, LmiUint sourceCol, LmiUint numRows, LmiUint numCols, LmiAllocator *a)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
y The matrix to use to initialize the matrix being constructed.
sourceRow The source row in the source matrix from which the data is copied to the new matrix being constructed.
sourceCol The source column in the source matrix from which the data is copied to the new matrix being constructed.
numRows The number of rows to be copied.
numCols The number of columns to be copied.
a The matrix's allocator.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixConstructDefault

Member Of:

LmiMatrix

Description:

Construct an empty matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixConstructDefault(T_)(LmiMatrix(T_)* x, LmiAllocator* a)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
a The matrix's allocator.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixConstructIdentity

Member Of:

LmiMatrix

Description:

Construct an identity matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixConstructIdentity(T_)(LmiMatrix(T_)* x, LmiUint dimension, LmiAllocator* a)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
dimension The size of the identity matrix to construct.
a The matrix's allocator.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

Dimension should be non-zero.

Function: LmiMatrixCopyRange

Member Of:

LmiMatrix

Description:

Construct a matrix as a sub-matrix of another matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixCopyRange(T_)(LmiMatrix(T_)* x, const LmiMatrix(T_)* y, LmiUint xSourceRow, LmiUint xSourceCol, LmiUint ySourceRow, LmiUint ySourceCol, LmiUint numRows, LmiUint numCols)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to construct.
y The matrix to use to initialize the matrix being constructed.
xSourceRow The source row of the destination matrix to which the data is copied.
xSourceCol The source column of the source matrix to which the data is copied.
ySourceRow The source row in the source matrix from which the data is copied.
ySourceCol The source column in the source matrix from which the data is copied.
numRows The number of rows to be copied.
numCols The number of columns to be copied.

Returns:

A pointer to the constructed matrix or NULL on error.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixDestruct

Member Of:

LmiMatrix

Description:

Destruct a matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

void LmiMatrixDestruct(T_)(LmiMatrix(T_)* x)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to destruct.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixEqual

Member Of:

LmiMatrix

Description:

Test two matrices for equality.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixEqual(T_)(const LmiMatrix(T_)* x, const LmiMatrix(T_)* y)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to compare.
y The other matrix to compare.

Returns:

LMI_TRUE if the matrices are equal or LMI_FALSE if they are not.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixGetAllocator

Member Of:

LmiMatrix

Description:

Gets a pointer to the matrix's allocator.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiAllocator* LmiMatrixGetAllocator(T_)(const LmiMatrix(T_)* x)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix.

Returns:

A pointer to the matrix's allocator.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixGetNumColumns

Member Of:

LmiMatrix

Description:

Get the number of columns of the matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiUint LmiMatrixGetNumColumns(T_)(const LmiMatrix(T_)* x)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix.

Returns:

The number of columns of the matrix.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixGetNumRows

Member Of:

LmiMatrix

Description:

Get the number of rows of the matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiUint LmiMatrixGetNumRows(T_)(const LmiMatrix(T_)* x)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix.

Returns:

The number of rows of the matrix.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixInverse

Member Of:

LmiMatrix

Description:

Inverse a matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixInverse(T_)(const LmiMatrix(T_)* x, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x Matrix which need to be inverted.
result Default constructed matrix to which the inverse matrix is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The input matrix should be a square matrix, with the number of rows equal to the number of columns.

Note 3:

The dimensions of the result matrix is same as that of x.

Function: LmiMatrixLess

Member Of:

LmiMatrix

Description:

Test whether one matrix is lexicographically less than another.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixLess(T_)(const LmiMatrix(T_)* x, const LmiMatrix(T_)* y)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to compare.
y The other matrix to compare.

Returns:

LMI_TRUE if the first matrix is lexicographically less than the second matrix or LMI_FALSE if it is not.

Note 1:

The macro Declare_LmiMatrixLess must be called at global scope before calling LmiMatrixLess member functions.

Function: LmiMatrixMultiply

Member Of:

LmiMatrix

Description:

Multiply two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixMultiply(T_)(const LmiMatrix(T_)* x, const LmiMatrix(T_)* y, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x LHS matrix to multiply.
y RHS matrix to multiply.
result Default constructed matrix to which the result of matrix multiplication is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The number of columns of x should be same as the number of rows of y.

Note 3:

The dimension of the result matrix is number of rows of x by number of columns of y.

Function: LmiMatrixMultiplyScalar

Member Of:

LmiMatrix

Description:

Multiply a matrix by a scalar.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixMultiplyScalar(T_)(const LmiMatrix(T_)* x, T_* y, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x LHS matrix to multiply.
y A scalar to multiply the matrix with.
result Default constructed matrix to which the result of matrix scalar multiplication is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The number of columns of x should be same as the number of rows of y.

Note 3:

The dimension of the result matrix is number of rows of x by number of columns of y.

Function: LmiMatrixReset

Member Of:

LmiMatrix

Description:

Reset of content of the matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

void LmiMatrixReset(T_)(LmiMatrix(T_)* x)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to reset.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

All the elements of the matrix will be set to zero.

Function: LmiMatrixResize

Member Of:

LmiMatrix

Description:

Resize a matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiMatrix(T_)* LmiMatrixResize(T_)(LmiMatrix(T_)* x, LmiUint rows, LmiUint cols)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to resize.
rows The new number of rows in the matrix.
cols The new number of columns in the matrix.

Returns:

Pointer to the resized matrix or NULL on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

Number of rows and number of columns both need to be either zero or non-zero.

Function: LmiMatrixSetVal

Member Of:

LmiMatrix

Description:

Set the value of an element of the matrix at index row,col.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

void LmiMatrixSetVal(T_)(LmiMatrix(T_)* x, LmiUint row, LmiUint col, T_ val)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix.
row The row index of the element to set.
col The column index of the element to set.
val The value to set.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Function: LmiMatrixSubtract

Member Of:

LmiMatrix

Description:

Subtract two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixSubtract(T_)(const LmiMatrix(T_)* x, const LmiMatrix(T_)* y, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x Matrix to subtract from.
y Matrix to subtract.
result Default constructed matrix to which the result of matrix subtraction is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The dimensions of both the matrices to subtract should be the same.

Function: LmiMatrixSwap

Member Of:

LmiMatrix

Description:

Swap two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixSwap(T_)(LmiMatrix(T_)* x, LmiMatrix(T_)* y)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to swap.
y The other matrix to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The dimensions of both the matrices should be same.

Function: LmiMatrixSwapColumn

Member Of:

LmiMatrix

Description:

Swap a column of two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixSwapColumn(T_)(LmiMatrix(T_)* x, LmiMatrix(T_)* y, LmiUint columnX, LmiUint columnY)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to swap.
y The other matrix to swap.
columnX The column of matrix x to swap.
columnY The column of matrix y to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

Number of rows of both the matrices should be same.

Function: LmiMatrixSwapRow

Member Of:

LmiMatrix

Description:

Swap a row of two matrices.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixSwapRow(T_)(LmiMatrix(T_)* x, LmiMatrix(T_)* y, LmiUint rowX, LmiUint rowY)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x The matrix to swap.
y The other matrix to swap.
rowX The row of matrix x to swap.
rowY The row of matrix y to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

Number of columns of both the matrices should be same.

Function: LmiMatrixTranspose

Member Of:

LmiMatrix

Description:

Transpose a matrix.

Include:

Lmi/Utils/LmiMatrix.h

Library:

LmiUtils

Syntax:

LmiBool LmiMatrixTranspose(T_)(const LmiMatrix(T_)* x, LmiMatrix(T_)* result)

Template Parameters:

T_ The type of matrix elements.

Parameters:

x Matrix which need to be transposed.
result Default constructed matrix to which the transposed matrix is stored.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiMatrix must be called at global scope before calling any LmiMatrix member functions.

Note 2:

The rows and columns of the matrix are exchanged in the result matrix. The dimension of the result matrix is number of columns of x by number of rows of x.

Function: LmiMediaFormatAssign

Member Of:

LmiMediaFormat

Description:

Copy the content of one media format object to another.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiMediaFormat* LmiMediaFormatAssign(LmiMediaFormat* x, const LmiMediaFormat* y)

Parameters:

x The media format object.
y The media format object to copy from.

Returns:

The object assigned to or NULL on error.

Function: LmiMediaFormatConstruct

Member Of:

LmiMediaFormat

Description:

Constructs a media format object and initializes it from a FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiMediaFormat* LmiMediaFormatConstruct(LmiMediaFormat* x, LmiUint32 fourcc)

Parameters:

x The media format object.
fourcc The ???? byte-order FourCC value to initialize the media format from.

Returns:

The constructed object or NULL on error.

Note 1:

See also LmiMediaFormatConstructFromNative to construct media formats from FourCC codes in native byte order (as are typically used on Apple platforms).

Function: LmiMediaFormatConstructCopy

Member Of:

LmiMediaFormat

Description:

Construct a media format object from another media format instance.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiMediaFormat* LmiMediaFormatConstructCopy(LmiMediaFormat* x, const LmiMediaFormat* y)

Parameters:

x The media object.
y The media object to initialize from.

Returns:

The constructed object or NULL on error.

Function: LmiMediaFormatConstructFromCStr

Member Of:

LmiMediaFormat

Description:

Constructs a media format object from a C string representation of a FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiMediaFormat* LmiMediaFormatConstructFromCStr(LmiMediaFormat* x, const char* fourcc)

Parameters:

x The media format object.
fourcc A C string representation of the FourCC value to initialize the media format with.

Returns:

The constructed object or NULL on error.

Function: LmiMediaFormatConstructFromNative

Member Of:

LmiMediaFormat

Description:

Constructs a media format object and initializes it from a native-format FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiMediaFormat* LmiMediaFormatConstructFromNative(LmiMediaFormat* x, LmiUint32 fourcc)

Parameters:

x The media format object.
fourcc The native-format FourCC value to initialize the media format from.

Returns:

The constructed object or NULL on error.

Note 1:

The endiannesses of FourCC values are different on different little-endian platforms. On Apple platforms, they are typically forward in an unsigned 32-bit integer (reversed in memory), whereas on Windows and Linux they are reversed in a 32-bit integer (forward in memory). (Big-endian platforms, generally, are consistently forward both in memory and in the integer.)

Function: LmiMediaFormatDestruct

Member Of:

LmiMediaFormat

Description:

Destructs a media format object.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

void LmiMediaFormatDestruct(LmiMediaFormat* x)

Parameters:

x The media format object.

Function: LmiMediaFormatEqual

Member Of:

LmiMediaFormat

Description:

Compares two media format objects for equality.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiBool LmiMediaFormatEqual(const LmiMediaFormat* x, const LmiMediaFormat* y)

Parameters:

x The media format object.
y The other media format object.

Returns:

LMI_TRUE if the media format objects are equal and LMI_FALSE otherwise.

Function: LmiMediaFormatLess

Member Of:

LmiMediaFormat

Description:

Checks if the media format x is less than media format y

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiBool LmiMediaFormatLess(const LmiMediaFormat* x, const LmiMediaFormat* y)

Parameters:

x The media format object.
y The media format object to check with.

Returns:

LMI_TRUE if x is less than y and LMI_FALSE otherwise.

Function: LmiMediaFormatSwap

Member Of:

LmiMediaFormat

Description:

Swap the content of one media format object with another.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiBool LmiMediaFormatSwap(LmiMediaFormat* x, LmiMediaFormat* y)

Parameters:

x The media format object.
y The media format object to copy from.

Returns:

Returns LMI_TRUE on success or LMI_FALSE otherwise.

Function: LmiMediaFormatToCStr

Member Of:

LmiMediaFormat

Description:

Converts a media format object to a C string representation of a FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

char* LmiMediaFormatToCStr(const LmiMediaFormat* x, char buf[5])

Parameters:

x The media format object.
buf The buffer to hold the result.

Returns:

A pointer to the FourCC buffer.

Function: LmiMediaFormatToFourCC

Member Of:

LmiMediaFormat

Description:

Converts a media format object to a FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiUint32 LmiMediaFormatToFourCC(const LmiMediaFormat* x)

Parameters:

x The media format object.

Returns:

A FourCC value.

Note 1:

See also LmiMediaFormatToNativeFourCC.

Function: LmiMediaFormatToNativeFourCC

Member Of:

LmiMediaFormat

Description:

Converts a media format object to a native-format FourCC value.

Include:

Lmi/Utils/LmiMediaFormat.h

Library:

LmiUtils

Syntax:

LmiUint32 LmiMediaFormatToNativeFourCC(const LmiMediaFormat* x)

Parameters:

x The media format object.

Returns:

A native-format FourCC value.

Note 1:

The endiannesses of FourCC values are different on different little-endian platforms. On Apple platforms, they are typically forward in an unsigned 32-bit integer (reversed in memory), whereas on Windows and Linux they are reversed in a 32-bit integer (forward in memory). (Big-endian platforms, generally, are consistently forward both in memory and in the integer.)

Function: LmiMismatch

Member Of:

Algorithms

Description:

Find the first place where two sequences differ.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiMismatch(T, I1, I2)(I1 ai, I1 ae, I2 bi, I2 be, I1 *am, I2 *bm)

Template Parameters:

T The type of the elements in the sequences. The type must be a model of LmiEqualityComparable.
I1 The iterator type of the first sequence. The iterator type must be a model of LmiInputIterator.
I2 The iterator type of the second sequence. The iterator type must be a model of LmiInputIterator.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
am An iterator to the first unmatched element of the first sequence will be written into this variable. If set to ae (one past the last element of the first sequence) then the entire first sequence is contained in the second sequence.
bm An iterator to the first unmatched element of the second sequence will be written into this variable. If set to be (one past the last element of the second sequence) then the entire second sequence is contained in the first sequence.

Note 1:

The macro Define_LmiMismatch must be called at global scope before calling this function.

Function: LmiMismatchComp

Member Of:

Algorithms

Description:

Find the first place where two sequences differ.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiMismatchComp(I1, I2, Comp)(I1 ai, I1 ae, I2 bi, I2 be, I1 *am, I2 *bm)

Template Parameters:

I1 The iterator type of the first sequence. The iterator type must be a model of LmiInputIterator.
I2 The iterator type of the second sequence. The iterator type must be a model of LmiInputIterator.
Comp The comparison function for elements.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
am An iterator to the first unmatched element of the first sequence will be written into this variable. If set to ae (one past the last element of the first sequence) then the entire first sequence is contained in the second sequence.
bm An iterator to the first unmatched element of the second sequence will be written into this variable. If set to be (one past the last element of the second sequence) then the entire second sequence is contained in the first sequence.

Note 1:

The macro Define_LmiMismatchComp must be called at global scope before calling this function.

Function: LmiMotionProfileConstructBase

Member Of:

LmiMotionProfile

Description:

Constructs an LmiMotionProfile object. Use this function when creating an object of a class derived from LmiMotionProfile.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfile *LmiMotionProfileConstructBase(LmiMotionProfile *mp, LmiMotionProfilePlugIn *plugIn)

Parameters:

mp The LmiMotionProfile object to construct.
plugIn The motion profile plug-in. Typically each derived class will have its own plug-in object that is shared between all instances of the class.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiMotionProfileDestruct

Member Of:

LmiMotionProfile

Description:

Destructs an LmiMotionProfile object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

void LmiMotionProfileDestruct(LmiMotionProfile *mp)

Parameters:

mp The LmiMotionProfile object to destruct.

Function: LmiMotionProfileGetPosition

Member Of:

LmiMotionProfile

Description:

Gets the fraction of the total distance traveled as a function of the fraction of total time elapsed.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiMotionProfileGetPosition(LmiMotionProfile *mp, LmiFloat64 t)

Parameters:

mp The LmiMotionProfile object to construct.
t A value between 0 and 1 representing the fraction of the total time allotted for the move that has elapsed.

Returns:

A value between 0 and 1 representing the fraction of the total distance that has been traveled so far.

Function: LmiMotionProfilePlugInConstruct

Member Of:

LmiMotionProfilePlugIn

Description:

Constructs an LmiMotionProfilePlugIn object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

LmiMotionProfilePlugIn *LmiMotionProfilePlugInConstruct(LmiMotionProfilePlugIn *plugIn, LmiMotionProfilePlugInGetPositionCallback getPosition)

Parameters:

plugIn The LmiMotionProfilePlugIn object to construct.
getPosition See LmiMotionProfilePlugInGetPositionCallback.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiMotionProfilePlugInDestruct

Member Of:

LmiMotionProfilePlugIn

Description:

Destructs an LmiMotionProfilePlugIn object.

Include:

Lmi/Utils/LmiMotionProfile.h

Library:

LmiUtils

Syntax:

void LmiMotionProfilePlugInDestruct(LmiMotionProfilePlugIn *plugIn)

Parameters:

plugIn The LmiMotionProfilePlugIn object to destruct.

Function: LmiPairAssign

Member Of:

LmiPair

Description:

Assign the value of one pair to another pair.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairAssign(T1_, T2_)(LmiPair(T1_, T2_)* x, const LmiPair(T1_, T2_)* y)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to the pair to assign to.
y A pointer to the pair to assign from.

Returns:

A pointer to the assigned to object or NULL on failure.

Function: LmiPairConstruct

Member Of:

LmiPair

Description:

Constructs a pair.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairConstruct(T1_, T2_)(LmiPair(T1_, T2_)* x, const T1_* first, const T2_* second)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to the pair to construct.
first The value to initialize the first item of the pair to.
second The value to initialize the second item of the pair to.

Returns:

A pointer to the constructed object or NULL on failure.

Function: LmiPairConstructCopy

Member Of:

LmiPair

Description:

Constructs a pair, initializing it with the value of another pair.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairConstructCopy(T1_, T2_)(LmiPair(T1_, T2_)* x, const LmiPair(T1_, T2_)* y)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to the pair to construct.
y A pointer to the pair to use to initialize the constructed pair.

Returns:

A pointer to the constructed object or NULL on failure.

Function: LmiPairDestruct

Member Of:

LmiPair

Description:

Destructs a pair.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

void LmiPairDestruct(T1_, T2_)(LmiPair(T1_, T2_)* x)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to the pair to destruct.

Function: LmiPairEqual

Member Of:

LmiPair

Description:

Compare two pairs for equality.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairEqual(T1_, T2_)(const LmiPair(T1_, T2_)* x, const LmiPair(T1_, T2_)* y)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to one of the pairs to compare.
y A pointer to the other pair to compare.

Returns:

LMI_TRUE if the pairs are equal or LMI_FALSE if they are not.

Function: LmiPairLess

Member Of:

LmiPair

Description:

Compare whether one pair is lexicographically less than another.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairLess(T1_, T2_)(const LmiPair(T1_, T2_)* x, const LmiPair(T1_, T2_)* y)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to one of the pairs to compare.
y A pointer to the other pair to compare.

Returns:

LMI_TRUE if the first pair is less than the second pair or LMI_FALSE if it is not.

Function: LmiPairSwap

Member Of:

LmiPair

Description:

Swap the value of two pairs.

Include:

Lmi/Utils/LmiUtility.h

Library:

LmiUtils

Syntax:

LmiPair(T1_, T2_)* LmiPairSwap(T1_, T2_)(LmiPair(T1_, T2_)* x, LmiPair(T1_, T2_)* y)

Template Parameters:

T1_ The type of the first item of the pair.
T2_ The type of the second item of the pair.

Parameters:

x A pointer to one of the pairs to swap.
y A pointer to the other pair to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Function: LmiPartition

Member Of:

Algorithms

Description:

Partition a range of elements into two groups. The first group shall contain all the elements for which a supplied predicate returns true. The second group shall contain all the elements for which the predicate returns false. This is not a stable partition: the order of the elements in each group may change.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

BI_ LmiPartition(BI_, T_)(BI_ first, BI_ last, LmiPredicate(T_) predicate, void *data)

Template Parameters:

BI_ The iterator type of the container containing the items to be searched. The iterator type must be a model of LmiBidirectionalIterator.
T_ The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

first An iterator to the first item in the range.
last An iterator to one past the last item in the range.
predicate The predicate function. The function must be a model of LmiPredicate.
data A user data pointer that will be passed to each invocation of the predicate.

Returns:

An iterator marking the first element of the second group.

Note 1:

The macro Define_LmiPartition must be called at global scope before calling this function.

Function: LmiPropertyAssign

Member Of:

LmiProperty

Description:

Assignment operator.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiProperty* LmiPropertyAssign(LmiProperty* p, const LmiProperty* o)

Parameters:

p The LmiProperty object to be assigned to.
o The LmiProperty object to be assigned from.

Returns:

p if the assignment operation was successful; NULL otherwise.

Function: LmiPropertyConstruct

Member Of:

LmiProperty

Description:

Constructor with initial values.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiProperty* LmiPropertyConstruct(LmiProperty* p, const LmiString* name, const LmiString* value)

Parameters:

p The LmiProperty object to be constructed.
name The name of the property.
value The value of the property.

Returns:

p if the construct operation was successful; NULL otherwise.

Function: LmiPropertyConstructCStr

Member Of:

LmiProperty

Description:

Constructor with initial values (in CStr format).

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiProperty* LmiPropertyConstructCStr(LmiProperty* p, const char* name, const char* value, LmiAllocator* a)

Parameters:

p The LmiProperty object to be constructed.
name The name of the property.
value The value of the property.
a The allocator to be used.

Returns:

p if the construct operation was successful; NULL otherwise.

Function: LmiPropertyConstructCopy

Member Of:

LmiProperty

Description:

Copy constructor.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiProperty* LmiPropertyConstructCopy(LmiProperty* p, const LmiProperty* o)

Parameters:

p The LmiProperty object to be copy-constructed.
o The LmiProperty object to be constructed from.

Returns:

p if the construct operation was successful; NULL otherwise.

Function: LmiPropertyDestruct

Member Of:

LmiProperty

Description:

Destructor.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

void LmiPropertyDestruct(LmiProperty* p)

Parameters:

p The LmiProperty object to be destructed.

Function: LmiPropertyGetName

Member Of:

LmiProperty

Description:

To get the name of an LmiProperty object.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

const LmiString* LmiPropertyGetName(const LmiProperty* p)

Parameters:

p The LmiProperty object.

Returns:

The name of the object.

Function: LmiPropertyGetNameCStr

Member Of:

LmiProperty

Description:

To get the name of an LmiProperty object in CStr format.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

const char* LmiPropertyGetNameCStr(const LmiProperty* p)

Parameters:

p The LmiProperty object.

Returns:

The name of the object.

Function: LmiPropertyGetValue

Member Of:

LmiProperty

Description:

To get the value of an LmiProperty object.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

const LmiString* LmiPropertyGetValue(const LmiProperty* p)

Parameters:

p The LmiProperty object.

Returns:

The value of the object.

Function: LmiPropertyGetValueCStr

Member Of:

LmiProperty

Description:

To get the value of an LmiProperty object in CStr format.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

const char* LmiPropertyGetValueCStr(const LmiProperty* p)

Parameters:

p The LmiProperty object.

Returns:

The value of the object.

Function: LmiPropertyIsEqual

Member Of:

LmiProperty

Description:

To check whether the name of the LmiProperty object matches the given string.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiBool LmiPropertyIsEqual(const LmiProperty* p, const LmiString* name)

Parameters:

p The LmiProperty object.
name The name string to be matched against.

Returns:

LMI_TRUE if the name of the property matches with the given name; LMI_FALSE otherwise.

Function: LmiPropertyIsEqualCStr

Member Of:

LmiProperty

Description:

To check whether the name of the LmiProperty object matches the given string (in CStr format).

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiBool LmiPropertyIsEqualCStr(const LmiProperty* p, const char* name)

Parameters:

p The LmiProperty object.
name The name string to be matched against.

Returns:

LMI_TRUE if the name of the property matches with the given name; LMI_FALSE otherwise.

Function: LmiPropertySetValue

Member Of:

LmiProperty

Description:

To change the value of an LmiProperty object.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiBool LmiPropertySetValue(LmiProperty* p, const LmiString* value)

Parameters:

p The LmiProperty object.
value The new value.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiPropertySetValueCStr

Member Of:

LmiProperty

Description:

To change the value of an LmiProperty object.

Include:

Lmi/Utils/LmiProperty.h

Library:

LmiUtils

Syntax:

LmiBool LmiPropertySetValueCStr(LmiProperty* p, const char* value)

Parameters:

p The LmiProperty object.
value The new value.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiRandomAccessIteratorAdd

Member Of:

LmiRandomAccessIterator

Description:

Return an iterator to the element n elements from the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiRandomAccessIterator(T_) LmiRandomAccessIteratorAdd(T_)(LmiRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator from which the new iterator is based.
n The distance from iterator x the new iterator should point.

Returns:

A new iterator pointing to an element n elements from the iterator x.

Function: LmiRandomAccessIteratorAt

Member Of:

LmiRandomAccessIterator

Description:

Retrieve a pointer to an element of the iterator's value type at an offset from the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

T_* LmiRandomAccessIteratorAt(T_)(LmiRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The offset from the iterator to the element to retrieve.

Returns:

A pointer to the element retrieved.

Function: LmiRandomAccessIteratorDecrementN

Member Of:

LmiRandomAccessIterator

Description:

Decrement the iterator by n.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiRandomAccessIterator(T_)* LmiRandomAccessIteratorDecrementN(T_)(LmiRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The distance to decrement the iterator by.

Returns:

A pointer to the decremented iterator.

Function: LmiRandomAccessIteratorIncrementN

Member Of:

LmiRandomAccessIterator

Description:

Increment the iterator by n.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiRandomAccessIterator(T_)* LmiRandomAccessIteratorIncrementN(T_)(LmiRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The distance to increment the iterator by.

Returns:

A pointer to the incremented iterator.

Function: LmiRandomAccessIteratorLess

Member Of:

LmiRandomAccessIterator

Description:

Test whether one iterator is lexicographically less than another.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiRandomAccessIteratorLess(T_)(const LmiRandomAccessIterator(T_)* x, const LmiRandomAccessIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to compare.
y The other iterator to compare.

Returns:

LMI_TRUE if the first iterator is lexicographically less than the second iterator or LMI_FALSE if it is not.

Function: LmiRandomAccessIteratorSubtract

Member Of:

LmiRandomAccessIterator

Description:

Find the distance between two iterators.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiDifferenceType(T_) LmiRandomAccessIteratorSubtract(T_)(LmiRandomAccessIterator(T_)* x, LmiRandomAccessIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The minuend iterator.
y The subtrahend iterator.

Returns:

The distance in value type elements.

Function: LmiRectangleAssign

Member Of:

LmiRectangle

Description:

Assigns one LmiRectangle object the value of another.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleAssign(LmiRectangle* d, const LmiRectangle* s)

Parameters:

d The destination object.
s The source object.

Returns:

A pointer to the destination object on success, or NULL on failure.

Function: LmiRectangleClip

Member Of:

LmiRectangle

Description:

Reduce the size of a rectangle such that it does not intersect another rectangle. This may be useful for calculating the new shape of a window when it is desired to keep the whole window visible in the presence of another screen element. If there is more than one way to accomplish this, the resulting rectangle with the largest area is chosen. If there is no way to do this (because the rectangle r lies entirely within the other rectangle), then r is left unchanged.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleClip(LmiRectangle *r, const LmiRectangle *avoid)

Parameters:

r The rectangle to clip.
avoid The rectangle to clip to.

Function: LmiRectangleConstruct

Member Of:

LmiRectangle

Description:

Constructs a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstruct(LmiRectangle* r, LmiInt x, LmiInt y, LmiUint width, LmiUint height)

Parameters:

r The rectangle object to construct.
x The minimum x coordinate.
y The minimum y coordinate.
width The width.
height The height.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Note 1:

equivalent to LmiRectangleConstructMinAndSize

Function: LmiRectangleConstructCopy

Member Of:

LmiRectangle

Description:

Constructs an LmiRectangle object as a copy of another.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstructCopy(LmiRectangle* d, const LmiRectangle* s)

Parameters:

d The rectangle to construct.
s The rectangle to copy.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiRectangleConstructDefault

Member Of:

LmiRectangle

Description:

Constructs a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstructDefault(LmiRectangle* r)

Parameters:

r The rectangle object to construct.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiRectangleConstructMaxAndSize

Member Of:

LmiRectangle

Description:

Constructs a rectangle by specifying the maximum values for each coordinate, and also the rectangle's width and height.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstructMaxAndSize(LmiRectangle* r, LmiInt x, LmiInt y, LmiUint width, LmiUint height)

Parameters:

r The rectangle object to construct.
x The maximum x coordinate.
y The maximum y coordinate.
width The width.
height The height.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiRectangleConstructMinAndMax

Member Of:

LmiRectangle

Description:

Constructs a rectangle by specifying the minimum and maximum values for each coordinate.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstructMinAndMax(LmiRectangle* r, LmiInt xMin, LmiInt yMin, LmiInt xMax, LmiInt yMax)

Parameters:

r The rectangle object to construct.
xMin The minimum x coordinate.
yMin The minimum y coordinate.
xMax The maximum x coordinate.
yMax The maximum y coordinate.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiRectangleConstructMinAndSize

Member Of:

LmiRectangle

Description:

Constructs a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiRectangle* LmiRectangleConstructMinAndSize(LmiRectangle* r, LmiInt x, LmiInt y, LmiUint width, LmiUint height)

Parameters:

r The rectangle object to construct.
x The minimum x coordinate.
y The minimum y coordinate.
width The width.
height The height.

Returns:

A pointer to a constructed object on success, or NULL on failure.

Function: LmiRectangleContains

Member Of:

LmiRectangle

Description:

Determine if a point is located within a rectangle. Note that points lying on the rectangle's maximum x and y coordinates will be considered outside the rectangle. When the rectangle is used to represent a grid of pixels, this convention ensures that the proper number of pixels are determined to lie within the rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiBool LmiRectangleContains(const LmiRectangle *r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The x coordinate of the point.
y The y coordinate of the point.

Returns:

A boolean indicating if the point is within the rectangle.

Function: LmiRectangleDestruct

Member Of:

LmiRectangle

Description:

Destructs an LmiRectangle object.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleDestruct(LmiRectangle* r)

Parameters:

r The rectangle object.

Function: LmiRectangleEnclose

Member Of:

LmiRectangle

Description:

Finds the smallest rectangle that contains two specified rectangles.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleEnclose(const LmiRectangle *a, const LmiRectangle *b, LmiRectangle *r)

Parameters:

a The first rectangle.
b The second rectangle.
r The enclosing rectangle will be written into this object.

Function: LmiRectangleEqual

Member Of:

LmiRectangle

Description:

Checks whether two rectangles are equivalent, meaning they have the same size and location.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiBool LmiRectangleEqual(const LmiRectangle* a, const LmiRectangle* b)

Parameters:

a The first rectangle object.
b The second rectangle object.

Returns:

A boolean indicating whether the rectangles are equivalent.

Function: LmiRectangleGetArea

Member Of:

LmiRectangle

Description:

Gets the area of a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiUint LmiRectangleGetArea(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The area.

Function: LmiRectangleGetBottom

Member Of:

LmiRectangle

Description:

Gets the maximum y coordinate for a rectangle. When the rectangle represents a region in a coordinate system whose y values increase as you move downward, this value corresponds to the bottom edge of the rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetBottom(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The maximum y coordinate.

Note 1:

equivalent to LmiRectangleGetMaxY

Function: LmiRectangleGetHeight

Member Of:

LmiRectangle

Description:

Gets the height of a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiUint LmiRectangleGetHeight(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The height.

Function: LmiRectangleGetLeft

Member Of:

LmiRectangle

Description:

Gets the x coordinate of the left edge of a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetLeft(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The x coordinate of the left edge.

Note 1:

equivalent to LmiRectangleGetMinX

Function: LmiRectangleGetMaxX

Member Of:

LmiRectangle

Description:

Gets the maximum x coordinate for a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetMaxX(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The maximum x coordinate.

Function: LmiRectangleGetMaxY

Member Of:

LmiRectangle

Description:

Gets the maximum y coordinate for a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetMaxY(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The maximum y coordinate.

Function: LmiRectangleGetMinX

Member Of:

LmiRectangle

Description:

Gets the minimum x coordinate for a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetMinX(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The minimum x coordinate.

Function: LmiRectangleGetMinY

Member Of:

LmiRectangle

Description:

Gets the minimum y coordinate for a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetMinY(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The minimum y coordinate.

Function: LmiRectangleGetRight

Member Of:

LmiRectangle

Description:

Gets the x coordinate of the right edge of a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetRight(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The x coordinate of the right edge.

Note 1:

equivalent to LmiRectangleGetMaxX

Function: LmiRectangleGetTop

Member Of:

LmiRectangle

Description:

Gets the minimum y coordinate for a rectangle. When the rectangle represents a region in a coordinate system whose y values increase as you move downward, this value corresponds to the top edge of the rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiInt LmiRectangleGetTop(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The minimum y coordinate.

Note 1:

equivalent to LmiRectangleGetMinY

Function: LmiRectangleGetWidth

Member Of:

LmiRectangle

Description:

Gets the width of a rectangle.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiUint LmiRectangleGetWidth(const LmiRectangle* r)

Parameters:

r The rectangle object.

Returns:

The width.

Function: LmiRectangleIntersect

Member Of:

LmiRectangle

Description:

Finds the intersection between two rectangles.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleIntersect(const LmiRectangle *a, const LmiRectangle *b, LmiRectangle *r)

Parameters:

a The first rectangle.
b The second rectangle.
r The intersection between the first and second rectangles will be written into this rectangle. If there is no intersection, the width or height of this rectangle will be zero.

Function: LmiRectangleIntersects

Member Of:

LmiRectangle

Description:

Determines if two rectangles intersect. Rectangles are considered intersecting if they have nonzero common area. Two rectangles sharing boundaries only will not be considered intersecting.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

LmiBool LmiRectangleIntersects(const LmiRectangle *a, const LmiRectangle *b)

Parameters:

a The first rectangle.
b The second rectangle.

Returns:

A boolean indicating if the two rectangles intersect.

Function: LmiRectangleMoveTo

Member Of:

LmiRectangle

Description:

Moves a rectangle without changing its size. Specify the new minimum values for each coordinate.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleMoveTo(LmiRectangle *r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The minimum x coordinate.
y The minimum y coordinate.

Note 1:

equivalent to LmiRectangleMoveToMin

Function: LmiRectangleMoveToMax

Member Of:

LmiRectangle

Description:

Moves a rectangle without changing its size. Specify the new maximum values for each coordinate.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleMoveToMax(LmiRectangle* r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The maximum x coordinate.
y The maximum y coordinate.

Function: LmiRectangleMoveToMin

Member Of:

LmiRectangle

Description:

Moves a rectangle without changing its size. Specify the new minimum values for each coordinate.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleMoveToMin(LmiRectangle* r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The minimum x coordinate.
y The minimum y coordinate.

Function: LmiRectangleResizeFromMax

Member Of:

LmiRectangle

Description:

Resizes a rectangle, keeping the maximum values for each coordinate unchanged. The minimum values are adjusted as necessary.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleResizeFromMax(LmiRectangle* r, LmiUint width, LmiUint height)

Parameters:

r The rectangle object.
width The new width.
height The new height.

Function: LmiRectangleResizeFromMin

Member Of:

LmiRectangle

Description:

Resizes a rectangle, keeping the minimum values for each coordinate unchanged. The maximum values are adjusted as necessary.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleResizeFromMin(LmiRectangle* r, LmiUint width, LmiUint height)

Parameters:

r The rectangle object.
width The new width.
height The new height.

Function: LmiRectangleResizeToAspectRatio

Member Of:

LmiRectangle

Description:

Resizes a rectangle so that it has the specified aspect ratio. The center position of the rectangle is left unchanged.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleResizeToAspectRatio(LmiRectangle* r, LmiUint width, LmiUint height, LmiBool letterbox)

Parameters:

r The rectangle object.
width The desired width.
height The desired height.
letterbox Set to LMI_TRUE to resize using letterbox mode. This will resize the rectangle to the largest rectangle of the proper aspect ratio fitting completely within the original rectangle. Set to LMI_FALSE to resize using crop mode. This will resize the rectangle to the smallest rectangle of the proper aspect ratio completely covering the original rectangle.

Function: LmiRectangleScale

Member Of:

LmiRectangle

Description:

Scale a rectangle by a constant factor. Both its position and size are scaled by this amount.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleScale(LmiRectangle* r, LmiFloat32 scale)

Parameters:

r The rectangle object.
scale The amount to scale the rectangle.

Function: LmiRectangleSetBottom

Member Of:

LmiRectangle

Description:

Changes the maximum y coordinate. The minimum y coordinate is left unchanged. If a new value is provided, the height of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetBottom(LmiRectangle* r, LmiInt y)

Parameters:

r The rectangle object.
y The maximum y coordinate.

Function: LmiRectangleSetHeight

Member Of:

LmiRectangle

Description:

Changes the height of a rectangle, keeping the minimum y coordinate unchanged. The maximum y coordinate is adjusted as necessary.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetHeight(LmiRectangle* r, LmiUint height)

Parameters:

r The rectangle object.
height The new height.

Function: LmiRectangleSetLeft

Member Of:

LmiRectangle

Description:

Changes the minimum x coordinate. The maximum x coordinate is left unchanged. If a new value is provided, the width of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetLeft(LmiRectangle* r, LmiInt x)

Parameters:

r The rectangle object.
x The minimum x coordinate.

Function: LmiRectangleSetMax

Member Of:

LmiRectangle

Description:

Changes the maximum values for each coordinate. The minimum values are left unchanged. If new maximum values are provided, the size of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetMax(LmiRectangle* r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The maximum x coordinate.
y The maximum y coordinate.

Function: LmiRectangleSetMaxAndSize

Member Of:

LmiRectangle

Description:

Modifies a rectangle by specifying the maximum values for each coordinate, and also the rectangle's width and height.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetMaxAndSize(LmiRectangle* r, LmiInt x, LmiInt y, LmiUint width, LmiUint height)

Parameters:

r The rectangle object.
x The maximum x coordinate.
y The maximum y coordinate.
width The width.
height The height.

Function: LmiRectangleSetMin

Member Of:

LmiRectangle

Description:

Changes the minimum values for each coordinate. The maximum values are left unchanged. If new minimum values are provided, the size of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetMin(LmiRectangle* r, LmiInt x, LmiInt y)

Parameters:

r The rectangle object.
x The minimum x coordinate.
y The minimum y coordinate.

Function: LmiRectangleSetMinAndMax

Member Of:

LmiRectangle

Description:

Modifies a rectangle by specifying the minimum and maximum values for each coordinate.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetMinAndMax(LmiRectangle* r, LmiInt xMin, LmiInt yMin, LmiInt xMax, LmiInt yMax)

Parameters:

r The rectangle object.
xMin The minimum x coordinate.
yMin The minimum y coordinate.
xMax The maximum x coordinate.
yMax The maximum y coordinate.

Function: LmiRectangleSetMinAndSize

Member Of:

LmiRectangle

Description:

Modifies a rectangle by specifying the minimum values for each coordinate, and also the rectangle's width and height.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetMinAndSize(LmiRectangle* r, LmiInt x, LmiInt y, LmiUint width, LmiUint height)

Parameters:

r The rectangle object.
x The minimum x coordinate.
y The minimum y coordinate.
width The width.
height The height.

Function: LmiRectangleSetRight

Member Of:

LmiRectangle

Description:

Changes the maximum x coordinate. The minimum x coordinate is left unchanged. If a new value is provided, the width of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetRight(LmiRectangle* r, LmiInt x)

Parameters:

r The rectangle object.
x The maximum x coordinate.

Function: LmiRectangleSetTop

Member Of:

LmiRectangle

Description:

Changes the minimum y coordinate. The maximum y coordinate is left unchanged. If a new value is provided, the height of the rectangle will change.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetTop(LmiRectangle* r, LmiInt y)

Parameters:

r The rectangle object.
y The minimum y coordinate.

Function: LmiRectangleSetWidth

Member Of:

LmiRectangle

Description:

Changes the width of a rectangle, keeping the minimum x coordinate unchanged. The maximum x coordinate is adjusted as necessary.

Include:

Lmi/Utils/LmiRectangle.h

Library:

LmiUtils

Syntax:

void LmiRectangleSetWidth(LmiRectangle* r, LmiUint width)

Parameters:

r The rectangle object.
width The new width.

Function: LmiRemoveIf

Member Of:

Algorithms

Description:

Removes all the elements in a range matching a given condition. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

FI LmiRemoveIf(FI, T)(FI x, FI y, LmiPredicate(T) predicate, void *data)

Template Parameters:

FI The iterator type of the container containing the items to process. The iterator type must be a model of LmiForwardIterator.
T The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

x Points to the first item in the range to be processed.
y Points to one past the last item in the range to be processed.
predicate A function to be called once for each element in the range. If the function returns LMI_TRUE, the element will be removed.
data A pointer that will be passed to each invocation of the predicate function.

Returns:

An iterator pointing to the beginning of the invalidated part of the range.

Note 1:

The macro Define_LmiRemoveIf must be called at global scope before calling this function.

Example 1:

				
		Define_LmiRemoveIf(LmiVectorIterator(LmiUint), LmiUint)

		LmiBool IsEven(const LmiUint *x, void *data)
		{
			return (*x % 2) == 0;
		}

		void RemoveEven(LmiVector(LmiUint) *v)
		{
			LmiVectorIterator(LmiUint) end = LmiRemoveIf(LmiVectorIterator(LmiUint), LmiUint)(
				LmiVectorBegin(LmiUint)(v), LmiVectorEnd(LmiUint)(v), IsEven, NULL);
			LmiVectorEraseRange(LmiUint)(v, end, LmiVectorEnd(LmiUint)(v));
		}
	
			

Function: LmiResolutionAssign

Member Of:

LmiResolution

Description:

To assign an instance of LmiResolution to another instance

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiResolution* LmiResolutionAssign(LmiResolution* r, const LmiResolution* o)

Parameters:

r Pointer to the target instance.
o const Pointer to the source instance.

Returns:

A pointer to the assigned-to instance; NULL in case of error.

Function: LmiResolutionConstruct

Member Of:

LmiResolution

Description:

To construct an instance of an LmiResolution object.

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiResolution* LmiResolutionConstruct(LmiResolution* r, LmiUint width, LmiUint height, LmiAllocator* a)

Parameters:

r Pointer to a LmiResolution to be constructed.
width Width.
height Height.
a Allocator.

Returns:

Pointer to the constructed LmiResolution object.

Function: LmiResolutionConstructCopy

Member Of:

LmiResolution

Description:

Construct a LmiResolution object from another instance.

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiResolution* LmiResolutionConstructCopy(LmiResolution* r, const LmiResolution* o)

Parameters:

r The object to be constructed.
o The object to initialize from.

Returns:

Pointer to the newly created copy or NULL on error.

Function: LmiResolutionDestruct

Member Of:

LmiResolution

Description:

To destruct a LmiResolution.

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

void LmiResolutionDestruct(LmiResolution* r)

Parameters:

r Pointer to an object of type LmiResolution

Function: LmiResolutionGetHeight

Member Of:

LmiResolution

Description:

Get height from LmiResolution.

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiUint LmiResolutionGetHeight(const LmiResolution* r)

Parameters:

r Pointer to a LmiResolution object.

Returns:

Height.

Function: LmiResolutionGetWidth

Member Of:

LmiResolution

Description:

Get width from LmiResolution.

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiUint LmiResolutionGetWidth(const LmiResolution* r)

Parameters:

r Pointer to a LmiResolution object.

Returns:

Width.

Function: LmiResolutionSetHeight

Member Of:

LmiResolution

Description:

To modify height in a LmiResolution

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiBool LmiResolutionSetHeight(LmiResolution* r, LmiUint height)

Parameters:

r Pointer to a LmiResolution object.
height The new height to be set.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiResolutionSetWidth

Member Of:

LmiResolution

Description:

To modify width in a LmiResolution

Include:

Lmi/Utils/LmiResolution.h

Library:

LmiUtils

Syntax:

LmiBool LmiResolutionSetWidth(LmiResolution* r, LmiUint width)

Parameters:

r Pointer to a LmiResolution object.
width The new width to be set.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiReverse

Member Of:

Algorithms

Description:

Reverse a sequence of elements.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiReverse(I, T)(I first, I last)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiBidirectionalIterator.
T The type of the elements in the sequence.

Parameters:

first Points to the first item in the sequence.
last Points to one past the last item in the sequence.

Note 1:

The macro Define_LmiReverse must be called at global scope before calling this function.

Function: LmiReverseBidirectionalIteratorAssign

Member Of:

LmiReverseBidirectionalIterator

Description:

Copy one iterator to another.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseBidirectionalIterator(T_)* LmiReverseBidirectionalIteratorAssign(T_)(LmiReverseBidirectionalIterator(T_)* x, const LmiReverseBidirectionalIterator(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The iterator to assign to.
y The iterator to assign from.

Returns:

A pointer to the assigned to iterator or NULL on error.

Function: LmiReverseBidirectionalIteratorConstructCopy

Member Of:

LmiReverseBidirectionalIterator

Description:

Constructs an iterator from another iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseBidirectionalIterator(T_)* LmiReverseBidirectionalIteratorConstructCopy(T_)(LmiReverseBidirectionalIterator(T_)* x, const LmiReverseBidirectionalIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be constructed.
y The iterator to use to initialize the iterator being constructed.

Returns:

A pointer to the constructed iterator or NULL on error.

Function: LmiReverseBidirectionalIteratorConstructExceptional

Member Of:

LmiReverseBidirectionalIterator

Description:

Constructs an exception iterator. Exceptional iterators are used to indicate failure in cases where the normal return is an iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseBidirectionalIterator(T_)* LmiReverseBidirectionalIteratorConstructExceptional(T_)(LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be constructed.

Returns:

A pointer to the constructed iterator or NULL on error.

Function: LmiReverseBidirectionalIteratorContentOf

Member Of:

LmiReverseBidirectionalIterator

Description:

Gets the content of the object pointed to by the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

T_* LmiReverseBidirectionalIteratorContentOf(T_)(LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator whose content is requested.

Returns:

A pointer to the content of the iterator.

Function: LmiReverseBidirectionalIteratorContentOfConst

Member Of:

LmiReverseBidirectionalIterator

Description:

Gets the read-only content of the object pointed to by the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

const T_* LmiReverseBidirectionalIteratorContentOfConst(T_)(const LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator whose content is requested.

Returns:

A pointer to the read-only content of the iterator.

Function: LmiReverseBidirectionalIteratorDecrement

Member Of:

LmiReverseBidirectionalIterator

Description:

Decrements the iterator to point at the previous object in the reverse container. No checking is perform to ensure that the iterator is in range of the container after the operation.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseBidirectionalIterator(T_)* LmiReverseBidirectionalIteratorDecrement(T_)(LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be incremented.

Returns:

A pointer to the iterator after it has been decremented.

Function: LmiReverseBidirectionalIteratorDestruct

Member Of:

LmiReverseBidirectionalIterator

Description:

Destructs an iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

void LmiReverseBidirectionalIteratorDestruct(T_)(LmiBaseIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be destructed.

Function: LmiReverseBidirectionalIteratorEqual

Member Of:

LmiReverseBidirectionalIterator

Description:

Compares two iterators for equality.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiReverseBidirectionalIteratorEqual(T_)(const LmiReverseBidirectionalIterator(T_)* x, const LmiReverseBidirectionalIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to compare.
y The other iterator to compare.

Returns:

LMI_TRUE if the iterators are equal or LMI_FALSE if they are not.

Function: LmiReverseBidirectionalIteratorIncrement

Member Of:

LmiReverseBidirectionalIterator

Description:

Increments the iterator to point at the next object in the reverse container. No checking is perform to ensure that the iterator is in range of the container after the operation.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseBidirectionalIterator(T_)* LmiReverseBidirectionalIteratorIncrement(T_)(LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be incremented.

Returns:

A pointer to the iterator after it has been incremented.

Function: LmiReverseBidirectionalIteratorIsExceptional

Member Of:

LmiReverseBidirectionalIterator

Description:

Determines whether or not the iterator has encountered an exception.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiReverseBidirectionalIteratorIsExceptional(T_)(const LmiReverseBidirectionalIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.

Returns:

LMI_TRUE if an exception has occurred on the iterator and LMI_FALSE if no exception has occurred.

Function: LmiReverseBidirectionalIteratorSwap

Member Of:

LmiReverseBidirectionalIterator

Description:

Swap two iterators.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiReverseBidirectionalIteratorSwap(T_)(LmiReverseBidirectionalIterator(T_)* x, LmiReverseBidirectionalIterator(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The iterator to swap.
y The other iterator to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Function: LmiReverseRandomAccessIteratorAdd

Member Of:

LmiReverseRandomAccessIterator

Description:

Return an iterator to the element n elements from the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseRandomAccessIterator(T_) LmiReverseRandomAccessIteratorAdd(T_)(LmiReverseRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator from which the new iterator is based.
n The distance from iterator x the new iterator should point.

Returns:

A new iterator pointing to an element n elements from the iterator x.

Function: LmiReverseRandomAccessIteratorAt

Member Of:

LmiReverseRandomAccessIterator

Description:

Retrieve a pointer to an element of the iterator's value type at an offset from the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

T_* LmiReverseRandomAccessIteratorAt(T_)(LmiReverseRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The offset from the iterator to the element to retrieve.

Returns:

A pointer to the element retrieved.

Function: LmiReverseRandomAccessIteratorDecrementN

Member Of:

LmiReverseRandomAccessIterator

Description:

Decrement the iterator by n.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseRandomAccessIterator(T_)* LmiReverseRandomAccessIteratorDecrementN(T_)(LmiReverseRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The distance to decrement the iterator by.

Returns:

A pointer to the decremented iterator.

Function: LmiReverseRandomAccessIteratorIncrementN

Member Of:

LmiReverseRandomAccessIterator

Description:

Increment the iterator by n.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiReverseRandomAccessIterator(T_)* LmiReverseRandomAccessIteratorIncrementN(T_)(LmiReverseRandomAccessIterator(T_)* x, LmiSizeType(T_) n)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.
n The distance to increment the iterator by.

Returns:

A pointer to the incremented iterator.

Function: LmiReverseRandomAccessIteratorLess

Member Of:

LmiReverseRandomAccessIterator

Description:

Test whether one iterator is lexicographically less than another.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiReverseRandomAccessIteratorLess(T_)(const LmiReverseRandomAccessIterator(T_)* x, const LmiReverseRandomAccessIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to compare.
y The other iterator to compare.

Returns:

LMI_TRUE if the first iterator is lexicographically less than the second iterator or LMI_FALSE if it is not.

Function: LmiReverseRandomAccessIteratorSubtract

Member Of:

LmiReverseRandomAccessIterator

Description:

Find the distance between two iterators.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiDifferenceType(T_) LmiReverseRandomAccessIteratorSubtract(T_)(LmiReverseRandomAccessIterator(T_)* x, LmiReverseRandomAccessIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The minuend iterator.
y The subtrahend iterator.

Returns:

The distance in value type elements.

Function: LmiSetIntersection

Member Of:

Algorithms

Description:

Creates the intersection of two sorted sequences. Each element of the first sequence that has a corresponding equivalent element in the second sequence will appear in the output sequence. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then the first min(m,n) elements from the first sequence are written to the output.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetIntersection(I, C, T)(I ai, I ae, I bi, I be, C *out)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
T The type of the elements contained in the sequences.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
out Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetIntersection must be called at global scope before calling this function.

Example 1:

				
		Define_LmiSetIntersection(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)

		void f(void)
		{
			LmiVector(LmiUint) a, b, c;

			const LmiUint ae[] = {1, 2, 2, 2, 2, 6, 8, 8};
			const LmiUint be[] = {1, 2, 2, 3, 4, 6, 6, 8};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&c, LmiMallocAllocatorGetDefault());

			LmiSetIntersection(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b), &c);

			/* leaves c with {1, 2, 2, 6, 8} */

			LmiVectorDestruct(LmiUint)(&c);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSetIntersectionComp

Member Of:

Algorithms

Description:

Creates the intersection of two sorted sequences. Each element of the first sequence that has a corresponding equivalent element in the second sequence will appear in the output sequence. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then the first min(m,n) elements from the first sequence are written to the output.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetIntersectionComp(I, C, Comp)(I ai, I ae, I bi, I be, C *out)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
Comp The comparison function for elements.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
out Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetIntersectionComp must be called at global scope before calling this function.

Example 1:

				
		LmiBool LastDigitLess(const LmiUint *a, const LmiUint *b)
		{
			return (*a % 10) < (*b % 10);
		}

		Define_LmiSetIntersectionComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)

		void f(void)
		{
			LmiVector(LmiUint) a, b, c;

			const LmiUint ae[] = {1, 2, 2, 12, 12, 6, 8, 18};
			const LmiUint be[] = {11, 12, 12, 13, 14, 16, 16, 18};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&c, LmiMallocAllocatorGetDefault());

			LmiSetIntersectionComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b), &c);

			/* leaves c with {1, 2, 2, 6, 8} */

			LmiVectorDestruct(LmiUint)(&c);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSetIntersectionWithDifferences

Member Of:

Algorithms

Description:

Calculates simultaneously the set intersection and set differences of two sorted sequences. If all output containers are specified, then each input element will be copied to exactly one of the containers.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetIntersectionWithDifferences(I, C, T)(I ai, I ae, I bi, I be, C *aBoth, C *bBoth, C *aOnly, C *bOnly)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
T The type of the elements contained in the sequences.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
aBoth Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container. This is the same sequence that would be generated by LmiSetIntersection.
bBoth Elements from the second sequence that have a matching element in the first sequence will be added to the end of this container. Can be NULL if this set of elements is not desired.
aOnly Elements from the first sequence that do not have a matching element in the second sequence will be added to the end of this container.
bOnly Elements from the second sequence that do not have a matching element in the first sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetIntersectionWithDifferences must be called at global scope before calling this function.

Example 1:

				
		Define_LmiSetIntersectionWithDifferences(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)

		void f(void)
		{
			LmiVector(LmiUint) a, b, both, aOnly, bOnly;

			const LmiUint ae[] = {1, 2, 2, 2, 2, 6, 8, 8};
			const LmiUint be[] = {1, 2, 2, 3, 4, 6, 6, 8};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&both,  LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&aOnly, LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&bOnly, LmiMallocAllocatorGetDefault());

			LmiSetIntersectionWithDifferences(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b),
				&both, NULL, &aOnly, &bOnly);

			/* leaves both  with {1, 2, 2, 6, 8} */
			/* leaves aOnly with {2, 2, 8} */
			/* leaves bOnly with {3, 4, 6} */

			LmiVectorDestruct(LmiUint)(&bOnly);
			LmiVectorDestruct(LmiUint)(&aOnly);
			LmiVectorDestruct(LmiUint)(&both);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSetIntersectionWithDifferencesComp

Member Of:

Algorithms

Description:

Calculates simultaneously the set intersection and set differences of two sorted sequences. If all output containers are specified, then each input element will be copied to exactly one of the containers.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetIntersectionWithDifferencesComp(I, C, Comp)(I ai, I ae, I bi, I be, C *aBoth, C *bBoth, C *aOnly, C *bOnly)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
Comp The comparison function for elements.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
aBoth Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container. This is the same sequence that would be generated by LmiSetIntersectionComp.
bBoth Elements from the second sequence that have a matching element in the first sequence will be added to the end of this container. Can be NULL if this set of elements is not desired.
aOnly Elements from the first sequence that do not have a matching element in the second sequence will be added to the end of this container.
bOnly Elements from the second sequence that do not have a matching element in the first sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetIntersectionWithDifferencesComp must be called at global scope before calling this function.

Example 1:

				
		LmiBool LastDigitLess(const LmiUint *a, const LmiUint *b)
		{
			return (*a % 10) < (*b % 10);
		}

		Define_LmiSetIntersectionWithDifferencesComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)

		void f(void)
		{
			LmiVector(LmiUint) a, b, aBoth, bBoth, aOnly, bOnly;

			const LmiUint ae[] = {1, 2, 2, 12, 12, 6, 8, 18};
			const LmiUint be[] = {11, 12, 12, 13, 14, 16, 16, 18};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&aBoth, LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&bBoth, LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&aOnly, LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&bOnly, LmiMallocAllocatorGetDefault());

			LmiSetIntersectionWithDifferencesComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b),
				&aBoth, &bBoth, &aOnly, &bOnly);

			/* leaves aBoth with {1, 2, 2, 6, 8} */
			/* leaves bBoth with {11, 12, 12, 16, 18} */
			/* leaves aOnly with {12, 12, 18} */
			/* leaves bOnly with {13, 14, 16} */

			LmiVectorDestruct(LmiUint)(&bOnly);
			LmiVectorDestruct(LmiUint)(&aOnly);
			LmiVectorDestruct(LmiUint)(&bBoth);
			LmiVectorDestruct(LmiUint)(&aBoth);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSetUnion

Member Of:

Algorithms

Description:

Creates the union of two sorted sequences. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then max(m,n) elements are written to the output. All m elements of the first sequence are written, and then if n>m the elements indexed m+1 through n of the second sequence are written.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetUnion(I, C, T)(I ai, I ae, I bi, I be, C *out)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
T The type of the elements contained in the sequences.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
out Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetUnion must be called at global scope before calling this function.

Example 1:

				
		Define_LmiSetUnion(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)

		void f(void)
		{
			LmiVector(LmiUint) a, b, c;

			const LmiUint ae[] = {1, 2, 2, 2, 2, 6, 8, 8};
			const LmiUint be[] = {1, 2, 2, 3, 4, 6, 6, 8};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&c, LmiMallocAllocatorGetDefault());

			LmiSetUnion(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LmiUint)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b), &c);

			/* leaves c with {1, 2, 2, 2, 2, 3, 4, 6, 6, 8, 8} */

			LmiVectorDestruct(LmiUint)(&c);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSetUnionComp

Member Of:

Algorithms

Description:

Creates the union of two sorted sequences. Within each equivalence class, if there are m elements in the first sequence and n elements in the second sequence, then max(m,n) elements are written to the output. All m elements of the first sequence are written, and then if n>m the elements indexed m+1 through n of the second sequence are written.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSetUnionComp(I, C, Comp)(I ai, I ae, I bi, I be, C *out)

Template Parameters:

I The iterator type of the input sequences. The iterator type must be a model of LmiInputIterator.
C The type of the output container. The type must be a model of LmiBackInsertionSequence.
Comp The comparison function for elements.

Parameters:

ai Points to the first item in the first sequence.
ae Points to one past the last item in the first sequence.
bi Points to the first item in the second sequence.
be Points to one past the last item in the second sequence.
out Elements from the first sequence that have a matching element in the second sequence will be added to the end of this container.

Note 1:

The macro Define_LmiSetUnionComp must be called at global scope before calling this function.

Example 1:

				
		LmiBool LastDigitLess(const LmiUint *a, const LmiUint *b)
		{
			return (*a % 10) < (*b % 10);
		}

		Define_LmiSetUnionComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)

		void f(void)
		{
			LmiVector(LmiUint) a, b, c;

			const LmiUint ae[] = {1, 2, 2, 12, 12, 6, 8, 18};
			const LmiUint be[] = {11, 12, 12, 13, 14, 16, 16, 18};

			LmiVectorConstructRange(LmiUint)(&a, ae, ae + LmiNumElements(ae), LmiMallocAllocatorGetDefault());
			LmiVectorConstructRange(LmiUint)(&b, be, be + LmiNumElements(be), LmiMallocAllocatorGetDefault());
			LmiVectorConstructDefault(LmiUint)(&c, LmiMallocAllocatorGetDefault());

			LmiSetUnionComp(LmiVectorConstIterator(LmiUint), LmiVector(LmiUint), LastDigitLess)(
				LmiVectorBeginConst(LmiUint)(&a), LmiVectorEndConst(LmiUint)(&a),
				LmiVectorBeginConst(LmiUint)(&b), LmiVectorEndConst(LmiUint)(&b), &c);

			/* leaves c with {1, 2, 2, 12, 12, 13, 14, 6, 16, 8, 18} */

			LmiVectorDestruct(LmiUint)(&c);
			LmiVectorDestruct(LmiUint)(&b);
			LmiVectorDestruct(LmiUint)(&a);
		}
	
			

Function: LmiSizeTAssign

Member Of:

LmiSizeT

Description:

Assign the value of one LmiSizeT object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiSizeT* LmiSizeTAssign(LmiSizeT* dst, const LmiSizeT* src)

Parameters:

dst A pointer to the LmiSizeT object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiSizeT object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiSizeT assignment will not fail.

Function: LmiSizeTConstruct

Member Of:

LmiSizeT

Description:

Construct a default instance of an LmiSizeT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiSizeT* LmiSizeTConstruct(LmiSizeT* obj)

Parameters:

obj A pointer to the LmiSizeT object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiSizeT object is initialized with the value 0. LmiSizeT construction will not fail.

Function: LmiSizeTConstructCopy

Member Of:

LmiSizeT

Description:

Construct a new LmiSizeT object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiSizeT* LmiSizeTConstructCopy(LmiSizeT* dst, const LmiSizeT* src)

Parameters:

dst A pointer to the LmiSizeT object to initialize as a copy.
src An existing LmiSizeT object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiSizeT construction will not fail.

Function: LmiSizeTDestruct

Member Of:

LmiSizeT

Description:

Destruct an LmiSizeT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiSizeTDestruct(LmiSizeT* obj)

Parameters:

obj A pointer to the LmiSizeT object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiSizeTEqual

Member Of:

LmiSizeT

Description:

Compare the values of two LmiSizeT objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiSizeTEqual(const LmiSizeT* a, const LmiSizeT* b)

Parameters:

a A pointer to the first LmiSizeT object to be compared.
b A pointer to the second LmiSizeT object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiSizeTLess

Member Of:

LmiSizeT

Description:

Compare the values of two LmiSizeT objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiSizeTLess(const LmiSizeT* a, const LmiSizeT* b)

Parameters:

a A pointer to the first LmiSizeT object to be compared.
b A pointer to the second LmiSizeT object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiSizeTSwap

Member Of:

LmiSizeT

Description:

Swap the contents of two LmiSizeT objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiSizeTSwap(LmiSizeT* a, LmiSizeT* b)

Parameters:

a A pointer to the first LmiSizeT object to be swapped.
b A pointer to the second LmiSizeT object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiSizeT swapping will not fail.

Function: LmiSort

Member Of:

Algorithms

Description:

Sort a range of items of a container.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSort(Ran_, T_)(Ran_ x_, Ran_ y_)

Template Parameters:

Ran_ The iterator type of the container containing the items to sort. The iterator type must be a model of LmiRandomAccessIterator.
T_ The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

x_ An iterator to the first item in the set to sort.
y_ an iterator to one-past-the-end of the last item in the set to sort.

Note 1:

The macro Define_LmiSort must be called at global scope before calling this function.

Example 1:

				
		Define_LmiSort(LmiVectorIterator(LmiInt), LmiInt)
		void sort_vector(LmiVector(LmiInt)* v) {
			LmiSort(LmiVectorIterator(LmiInt), LmiInt)(LmiVectorBegin(LmiInt)(v), LmiVectorEnd(LmiInt)(v));
		}
	
			

Function: LmiSortComp

Member Of:

Algorithms

Description:

Sort a range of items of a container using a comparison function.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

void LmiSortComp(Ran_, T_, Comp_)(Ran_ x_, Ran_ y_)

Template Parameters:

Ran_ The iterator type of the container containing the items to sort. The iterator type must be a model of LmiRandomAccessIterator.
T_ The type stored in the container. The type must be a model of LmiAssignable.
Comp_ The comparison function. The comparison function must be a model of LmiLessThanComparable.

Parameters:

x_ An iterator to the first item in the container to sort.
y_ an iterator to one past of the last item in the container to sort.

Note 1:

The macro Define_LmiSortComp must be called at global scope before calling this function.

Example 1:

				
		LmiBool less(const LmiInt* a, const LmiInt* b) { return a < b; }
		Define_LmiSortComp(LmiVectorIterator(LmiInt), LmiInt, less)
		void sortcomp_vector(LmiVector(LmiInt)* v) {
			LmiSortComp(LmiVectorIterator(LmiInt), LmiInt, less)(LmiVectorBegin(LmiInt)(v), LmiVectorEnd(LmiInt)(v));
		}
	
			

Function: LmiStringAppend

Member Of:

LmiString

Description:

Append the contents of one LmiString to another.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppend(LmiString* x, const LmiString* str)

Parameters:

x The string to append to.
str The string to be appended.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendCStr

Member Of:

LmiString

Description:

Append a NUL-terminated C string to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendCStr(LmiString* x, const char* str)

Parameters:

x The string to which to append str .
str The NUL-terminated C string to append.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendCStrLen

Member Of:

LmiString

Description:

Append a C string of a given length to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendCStrLen(LmiString* x, const char* str, LmiSizeT n)

Parameters:

x The string to which to append str .
str The C string to append.
n The length of str .

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendChar

Member Of:

LmiString

Description:

Append a single character to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendChar(LmiString* x, char c)

Parameters:

x The string to append to.
c The character to be appended.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendFormatted

Member Of:

LmiString

Description:

Append a printf-style formatted string to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendFormatted(LmiString* x, const char* fmt, ...)

Parameters:

x The string to which to append a formatted string.
fmt The printf-style format for the appended string.
... The arguments to fmt .

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendN

Member Of:

LmiString

Description:

Append multiple copies of a character to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendN(LmiString* x, LmiSizeT n, char c)

Parameters:

x The string to which to append n copies of c .
n The number of copies of c to append.
c The character to append.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendRange

Member Of:

LmiString

Description:

Append a range of characters to a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendRange(LmiString* x, LmiStringConstIterator first, LmiStringConstIterator last)

Parameters:

x The string to which to append the range.
first The beginning of the range to insert.
last The (non-inclusive) end of the range to insert. [first,last) must be a valid range.

Returns:

NULL on allocation failure, else x.

Note 1:

It is valid for the appended range to come from x .

Function: LmiStringAppendSubstring

Member Of:

LmiString

Description:

Append a substring of one LmiString to another.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendSubstring(LmiString* x, const LmiString* str, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string to append to.
str The string of which a substring is to be appended.
pos The offset within str of the beginning of the substring. Must be <= LmiStringLength(str).
n The length of the substring to be appended. If n is larger than LmiStringLength(str) - pos, the entire string following pos will be inserted. (In particular, LMI_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiStringAppendUcs4

Member Of:

LmiString

Description:

Append the UTF8-encoded values of a UCS4-encoded wide C string to a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendUcs4(LmiString* x, const LmiWideChar* ucs4)

Parameters:

x The string to which to append the wide C string.
ucs4 A NUL-terminated UCS-4 encoded wide C string.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringAppendUtf16

Member Of:

LmiString

Description:

Append the UTF8-encoded values of a UTF16-encoded C string to a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendUtf16(LmiString* x, const LmiUint16* utf16)

Parameters:

x The string to which to append the UTF-8 encoding of the UTF-16 string.
utf16 A NUL-terminated UTF-16 encoded wide C string.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringAppendVFormatted

Member Of:

LmiString

Description:

Append a vprintf-style formatted string to an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAppendVFormatted(LmiString* x, const char* fmt, va_list args)

Parameters:

x The string to which to append a formatted string.
fmt The printf-style format for the appended string.
args The arguments to fmt , as constructed by the functions of <stdarg.h>.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringAssign

Member Of:

LmiString

Description:

Assign the value of one LmiString to another. The previous data stored in the destination is overwritten.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssign(LmiString* x, const LmiString* y)

Parameters:

x A pointer to the string object to construct.
y A pointer to the string object to copy.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringAssignCStr

Member Of:

LmiString

Description:

Assign a NUL-terminated C string as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignCStr(LmiString* x, const char* str)

Parameters:

x The string to which to assign str .
str The NUL-terminated C string to assign.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAssignCStrLen

Member Of:

LmiString

Description:

Assign a C string of a given length as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignCStrLen(LmiString* x, const char* str, LmiSizeT n)

Parameters:

x The string to which to assign str .
str The C string to assign.
n The length of str .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringAssignChar

Member Of:

LmiString

Description:

Assign a single character as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignChar(LmiString* x, char c)

Parameters:

x The string to assign to.
c The character to be assigned.

Returns:

NULL on allocation failure, else x.

Function: LmiStringAssignFormatted

Member Of:

LmiString

Description:

Assign a printf-style formatted string as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignFormatted(LmiString* x, const char* fmt, ...)

Parameters:

x The string to which to assign a formatted string.
fmt The printf-style format for the assigned string.
... The arguments to fmt .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringAssignRange

Member Of:

LmiString

Description:

Assign a range of characters as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignRange(LmiString* x, LmiStringConstIterator first, LmiStringConstIterator last)

Parameters:

x The string to which to assign the range.
first The beginning of the range to assign.
last The (non-inclusive) end of the range to assign. [first,last) must be a valid range.

Returns:

NULL on allocation failure, else x.

Note 1:

It is valid for the replacement range to come from x .

Function: LmiStringAssignSubstring

Member Of:

LmiString

Description:

Assign a substring of one LmiString as the new value of another.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignSubstring(LmiString* x, const LmiString* str, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string to assign to.
str The string of which a substring is to be assigned.
pos The offset within str of the beginning of the substring. Must be <= LmiStringLength(str).
n The length of the substring to be assigned. If n is larger than LmiStringLength(str) - pos, the entire string following pos will be inserted. (In particular, LMI_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiStringAssignUcs4

Member Of:

LmiString

Description:

Assign a string to have the UTF8-encoded values of a UCS4-encoded wide C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignUcs4(LmiString* x, const LmiWideChar* ucs4)

Parameters:

x The string to which to assign the UTF-8 encoding of the wide C string.
ucs4 A NUL-terminated UCS-4 encoded wide C string.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringAssignUtf16

Member Of:

LmiString

Description:

Assign a string to have the UTF8-encoded values of a UTF16-encoded C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignUtf16(LmiString* x, const LmiUint16* utf16)

Parameters:

x The string to which to assign the UTF-8 encoding of the UTF-16 string.
utf16 A NUL-terminated UTF-16 encoded wide C string.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringAssignVFormatted

Member Of:

LmiString

Description:

Assign a vprintf-style formatted string as the new value of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringAssignVFormatted(LmiString* x, const char* fmt, va_list args)

Parameters:

x The string to which to assign a formatted string.
fmt The printf-style format for the assigned string.
args The arguments to fmt , as constructed by the functions of <stdarg.h>.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringAt

Member Of:

LmiString

Description:

Get a pointer to the character stored at a specific position in a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

char* LmiStringAt(LmiString* x, LmiSizeT n)

Parameters:

x The string from which the character should be extracted.
n The position of the character to be extracted.

Returns:

A pointer to the character to be extracted. This pointer is invalidated if a non-const member function, other than LmiStringAt, is invoked on x. It is not valid to write to this pointer.

Function: LmiStringAtConst

Member Of:

LmiString

Description:

Get a constant pointer to the character stored at a specific position in a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

const char* LmiStringAtConst(const LmiString* x, LmiSizeT n)

Parameters:

x The string from which the character should be extracted.
n The position of the character to be extracted.

Returns:

A pointer to the character to be extracted. This pointer is invalidated if a non-const member function, other than LmiStringAt, is invoked on x.

Function: LmiStringBack

Member Of:

LmiString

Description:

Return a pointer to the last character in a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

char* LmiStringBack(LmiString* x)

Parameters:

x The string whose last character to obtain.

Returns:

A pointer to the last character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiStringBackConst

Member Of:

LmiString

Description:

Return a pointer to the last character in a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

const char* LmiStringBackConst(const LmiString* x)

Parameters:

x The string whose last character to obtain.

Returns:

A pointer to the last character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiStringBegin

Member Of:

LmiString

Description:

Get an iterator referring to the beginning of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringIterator LmiStringBegin(LmiString* x)

Parameters:

x The string whose begin iterator to obtain.

Returns:

An iterator referring to the beginning of the string.

Function: LmiStringBeginConst

Member Of:

LmiString

Description:

Get an iterator referring to the beginning of a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringConstIterator LmiStringBeginConst(const LmiString* x)

Parameters:

x The string whose const begin iterator to obtain.

Returns:

A constant iterator referring to the beginning of the string.

Function: LmiStringCStr

Member Of:

LmiString

Description:

Get a NUL-terminated C string corresponding to the contents of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

const char* LmiStringCStr(const LmiString* x)

Parameters:

x The string whose C string to obtain.

Returns:

A read-only array of LmiStringSize(x) characters followed by a NUL character.

Note 1:

The pointer to the C string may be invalidated by any non-const member function of LmiString, other than LmiStringAt.

Function: LmiStringCapacity

Member Of:

LmiString

Description:

Get the size of the allocated storage of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringCapacity(const LmiString* x)

Parameters:

x A pointer to the string object whose capacity is to be determined.

Returns:

The capacity of the string, in characters.

Function: LmiStringClear

Member Of:

LmiString

Description:

Erase the contents of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

void LmiStringClear(LmiString* x)

Parameters:

x The string to clear.

Note 1:

Does not necessarily alter the string's capacity.

Function: LmiStringCompare

Member Of:

LmiString

Description:

Compare the values of two LmiStrings for ordering.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiInt LmiStringCompare(const LmiString* x, const LmiString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringCompareCStr

Member Of:

LmiString

Description:

Compare the value of an LmiString with that of a C string for ordering.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiInt LmiStringCompareCStr(const LmiString* x, const char* y)

Parameters:

x A pointer to the LmiString object to compare.
y A pointer to the C string to compare.

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringCompareCStrLen

Member Of:

LmiString

Description:

Compare the value of an LmiString with that of a C string of a given length for ordering.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiInt LmiStringCompareCStrLen(const LmiString* x, const char* y, LmiSizeT ylen)

Parameters:

x A pointer to the LmiString object to compare.
y A pointer to an array of char. The contents of x will be compared to the first ylen bytes of y. The array may include NUL.
ylen The length of the array pointed to by y .

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringConstructCStr

Member Of:

LmiString

Description:

Construct an LmiString based on a NUL-terminated C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructCStr(LmiString* x, const char* str, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str A NUL-terminated C string. The initial contents of x will be equal to the value of str up to its terminating NUL.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructCStrLen

Member Of:

LmiString

Description:

Construct an LmiString based on a C string of a given length.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructCStrLen(LmiString* x, const char* str, LmiSizeT len, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str A pointer to an array of char. The initial contents of x will be equal to the first len bytes of str. The array may include NUL bytes.
len The number of characters to include from str .
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructCopy

Member Of:

LmiString

Description:

Construct a copy of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructCopy(LmiString* x, const LmiString* y)

Parameters:

x A pointer to the string object to construct.
y A pointer to the string object to copy.

Returns:

A pointer to the string object, or NULL on failure.

Note 1:

The newly-constructed string uses the same allocator as the source string did.

Function: LmiStringConstructDefault

Member Of:

LmiString

Description:

Construct an empty LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructDefault(LmiString* x, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructFormatted

Member Of:

LmiString

Description:

Construct an LmiString based on a printf-style formatted string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructFormatted(LmiString* x, LmiAllocator* a, const char* fmt, ...)

Parameters:

x A pointer to the string object to construct.
a The allocator the string should use.
fmt The printf-style format for the constructed string's contents.
... The arguments to fmt .

Returns:

A pointer to the string object, or NULL on failure.

Note 1:

Notice that unlike other LmiString constructors, this constructor's LmiAllocator argument is not its final argument, because variadic arguments must come at the end.

Function: LmiStringConstructRange

Member Of:

LmiString

Description:

Construct an LmiString based on a range of another LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructRange(LmiString* x, LmiStringConstIterator first, LmiStringConstIterator last, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
first The beginning of the source range.
last The end of the source range.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructSubstring

Member Of:

LmiString

Description:

Construct an LmiString based on a substring of another LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructSubstring(LmiString* x, const LmiString* str, LmiSizeT pos, LmiSizeT n, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str The source LmiString object.
pos The initial position of the substring within the source string.
n The length of the substring within the source string. The value LMI_STRING_NPOS indicates the entire string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructUcs4

Member Of:

LmiString

Description:

Construct a string to have the UTF8-encoded values of a UCS4-encoded wide C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructUcs4(LmiString* x, const LmiWideChar* ucs4, LmiAllocator* a)

Parameters:

x A pointer to the string to construct.
ucs4 A NUL-terminated UCS-4 encoded wide C string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructUtf16

Member Of:

LmiString

Description:

Construct a string to have the UTF8-encoded values of a UTF16-encoded C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructUtf16(LmiString* x, const LmiUint16* utf16, LmiAllocator* a)

Parameters:

x A pointer to the string to construct.
utf16 A NUL-terminated UTF-16 encoded C string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiStringConstructVFormatted

Member Of:

LmiString

Description:

Construct an LmiString based on a vprintf-style formatted string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringConstructVFormatted(LmiString* x, const char* fmt, va_list args, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
fmt The printf-style format for the constructed string's contents.
args The arguments to fmt , as constructed by the functions of <stdarg.h>.
a The allocator the string should use.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringData

Member Of:

LmiString

Description:

Get a read-only buffer corresponding to the contents of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

const char* LmiStringData(const LmiString* x)

Parameters:

x The string whose buffer to extract.

Returns:

A read-only pointer to the string's data, as an array of LmiStringSize(x) characters.

Note 1:

The pointer to the buffer may be invalidated by any non-const member function of LmiString, other than LmiStringAt.

Function: LmiStringDestruct

Member Of:

LmiString

Description:

Destruct an LmiString, freeing all associated storage.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

void LmiStringDestruct(LmiString* x)

Parameters:

x A pointer to the string object to destruct.

Function: LmiStringEmpty

Member Of:

LmiString

Description:

Determine whether a string is empty.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringEmpty(const LmiString* x)

Parameters:

x The string whose emptiness to determine.

Returns:

True if the string is empty, else false.

Function: LmiStringEnd

Member Of:

LmiString

Description:

Get an iterator referring to the end of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringIterator LmiStringEnd(LmiString* x)

Parameters:

x The string whose end iterator to obtain.

Returns:

An iterator referring to the end of the string.

Function: LmiStringEndConst

Member Of:

LmiString

Description:

Get an iterator referring to the end of a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringConstIterator LmiStringEndConst(const LmiString* x)

Parameters:

x The string whose const end iterator to obtain.

Returns:

A constant iterator referring to the end of the string.

Function: LmiStringEqual

Member Of:

LmiString

Description:

Compare the values of two LmiStrings for equality.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringEqual(const LmiString* x, const LmiString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringEqualCStr

Member Of:

LmiString

Description:

Compare the value of an LmiString with that of a C string for equality.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringEqualCStr(const LmiString* x, const char* y)

Parameters:

x A pointer to the LmiString object to compare.
y A pointer to the C string to compare.

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringEqualCStrLen

Member Of:

LmiString

Description:

Compare the value of an LmiString with that of a C string of a given length for equality.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringEqualCStrLen(const LmiString* x, const char* y, LmiSizeT ylen)

Parameters:

x A pointer to the LmiString object to compare.
y A pointer to an array of char. The contents of x will be compared to the first ylen bytes of y. The array may include NUL.
ylen The length of the array pointed to by y .

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringErase

Member Of:

LmiString

Description:

Remove a single character from a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringIterator LmiStringErase(LmiString* x, LmiStringIterator p)

Parameters:

x The string from which to erase a range.
p An iterator pointing to the character to erase. Must be a valid iterator into x.

Returns:

An iterator pointing to the element which followed 'p' prior to the range being erased. If no such element exists, end() is returned.

Function: LmiStringEraseRange

Member Of:

LmiString

Description:

Remove a range from a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringIterator LmiStringEraseRange(LmiString* x, LmiStringIterator b, LmiStringIterator e)

Parameters:

x The string from which to erase a range.
b The beginning of the range to erase. Must be a valid iterator into x.
e The end (non-inclusive) of the range to erase. Must be a valid iterator into x.

Returns:

An iterator to the element which followed 'e' prior to the range being erased. If no such element exists, end() is returned.

Function: LmiStringEraseSubstring

Member Of:

LmiString

Description:

Remove a substring from a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringEraseSubstring(LmiString* x, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string from which to erase a substring.
pos The position of the beginning of the range to erase. Must be less than or equal to LmiStringLength(x).
n The number of characters to remove from the string. To remove all characters, pass LMI_STRING_NPOS.

Returns:

The argument passed in, i.e. x.

Function: LmiStringFind

Member Of:

LmiString

Description:

Find a substring.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFind(const LmiString* x, const LmiString* y)

Parameters:

x The string to be searched.
y The string whose characters are to be searched for.

Returns:

The first position in x where y occurs or LMI_STRING_NPOS otherwise.

Function: LmiStringFindCStr

Member Of:

LmiString

Description:

Find a substring.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindCStr(const LmiString* x, const char* y)

Parameters:

x The string to be searched.
y The C string whose characters are to be searched for.

Returns:

The first position in x where y occurs or LMI_STRING_NPOS otherwise.

Function: LmiStringFindCStrLen

Member Of:

LmiString

Description:

Find a substring.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindCStrLen(const LmiString* x, const char* y, LmiSizeT n)

Parameters:

x The string to be searched.
y The C string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The first position in x where y occurs or LMI_STRING_NPOS otherwise.

Function: LmiStringFindFirstNotOf

Member Of:

LmiString

Description:

Find first location in a string where one of the characters in a second string does not occur.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstNotOf(const LmiString* x, LmiSizeT pos, const LmiString* y)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The string whose characters are to be searched for.

Returns:

The first position in x where a character of y does not occur or LMI_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindFirstNotOfCStr

Member Of:

LmiString

Description:

Find first location in a string where one of the characters in a C string does not occur.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstNotOfCStr(const LmiString* x, LmiSizeT pos, const char* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The C string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The first position in x where a character of y does not occur or LMI_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindFirstNotOfChar

Member Of:

LmiString

Description:

Find first location in a string where a given character does not occur.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstNotOfChar(const LmiString* x, LmiSizeT pos, char c)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
c The character to be searched for.

Returns:

The first position in x where character c does not occur or LMI_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindFirstOf

Member Of:

LmiString

Description:

Find first location in a string where one of the characters in a second string occurs.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstOf(const LmiString* x, LmiSizeT pos, const LmiString* y)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The string whose characters are to be searched for.

Returns:

The first position in x where a character of y occurs or LMI_STRING_NPOS if none of the characters were found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindFirstOfCStr

Member Of:

LmiString

Description:

Find first location in a string where one of the characters in a C string occurs.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstOfCStr(const LmiString* x, LmiSizeT pos, const char* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The C string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The first position in x where a character of y occurs or LMI_STRING_NPOS if none of the characters were found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindFirstOfChar

Member Of:

LmiString

Description:

Find first location in a string where a given character occurs.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindFirstOfChar(const LmiString* x, LmiSizeT pos, char c)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
c The character to be searched for.

Returns:

The first position in x where a character c occurs or LMI_STRING_NPOS if not found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindLastNotOfCStr

Member Of:

LmiString

Description:

Find last location in a string where one of the characters in a C string does not occur.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindLastNotOfCStr(const LmiString* x, LmiSizeT pos, const char* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_STRING_NPOS to search the entire string.
y The C string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The last position in x where a character of y does not occur or LMI_STRING_NPOS otherwise.

Function: LmiStringFindLastNotOfChar

Member Of:

LmiString

Description:

Find last location in a string where a given character does not occur.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindLastNotOfChar(const LmiString* x, LmiSizeT pos, char c)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_STRING_NPOS to search the entire string.
c The character to be searched for.

Returns:

The last position in x where a character c does not occur or LMI_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFindLastOfCStr

Member Of:

LmiString

Description:

Find last location in a string where one of the characters in a C string occurs.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindLastOfCStr(const LmiString* x, LmiSizeT pos, const char* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_STRING_NPOS to search the entire string.
y The C string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The last position in x where a character of y occurs or LMI_STRING_NPOS if none of the characters were found.

Function: LmiStringFindLastOfChar

Member Of:

LmiString

Description:

Find last location in a string where a given character occurs.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringFindLastOfChar(const LmiString* x, LmiSizeT pos, char c)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_STRING_NPOS to search the entire string.
c The character to be searched for.

Returns:

The last position in x where a character c occurs or LMI_STRING_NPOS if not found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiStringFront

Member Of:

LmiString

Description:

Return a pointer to the first character in a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

char* LmiStringFront(LmiString* x)

Parameters:

x The string whose first character to obtain.

Returns:

A pointer to the first character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiStringFrontConst

Member Of:

LmiString

Description:

Return a pointer to the first character in a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

const char* LmiStringFrontConst(const LmiString* x)

Parameters:

x The string whose first character to obtain.

Returns:

A pointer to the first character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiStringGetAllocator

Member Of:

LmiString

Description:

Get the allocator of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiAllocator* LmiStringGetAllocator(const LmiString* x)

Parameters:

x A pointer to the string object whose allocator is to be determined.

Returns:

The pointer to the allocator of the string.

Function: LmiStringGetBuffer

Member Of:

LmiString

Description:

Get a writeable buffer into which data can be written outside the control of the LmiString object.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

char* LmiStringGetBuffer(LmiString* x)

Parameters:

x The string whose buffer to extract.

Returns:

A pointer to a buffer. It is safe to write into LmiStringCapacity(x) - LmiStringLength(x) bytes of this buffer. The data in question will be appended to the end of the string.

Note 1:

When the caller is done, the function LmiStringReleaseBuffer must be called to set the new length of the string.

Note 2:

The pointer to the buffer may be invalidated by any non-const member function of LmiString, other than LmiStringAt.

Function: LmiStringHash

Member Of:

LmiString

Description:

Hashes a string into an integer.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringHash(const LmiString* x)

Parameters:

x The string to be hashed.

Returns:

Unsigned integer value of the hashed string.

Function: LmiStringInsert

Member Of:

LmiString

Description:

Insert a single character into a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringIterator LmiStringInsert(LmiString* x, LmiStringIterator pos, const char* c)

Parameters:

x The string to which to insert a character.
pos An iterator pointing to the position at which to insert the character. Must be a valid iterator into x.
c A pointer to the character to insert.

Returns:

An iterator pointing to the inserted character. On allocation failure, the string is unchanged and an exceptional iterator is returned.

Function: LmiStringInsertCStr

Member Of:

LmiString

Description:

Insert a NUL-terminated C string into an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertCStr(LmiString* x, LmiSizeT pos, const char* str)

Parameters:

x The string into which to insert str .
pos The offset at which to insert the substring of str . Must be <= LmiStringLength(x).
str The NUL-terminated C string to insert.

Returns:

NULL on allocation failure, else x.

Function: LmiStringInsertCStrLen

Member Of:

LmiString

Description:

Insert a C string of a given length into an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertCStrLen(LmiString* x, LmiSizeT pos, const char* str, LmiSizeT n)

Parameters:

x The string into which to insert str .
pos The offset at which to insert the substring of str . Must be <= LmiStringLength(x).
str The C string to insert.
n The length of str .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringInsertChar

Member Of:

LmiString

Description:

Insert a single character in an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertChar(LmiString* x, LmiSizeT pos, char c)

Parameters:

x The string into which to insert str .
pos The offset at which to insert c . Must be <= LmiStringLength(x).
c The character to insert.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringInsertFormatted

Member Of:

LmiString

Description:

Insert a printf-style formatted string into an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertFormatted(LmiString* x, LmiSizeT pos, const char* fmt, ...)

Parameters:

x The string in which to insert a formatted string.
pos The offset within x at which to insert the formatted string.
fmt The printf-style format for the inserted string.
... The arguments to fmt .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringInsertRange

Member Of:

LmiString

Description:

Insert a range of characters into a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringInsertRange(LmiString* x, LmiStringIterator pos, LmiStringConstIterator first, LmiStringConstIterator last)

Parameters:

x The string to which to insert a range of characters.
pos An iterator pointing to the position at which to insert the range of characters. Must be a valid iterator into x.
first A constant iterator pointing to the beginning of the range to insert.
last A constant iterator pointing to the end (non-inclusive) of the range to insert. [first,last) must be a valid range.

Returns:

LMI_FALSE on allocation failure, else LMI_TRUE.

Note 1:

It is valid for the replacement range to come from x .

Function: LmiStringInsertString

Member Of:

LmiString

Description:

Insert the contents of one LmiString into another.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertString(LmiString* x, LmiSizeT pos, const LmiString* str)

Parameters:

x The string into which to insert str .
pos The offset at which to insert str . Must be <= LmiStringLength(x).
str The string to insert.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringInsertSubstring

Member Of:

LmiString

Description:

Insert part of the content of one LmiString into another.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertSubstring(LmiString* x, LmiSizeT pos1, const LmiString* str, LmiSizeT pos2, LmiSizeT n)

Parameters:

x The string into which to insert str .
pos1 The offset at which to insert the substring of str . Must be <= LmiStringLength(x).
str The string to insert.
pos2 The offset within str to begin the substring. Must be <= LmiStringLength(str).
n The length of the substring within str . If this is larger than LmiStringLength(str) - pos2, the entire string following pos2 will be inserted. (In particular, LMI_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiStringInsertVFormatted

Member Of:

LmiString

Description:

Insert a vprintf-style formatted string into an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringInsertVFormatted(LmiString* x, LmiSizeT pos, const char* fmt, va_list args)

Parameters:

x The string in which to insert a formatted string.
pos The offset within x at which to insert the formatted string.
fmt The printf-style format for the inserted string.
args The arguments to fmt , as constructed by the functions of <stdarg.h>.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringLength

Member Of:

LmiString

Description:

Get the length of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringLength(const LmiString* x)

Parameters:

x A pointer to the string object whose length is to be determined.

Returns:

The length of the string, in characters.

Function: LmiStringLess

Member Of:

LmiString

Description:

Compare the values of two LmiStrings for ordering.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringLess(const LmiString* x, const LmiString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

LMI_TRUE if x is lexicographically less than y, LMI_FALSE otherwise.

Note 1:

Comparison is done on a byte-by-byte basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiStringMaxSize

Member Of:

LmiString

Description:

Get the maximum supported length of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringMaxSize(const LmiString* x)

Parameters:

x A pointer to the string object whose maximum length is to be determined.

Returns:

The maximum length of the string, in characters.

Function: LmiStringPopBack

Member Of:

LmiString

Description:

Pop a single character from the end of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

void LmiStringPopBack(LmiString* x)

Parameters:

x The string from which to pop a character.

Note 1:

If the string is empty, this function is undefined.

Function: LmiStringPushBack

Member Of:

LmiString

Description:

Push a single character onto the end of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringPushBack(LmiString* x, const char* c)

Parameters:

x The string onto which to push a character.
c A pointer to the character to push.

Returns:

LMI_FALSE on allocation failure, else LMI_TRUE.

Function: LmiStringRBegin

Member Of:

LmiString

Description:

Get a reverse iterator referring to the reversed beginning (end) of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringReverseIterator LmiStringRBegin(LmiString* x)

Parameters:

x The string whose reverse begin iterator to obtain.

Returns:

An iterator referring to the reversed beginning of the string.

Function: LmiStringRBeginConst

Member Of:

LmiString

Description:

Get an iterator referring to the reversed beginning (end) of a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringConstReverseIterator LmiStringRBeginConst(const LmiString* x)

Parameters:

x The string whose const reverse begin iterator to obtain.

Returns:

A constant iterator referring to the reversed beginning of the string.

Function: LmiStringREnd

Member Of:

LmiString

Description:

Get an iterator referring to the reversed end (beginning) of a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringReverseIterator LmiStringREnd(LmiString* x)

Parameters:

x The string whose reversed end iterator to obtain.

Returns:

An iterator referring to the reversed end of the string.

Function: LmiStringREndConst

Member Of:

LmiString

Description:

Get an iterator referring to the reversed end (beginning) of a const string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiStringConstReverseIterator LmiStringREndConst(const LmiString* x)

Parameters:

x The string whose const reversed end iterator to obtain.

Returns:

A constant iterator referring to the reversed end of the string.

Function: LmiStringReleaseBuffer

Member Of:

LmiString

Description:

Release a writeable buffer previously acquired with LmiStringGetBuffer.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

void LmiStringReleaseBuffer(LmiString* x, LmiSizeT buflen)

Parameters:

x The string whose buffer to release.
buflen The number of bytes written into the buffer. This must be less than or equal to LmiStringCapacity(x) - LmiStringLength(x). The string's length will be adjusted accordingly.

Function: LmiStringReplaceCStr

Member Of:

LmiString

Description:

Replace part of an LmiString with a C string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceCStr(LmiString* x, LmiSizeT pos1, LmiSizeT n1, const char* str)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The NUL-terminated C string to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiStringReplaceCStrLen

Member Of:

LmiString

Description:

Replace part of an LmiString with a C string of a given length.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceCStrLen(LmiString* x, LmiSizeT pos1, LmiSizeT n1, const char* str, LmiSizeT n2)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The C string to insert.
n2 The length of str .

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiStringReplaceChar

Member Of:

LmiString

Description:

Replace part of an LmiString with a single character.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceChar(LmiString* x, LmiSizeT pos1, LmiSizeT n1, char c)

Parameters:

x The string in which to replace a substring with a character.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
c The character to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiStringReplaceFormatted

Member Of:

LmiString

Description:

Replace part of an LmiString with a printf-style formatted string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceFormatted(LmiString* x, LmiSizeT pos, LmiSizeT n, const char* fmt, ...)

Parameters:

x The string in which to replace a substring.
pos The position within x of the beginning of the substring to replace.
n The length of the substring to replace.
fmt The printf-style format for the replacement string.
... The arguments to fmt .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringReplaceRange

Member Of:

LmiString

Description:

Replace a range of an LmiString with a different range of string iterators.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceRange(LmiString* x, LmiStringIterator i1, LmiStringIterator i2, LmiStringConstIterator j1, LmiStringConstIterator j2)

Parameters:

x The string in which to replace a range.
i1 The beginning of the range in x to be replaced.
i2 The end of the range in x to be replaced.
j1 The beginning of the replacement range.
j2 The end of the replacement range.

Returns:

NULL on allocation failure out of range, else x.

Note 1:

It is valid for the replacement range to come from x , and even for the ranges to overlap.

Function: LmiStringReplaceString

Member Of:

LmiString

Description:

Replace part of an LmiString with another LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceString(LmiString* x, LmiSizeT pos1, LmiSizeT n1, const LmiString* str)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The string to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiStringReplaceSubstring

Member Of:

LmiString

Description:

Replace part of an LmiString with part of another LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceSubstring(LmiString* x, LmiSizeT pos1, LmiSizeT n1, const LmiString* str, LmiSizeT pos2, LmiSizeT n2)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The string from which to obtain the replacement substring.
pos2 The position within str of the beginning of the replacement substring.
n2 The length of the replacement substring.

Returns:

NULL on allocation failure or pos1 or pos2 out of range, else x.

Function: LmiStringReplaceVFormatted

Member Of:

LmiString

Description:

Replace part of an LmiString with a vprintf-style formatted string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiString* LmiStringReplaceVFormatted(LmiString* x, LmiSizeT pos, LmiSizeT n, const char* fmt, va_list args)

Parameters:

x The string in which to replace a substring.
pos The position within x of the beginning of the substring to replace.
n The length of the substring to replace.
fmt The printf-style format for the replacement string.
args The arguments to fmt , as constructed by the functions of <stdarg.h>.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiStringReserve

Member Of:

LmiString

Description:

Reserve storage for a string.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringReserve(LmiString* x, LmiSizeT res)

Parameters:

x A pointer to the string object for which storage is to be reserved.
res The number of bytes of memory to reserve for the string. After successful return of this function, LmiStringCapacity(x) will be >= res.

Returns:

LMI_FALSE on allocation failure, otherwise LMI_TRUE.

Note 1:

If res is less than the string's current capacity, this function is a non-binding shrink request. If res is less than the string's current size, this function is a non-binding shrink-to-fit request.

Function: LmiStringResize

Member Of:

LmiString

Description:

Alters the length of an LmiString, either by truncating it or extending it.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringResize(LmiString* x, LmiSizeT n, const char* c)

Parameters:

x A pointer to the string object to resize.
n The new length for the string. If this is greater than the current length of the string, the additional contents of the string will be set to 'c'.
c A pointer to the character value with which to fill the string, if the string is being extended.

Returns:

LMI_FALSE on allocation failure, otherwise LMI_TRUE.

Function: LmiStringSize

Member Of:

LmiString

Description:

Get the size of an LmiString.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiStringSize(const LmiString* x)

Parameters:

x A pointer to the string object whose size is to be determined.

Returns:

The size of the string, in characters.

Note 1:

This function is identical to LmiStringLength.

Function: LmiStringSwap

Member Of:

LmiString

Description:

Swap the values of two LmiStrings.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringSwap(LmiString* x, LmiString* y)

Parameters:

x A pointer to the first string object to swap.
y A pointer to the second string object to swap.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Note 1:

The strings' allocators are also swapped.

Function: LmiStringVectorAdd

Member Of:

LmiStringVector

Description:

To add an element to an LmiStringVector object. Optionally, check for uniqueness while adding.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorAdd(LmiStringVector* v, const LmiString* s, LmiBool checkForDuplicates)

Parameters:

v The LmiStringVector object.
s The LmiString object that is to be added to the vector.
checkForDuplicates If set to LMI_TRUE, s is not added if it is already present in the vector.

Returns:

LMI_TRUE if the operation was successful; LMI_FALSE, otherwise.

Function: LmiStringVectorAddCStr

Member Of:

LmiStringVector

Description:

To add an element in C-string format to an LmiStringVector object. Optionally, check for uniqueness while adding.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorAddCStr(LmiStringVector* v, const char* s, LmiBool checkForDuplicates)

Parameters:

v The LmiStringVector object.
s The C-string object that is to be added to the vector.
checkForDuplicates If set to LMI_TRUE, s is not added if it is already present in the vector.

Returns:

LMI_TRUE if the operation was successful; LMI_FALSE, otherwise.

Function: LmiStringVectorIsAMember

Member Of:

LmiStringVector

Description:

To test the membership in an LmiStringVector.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorIsAMember(const LmiStringVector* v, const LmiString* val)

Parameters:

v The vector.
val The string whose membership needs to be tested.

Returns:

LMI_TRUE if member; LMI_FALSE otherwise.

Function: LmiStringVectorIsAMemberCStr

Member Of:

LmiStringVector

Description:

To test the membership (of a C-style string) in an LmiStringVector.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorIsAMemberCStr(const LmiStringVector* v, const char* val)

Parameters:

v The vector.
val The string whose membership needs to be tested.

Returns:

LMI_TRUE if member; LMI_FALSE otherwise.

Function: LmiStringVectorRemove

Member Of:

LmiStringVector

Description:

To remove an element from an LmiStringVector object.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorRemove(LmiStringVector* v, const LmiString* s)

Parameters:

v The LmiStringVector object.
s The element to be removed.

Returns:

LMI_TRUE if the operation was successful; LMI_FALSE, otherwise.

Function: LmiStringVectorRemoveCStr

Member Of:

LmiStringVector

Description:

To remove an element (specified as a C-string) from an LmiStringVector object.

Include:

Lmi/Utils/LmiStringVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringVectorRemoveCStr(LmiStringVector* v, const char* s)

Parameters:

v The LmiStringVector object.
s The element to be removed.

Returns:

LMI_TRUE if the operation was successful; LMI_FALSE, otherwise.

Function: LmiStringWriteUtf16

Member Of:

LmiString

Description:

Encode the contents of a string as UTF-16 into a buffer.

Include:

Lmi/Utils/LmiString.h

Library:

LmiUtils

Syntax:

LmiBool LmiStringWriteUtf16(const LmiString* x, LmiUint16* output, LmiSizeT outputSize, LmiSizeT* outputLen)

Parameters:

x The string whose contents to encode. This string must contain valid UTF-8.
output A pointer to the buffer to which to write the decoded UTF-16 characters. May be NULL if outputSize is 0.
outputSize The size of the buffer to which the decoded UTF-16 characters should be written.
outputLen If not NULL, then on successful return, this will contain the number of UTF-16 codepoints needed to write the contents of the string. If this is more than outputSize-1, the output was truncated.

Returns:

LMI_TRUE if the string's contents were successfully written; LMI_FALSE if not.

Note 1:

If outputSize is greater than 0, the content of the output buffer is always NUL-terminated.

Function: LmiTrivialIteratorConstructExceptional

Member Of:

LmiTrivialIterator

Description:

Constructs an exception iterator. Exceptional iterators are used to indicate failure in cases where the normal return is an iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiTrivialIterator(T_)* LmiTrivialIteratorConstructExceptional(T_)(LmiTrivialIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to be constructed.

Returns:

A pointer to the constructed iterator or NULL on error.

Function: LmiTrivialIteratorContentOf

Member Of:

LmiTrivialIterator

Description:

Gets the content of the object pointed to by the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

T_* LmiTrivialIteratorContentOf(T_)(LmiTrivialIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator whose content is requested.

Returns:

A pointer to the content of the iterator.

Function: LmiTrivialIteratorContentOfConst

Member Of:

LmiTrivialIterator

Description:

Gets the read-only content of the object pointed to by the iterator.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

const T_* LmiTrivialIteratorContentOfConst(T_)(const LmiTrivialIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator whose content is requested.

Returns:

A pointer to the read-only content of the iterator.

Function: LmiTrivialIteratorEqual

Member Of:

LmiTrivialIterator

Description:

Compares two iterators for equality.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiTrivialIteratorEqual(T_)(const LmiTrivialIterator(T_)* x, const LmiTrivialIterator(T_)* y)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator to compare.
y The other iterator to compare.

Returns:

LMI_TRUE if the iterators are equal or LMI_FALSE if they are not.

Function: LmiTrivialIteratorIsExceptional

Member Of:

LmiTrivialIterator

Description:

Determines whether or not the iterator has encountered an exception.

Include:

Lmi/Utils/LmiIterators.h

Library:

LmiUtils

Syntax:

LmiBool LmiTrivialIteratorIsExceptional(T_)(const LmiTrivialIterator(T_)* x)

Template Parameters:

T_ The value type of the iterator.

Parameters:

x The iterator.

Returns:

LMI_TRUE if an exception has occurred on the iterator and LMI_FALSE if no exception has occurred.

Function: LmiUint16Assign

Member Of:

LmiUint16

Description:

Assign the value of one LmiUint16 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint16* LmiUint16Assign(LmiUint16* dst, const LmiUint16* src)

Parameters:

dst A pointer to the LmiUint16 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUint16 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUint16 assignment will not fail.

Function: LmiUint16Construct

Member Of:

LmiUint16

Description:

Construct a default instance of an LmiUint16 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint16* LmiUint16Construct(LmiUint16* obj)

Parameters:

obj A pointer to the LmiUint16 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUint16 object is initialized with the value 0. LmiUint16 construction will not fail.

Function: LmiUint16ConstructCopy

Member Of:

LmiUint16

Description:

Construct a new LmiUint16 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint16* LmiUint16ConstructCopy(LmiUint16* dst, const LmiUint16* src)

Parameters:

dst A pointer to the LmiUint16 object to initialize as a copy.
src An existing LmiUint16 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUint16 construction will not fail.

Function: LmiUint16Destruct

Member Of:

LmiUint16

Description:

Destruct an LmiUint16 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUint16Destruct(LmiUint16* obj)

Parameters:

obj A pointer to the LmiUint16 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUint16Equal

Member Of:

LmiUint16

Description:

Compare the values of two LmiUint16 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint16Equal(const LmiUint16* a, const LmiUint16* b)

Parameters:

a A pointer to the first LmiUint16 object to be compared.
b A pointer to the second LmiUint16 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUint16Less

Member Of:

LmiUint16

Description:

Compare the values of two LmiUint16 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint16Less(const LmiUint16* a, const LmiUint16* b)

Parameters:

a A pointer to the first LmiUint16 object to be compared.
b A pointer to the second LmiUint16 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUint16Swap

Member Of:

LmiUint16

Description:

Swap the contents of two LmiUint16 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint16Swap(LmiUint16* a, LmiUint16* b)

Parameters:

a A pointer to the first LmiUint16 object to be swapped.
b A pointer to the second LmiUint16 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUint16 swapping will not fail.

Function: LmiUint32Assign

Member Of:

LmiUint32

Description:

Assign the value of one LmiUint32 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint32* LmiUint32Assign(LmiUint32* dst, const LmiUint32* src)

Parameters:

dst A pointer to the LmiUint32 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUint32 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUint32 assignment will not fail.

Function: LmiUint32Construct

Member Of:

LmiUint32

Description:

Construct a default instance of an LmiUint32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint32* LmiUint32Construct(LmiUint32* obj)

Parameters:

obj A pointer to the LmiUint32 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUint32 object is initialized with the value 0. LmiUint32 construction will not fail.

Function: LmiUint32ConstructCopy

Member Of:

LmiUint32

Description:

Construct a new LmiUint32 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint32* LmiUint32ConstructCopy(LmiUint32* dst, const LmiUint32* src)

Parameters:

dst A pointer to the LmiUint32 object to initialize as a copy.
src An existing LmiUint32 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUint32 construction will not fail.

Function: LmiUint32Destruct

Member Of:

LmiUint32

Description:

Destruct an LmiUint32 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUint32Destruct(LmiUint32* obj)

Parameters:

obj A pointer to the LmiUint32 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUint32Equal

Member Of:

LmiUint32

Description:

Compare the values of two LmiUint32 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint32Equal(const LmiUint32* a, const LmiUint32* b)

Parameters:

a A pointer to the first LmiUint32 object to be compared.
b A pointer to the second LmiUint32 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUint32Less

Member Of:

LmiUint32

Description:

Compare the values of two LmiUint32 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint32Less(const LmiUint32* a, const LmiUint32* b)

Parameters:

a A pointer to the first LmiUint32 object to be compared.
b A pointer to the second LmiUint32 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUint32Swap

Member Of:

LmiUint32

Description:

Swap the contents of two LmiUint32 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint32Swap(LmiUint32* a, LmiUint32* b)

Parameters:

a A pointer to the first LmiUint32 object to be swapped.
b A pointer to the second LmiUint32 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUint32 swapping will not fail.

Function: LmiUint64Assign

Member Of:

LmiUint64

Description:

Assign the value of one LmiUint64 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint64* LmiUint64Assign(LmiUint64* dst, const LmiUint64* src)

Parameters:

dst A pointer to the LmiUint64 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUint64 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUint64 assignment will not fail.

Function: LmiUint64Construct

Member Of:

LmiUint64

Description:

Construct a default instance of an LmiUint64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint64* LmiUint64Construct(LmiUint64* obj)

Parameters:

obj A pointer to the LmiUint64 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUint64 object is initialized with the value 0. LmiUint64 construction will not fail.

Function: LmiUint64ConstructCopy

Member Of:

LmiUint64

Description:

Construct a new LmiUint64 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint64* LmiUint64ConstructCopy(LmiUint64* dst, const LmiUint64* src)

Parameters:

dst A pointer to the LmiUint64 object to initialize as a copy.
src An existing LmiUint64 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUint64 construction will not fail.

Function: LmiUint64Destruct

Member Of:

LmiUint64

Description:

Destruct an LmiUint64 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUint64Destruct(LmiUint64* obj)

Parameters:

obj A pointer to the LmiUint64 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUint64Equal

Member Of:

LmiUint64

Description:

Compare the values of two LmiUint64 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint64Equal(const LmiUint64* a, const LmiUint64* b)

Parameters:

a A pointer to the first LmiUint64 object to be compared.
b A pointer to the second LmiUint64 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUint64Less

Member Of:

LmiUint64

Description:

Compare the values of two LmiUint64 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint64Less(const LmiUint64* a, const LmiUint64* b)

Parameters:

a A pointer to the first LmiUint64 object to be compared.
b A pointer to the second LmiUint64 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUint64Swap

Member Of:

LmiUint64

Description:

Swap the contents of two LmiUint64 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint64Swap(LmiUint64* a, LmiUint64* b)

Parameters:

a A pointer to the first LmiUint64 object to be swapped.
b A pointer to the second LmiUint64 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUint64 swapping will not fail.

Function: LmiUint8Assign

Member Of:

LmiUint8

Description:

Assign the value of one LmiUint8 object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint8* LmiUint8Assign(LmiUint8* dst, const LmiUint8* src)

Parameters:

dst A pointer to the LmiUint8 object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUint8 object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUint8 assignment will not fail.

Function: LmiUint8Construct

Member Of:

LmiUint8

Description:

Construct a default instance of an LmiUint8 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint8* LmiUint8Construct(LmiUint8* obj)

Parameters:

obj A pointer to the LmiUint8 object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUint8 object is initialized with the value 0. LmiUint8 construction will not fail.

Function: LmiUint8ConstructCopy

Member Of:

LmiUint8

Description:

Construct a new LmiUint8 object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint8* LmiUint8ConstructCopy(LmiUint8* dst, const LmiUint8* src)

Parameters:

dst A pointer to the LmiUint8 object to initialize as a copy.
src An existing LmiUint8 object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUint8 construction will not fail.

Function: LmiUint8Destruct

Member Of:

LmiUint8

Description:

Destruct an LmiUint8 object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUint8Destruct(LmiUint8* obj)

Parameters:

obj A pointer to the LmiUint8 object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUint8Equal

Member Of:

LmiUint8

Description:

Compare the values of two LmiUint8 objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint8Equal(const LmiUint8* a, const LmiUint8* b)

Parameters:

a A pointer to the first LmiUint8 object to be compared.
b A pointer to the second LmiUint8 object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUint8Less

Member Of:

LmiUint8

Description:

Compare the values of two LmiUint8 objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint8Less(const LmiUint8* a, const LmiUint8* b)

Parameters:

a A pointer to the first LmiUint8 object to be compared.
b A pointer to the second LmiUint8 object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUint8Swap

Member Of:

LmiUint8

Description:

Swap the contents of two LmiUint8 objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUint8Swap(LmiUint8* a, LmiUint8* b)

Parameters:

a A pointer to the first LmiUint8 object to be swapped.
b A pointer to the second LmiUint8 object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUint8 swapping will not fail.

Function: LmiUintAssign

Member Of:

LmiUint

Description:

Assign the value of one LmiUint object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint* LmiUintAssign(LmiUint* dst, const LmiUint* src)

Parameters:

dst A pointer to the LmiUint object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUint object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUint assignment will not fail.

Function: LmiUintConstruct

Member Of:

LmiUint

Description:

Construct a default instance of an LmiUint object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint* LmiUintConstruct(LmiUint* obj)

Parameters:

obj A pointer to the LmiUint object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUint object is initialized with the value 0. LmiUint construction will not fail.

Function: LmiUintConstructCopy

Member Of:

LmiUint

Description:

Construct a new LmiUint object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUint* LmiUintConstructCopy(LmiUint* dst, const LmiUint* src)

Parameters:

dst A pointer to the LmiUint object to initialize as a copy.
src An existing LmiUint object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUint construction will not fail.

Function: LmiUintDestruct

Member Of:

LmiUint

Description:

Destruct an LmiUint object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUintDestruct(LmiUint* obj)

Parameters:

obj A pointer to the LmiUint object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUintEqual

Member Of:

LmiUint

Description:

Compare the values of two LmiUint objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintEqual(const LmiUint* a, const LmiUint* b)

Parameters:

a A pointer to the first LmiUint object to be compared.
b A pointer to the second LmiUint object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUintLess

Member Of:

LmiUint

Description:

Compare the values of two LmiUint objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintLess(const LmiUint* a, const LmiUint* b)

Parameters:

a A pointer to the first LmiUint object to be compared.
b A pointer to the second LmiUint object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUintPtrTAssign

Member Of:

LmiUintPtrT

Description:

Assign the value of one LmiUintPtrT object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUintPtrT* LmiUintPtrTAssign(LmiUintPtrT* dst, const LmiUintPtrT* src)

Parameters:

dst A pointer to the LmiUintPtrT object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiUintPtrT object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiUintPtrT assignment will not fail.

Function: LmiUintPtrTConstruct

Member Of:

LmiUintPtrT

Description:

Construct a default instance of an LmiUintPtrT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUintPtrT* LmiUintPtrTConstruct(LmiUintPtrT* obj)

Parameters:

obj A pointer to the LmiUintPtrT object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiUintPtrT object is initialized with the value 0. LmiUintPtrT construction will not fail.

Function: LmiUintPtrTConstructCopy

Member Of:

LmiUintPtrT

Description:

Construct a new LmiUintPtrT object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiUintPtrT* LmiUintPtrTConstructCopy(LmiUintPtrT* dst, const LmiUintPtrT* src)

Parameters:

dst A pointer to the LmiUintPtrT object to initialize as a copy.
src An existing LmiUintPtrT object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiUintPtrT construction will not fail.

Function: LmiUintPtrTDestruct

Member Of:

LmiUintPtrT

Description:

Destruct an LmiUintPtrT object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiUintPtrTDestruct(LmiUintPtrT* obj)

Parameters:

obj A pointer to the LmiUintPtrT object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiUintPtrTEqual

Member Of:

LmiUintPtrT

Description:

Compare the values of two LmiUintPtrT objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintPtrTEqual(const LmiUintPtrT* a, const LmiUintPtrT* b)

Parameters:

a A pointer to the first LmiUintPtrT object to be compared.
b A pointer to the second LmiUintPtrT object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiUintPtrTLess

Member Of:

LmiUintPtrT

Description:

Compare the values of two LmiUintPtrT objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintPtrTLess(const LmiUintPtrT* a, const LmiUintPtrT* b)

Parameters:

a A pointer to the first LmiUintPtrT object to be compared.
b A pointer to the second LmiUintPtrT object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiUintPtrTSwap

Member Of:

LmiUintPtrT

Description:

Swap the contents of two LmiUintPtrT objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintPtrTSwap(LmiUintPtrT* a, LmiUintPtrT* b)

Parameters:

a A pointer to the first LmiUintPtrT object to be swapped.
b A pointer to the second LmiUintPtrT object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUintPtrT swapping will not fail.

Function: LmiUintSwap

Member Of:

LmiUint

Description:

Swap the contents of two LmiUint objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiUintSwap(LmiUint* a, LmiUint* b)

Parameters:

a A pointer to the first LmiUint object to be swapped.
b A pointer to the second LmiUint object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiUint swapping will not fail.

Function: LmiUnique

Member Of:

Algorithms

Description:

Removes adjacent equal elements from a range. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

FI LmiUnique(FI, T)(FI x, FI y)

Template Parameters:

FI The iterator type of the container containing the items to process. The iterator type must be a model of LmiForwardIterator.
T The type stored in the container. The type must be a model of LmiAssignable.

Parameters:

x Points to the first item in the range to be processed.
y Points to one past the last item in the range to be processed.

Returns:

An iterator pointing to the beginning of the invalidated part of the range.

Note 1:

The macro Define_LmiUnique must be called at global scope before calling this function.

Example 1:

				
		Define_LmiUnique(LmiVectorIterator(LmiUint), LmiUint)

		void Unique(LmiVector(LmiUint) *v)
		{
			LmiVectorIterator(LmiUint) end = LmiUnique(LmiVectorIterator(LmiUint), LmiUint)(
				LmiVectorBegin(LmiUint)(v), LmiVectorEnd(LmiUint)(v));
			LmiVectorEraseRange(LmiUint)(v, end, LmiVectorEnd(LmiUint)(v));
		}
	
			

Function: LmiUniqueComp

Member Of:

Algorithms

Description:

Removes adjacent equivalent elements from a range. This function moves all the elements that are not to be removed to the front of the range, preserving their order. It returns an iterator marking the end of the retained elements. To complete the removal process, the caller can erase from this location to the end of the range.

Include:

Lmi/Utils/LmiAlgorithm.h

Library:

LmiUtils

Syntax:

FI LmiUniqueComp(FI, T, Comp)(FI x, FI y)

Template Parameters:

FI The iterator type of the container containing the items to process. The iterator type must be a model of LmiForwardIterator.
T The type stored in the container. The type must be a model of LmiAssignable.
Comp The function to be used to test elements for equivalence.

Parameters:

x Points to the first item in the range to be processed.
y Points to one past the last item in the range to be processed.

Returns:

An iterator pointing to the beginning of the invalidated part of the range.

Note 1:

The macro Define_LmiUniqueComp must be called at global scope before calling this function.

Example 1:

				
		LmiBool SameLastDigit(const LmiUint *a, const LmiUint *b)
		{
			return (*a % 10) == (*b % 10);
		}

		Define_LmiUniqueComp(LmiVectorIterator(LmiUint), LmiUint, SameLastDigit)

		void UniqueByLastDigit(LmiVector(LmiUint) *v)
		{
			LmiVectorIterator(LmiUint) end = LmiUniqueComp(LmiVectorIterator(LmiUint), LmiUint, SameLastDigit)(
				LmiVectorBegin(LmiUint)(v), LmiVectorEnd(LmiUint)(v));
			LmiVectorEraseRange(LmiUint)(v, end, LmiVectorEnd(LmiUint)(v));
		}
	
			

Function: LmiUriAddAuthorityParameter

Member Of:

LmiUri

Description:

Gets an authority parameter from a URI by name.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiBool LmiUriAddAuthorityParameter(LmiUri *uri, const char *name, const char *value)

Parameters:

uri The URI object.
name The name of the parameter.
value The optional value of the parameter.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiUriAddPath

Member Of:

LmiUri

Description:

Adds a path to a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiUriAddPath(LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The name of the parameter.

Returns:

Index of the path just added which can be used to add path parameters.

Function: LmiUriAddPathParameter

Member Of:

LmiUri

Description:

Adds a parameter into a given path index of a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiBool LmiUriAddPathParameter(LmiUri *uri, LmiSizeT index, const char *name, const char *value)

Parameters:

uri The URI object.
index The position index.
name The name of the parameter.
value The value of the parameter.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiUriAddQueryParameter

Member Of:

LmiUri

Description:

Adds a query parameter into a given URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiBool LmiUriAddQueryParameter(LmiUri *uri, const char *name, const char *value)

Parameters:

uri The URI object.
name The name of the parameter.
value The value of the parameter.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Function: LmiUriAppendPathQueryFragmentToString

Member Of:

LmiUri

Description:

Appends the path query and fragment components of a URI to the LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriAppendPathQueryFragmentToString(const LmiUri *uri, LmiSizeT index, LmiString *s, LmiBool percentEncode)

Parameters:

uri The URI object.
index The index of the path from which to start.
s The LmiString to which the path will be appended.
percentEncode Flag to percent encode the output.

Function: LmiUriAppendPathToString

Member Of:

LmiUri

Description:

Appends the full path of a URI without parameters or a leading slash to the LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriAppendPathToString(const LmiUri *uri, LmiString *s, LmiBool percentEncode)

Parameters:

uri The URI object.
s The LmiString to which the path will be appended.
percentEncode Flag to percent encode the output.

Function: LmiUriAppendToString

Member Of:

LmiUri

Description:

Appends the encoding of a URI to an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiBool LmiUriAppendToString(const LmiUri* uri, LmiString* str, LmiBool percentEncode)

Parameters:

uri The URI object.
str The string to append the encoding to.
percentEncode Flag to percent encode the output.

Returns:

LMI_TRUE on success, LMI_FALSE on failure

Function: LmiUriAsStr

Member Of:

LmiUri

Description:

Encodes a URI to a buffer.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiUriAsStr(const LmiUri* uri, char* buf, LmiSizeT buflen, LmiBool percentEncode)

Parameters:

uri The URI object.
buf The buffer to encode the URI into.
buflen The length of the buffer. No more than buflen bytes will be written to buf, including the final NUL. The resulting string will always be NUL-terminated unless buflen == 0.
percentEncode Flag to percent encode the output.

Returns:

The number of characters that would be printed if buflen were unlimited (not counting the final NUL.) If this is greater than or equal to buflen, the formatted string was truncated.

Function: LmiUriAsString

Member Of:

LmiUri

Description:

Encodes a URI to an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiString* LmiUriAsString(const LmiUri* uri, LmiString* buf, LmiBool percentEncode)

Parameters:

uri The URI object.
buf The LmiString object.
percentEncode Flag to percent encode the output.

Returns:

The URI as an LmiString on success; NULL on failure.

Function: LmiUriAssign

Member Of:

LmiUri

Description:

Assigns the value of one URI object to another

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri* LmiUriAssign(LmiUri* uri, const LmiUri* other)

Parameters:

uri The URI object to assign to.
other The existing URI to be copied.

Returns:

A pointer to a URI on success, or NULL on failure

Function: LmiUriCStr

Member Of:

LmiUri

Description:

Gets the URI as an CStr.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char *LmiUriCStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

The URI on success; NULL on failure.

Note 1:

Use with caution. The returned const char * will only be valid until the next non-const operation on LmiUri.

Function: LmiUriClearAuthorityParameters

Member Of:

LmiUri

Description:

Removes all parameters from a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriClearAuthorityParameters(LmiUri *uri)

Parameters:

uri The URI object.

Function: LmiUriConstruct

Member Of:

LmiUri

Description:

Constructs a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri* LmiUriConstruct(LmiUri* uri, const char* scheme, const char* name, const char* host, LmiUint port, const char *authParams, const char *path, const char *query, const char *fragment, LmiAllocator* alloc)

Parameters:

uri The URI object to construct.
scheme URI Scheme.
name An optional NULL terminated C string containing the name field of authority. Set this parameter to NULL if no name is desired.
host A NULL terminated C string containing the host name. Acceptable formats for this string are "IpV4Address", "[IpAddress]" and "DnsName".
port An optional port number. Set this parameter to 0 to leave the port unspecified.
authParams A NULL terminated C string containing the auth params part of the URI. Between the // and /.
path A NULL terminated C string containing the path part of the URI. From end of auth params to the ?.
query A NULL terminated C string containing the path part of the URI. From end of path to the #.
fragment A NULL terminated C string containing the path part of the URI. From end of query to end of string.
alloc An allocator to be used for memory.

Returns:

A pointer to an URI on success, NULL on failure including parse error

Function: LmiUriConstructCStr

Member Of:

LmiUri

Description:

Constructs a URI object from a NULL-terminated C string representation of that URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri* LmiUriConstructCStr(LmiUri* uri, const char* str, LmiAllocator* alloc)

Parameters:

uri The URI object to construct.
str A NULL-terminated string representation of an URI
alloc An allocator to be used for memory

Returns:

A pointer to an URI on success or NULL on failure including parse error

Function: LmiUriConstructCopy

Member Of:

LmiUri

Description:

Constructs a URI object as a copy of an existing URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri* LmiUriConstructCopy(LmiUri* uri, const LmiUri* other)

Parameters:

uri The URI object to construct.
other The existing URI to be copied.

Returns:

A pointer to a URI on success or NULL on failure.

Function: LmiUriConstructDefault

Member Of:

LmiUri

Description:

Constructs a default LmiUri object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri *LmiUriConstructDefault(LmiUri *uri, LmiAllocator *alloc)

Parameters:

uri The URI object to construct.
alloc An allocator to be used for memory

Returns:

A pointer to an URI on success or NULL on failure

Function: LmiUriConstructStr

Member Of:

LmiUri

Description:

Constructs a URI object based on a LMI string representation of that URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUri* LmiUriConstructStr(LmiUri* uri, const LmiString* str, LmiAllocator* alloc)

Parameters:

uri The URI object to construct.
str An LmiString object containing the URI.
alloc An allocator to be used for memory.

Returns:

A pointer to an URI on success, NULL on failure including parse error.

Function: LmiUriDestruct

Member Of:

LmiUri

Description:

Destructs a URI object

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriDestruct(LmiUri* uri)

Parameters:

uri The URI to be destructed.

Function: LmiUriEqual

Member Of:

LmiUri

Description:

Compares two URI objects for equality

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiBool LmiUriEqual(const LmiUri* a, const LmiUri* b)

Parameters:

a A pointer to the first URI to be compared
b A pointer to the second URI to be compared

Returns:

LMI_TRUE if the URIs are equal, otherwise LMI_FALSE.

Function: LmiUriGetAddress

Member Of:

LmiUri

Description:

Gets the address portion of a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetAddress(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A Pointer to a NULL-terminated C String with the address string on success, or NULL on failure

Function: LmiUriGetAddressStr

Member Of:

LmiUri

Description:

Gets the address portion of a URI as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString* LmiUriGetAddressStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to an LmiString object with the address on success, or NULL on failure

Function: LmiUriGetAuthority

Member Of:

LmiUri

Description:

Gets the authority of a URI in a buffer.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiUriGetAuthority(const LmiUri* uri, char *buf, LmiSizeT buflen)

Parameters:

uri The URI object.
buf The buffer to encode the URI into.
buflen The length of the buffer. No more than buflen bytes will be written to buf, including the final NUL. The resulting string will always be NUL-terminated unless buflen == 0

Returns:

The number of characters that would be printed if buflen were unlimited (not counting the final NUL.) If this is greater than or equal to buflen, the formatted string was truncated.

Function: LmiUriGetAuthorityParameter

Member Of:

LmiUri

Description:

Gets an authority parameter from a URI by name.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char *LmiUriGetAuthorityParameter(const LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The name of the parameter.

Returns:

The value of the parameter, or NULL if this parameter is not contained in the given URI.

Function: LmiUriGetAuthorityParameterStr

Member Of:

LmiUri

Description:

Gets an authority parameter from a URI by name.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriGetAuthorityParameterStr(const LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The name of the parameter.

Returns:

The value of the parameter, or NULL if this parameter is not contained in the given URI.

Function: LmiUriGetAuthorityStr

Member Of:

LmiUri

Description:

Gets the authority of a URI as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiString* LmiUriGetAuthorityStr(const LmiUri* uri, LmiString* str)

Parameters:

uri The URI object.
str The LmiString object.

Returns:

The URI Authority as an LmiString on success; NULL on failure.

Function: LmiUriGetFragment

Member Of:

LmiUri

Description:

Gets the fragment field from a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetFragment(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to a NULL-terminated C String with the fragment on success, or NULL on failure

Function: LmiUriGetFragmentStr

Member Of:

LmiUri

Description:

Gets the fragment field from a URI object as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString* LmiUriGetFragmentStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to the LmiString object with the fragment on success, or NULL on failure

Function: LmiUriGetHost

Member Of:

LmiUri

Description:

Gets the host name from a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetHost(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to a NULL-terminated C String with the host name on success, or NULL on failure.

Function: LmiUriGetHostStr

Member Of:

LmiUri

Description:

Gets the host name from a URI as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString* LmiUriGetHostStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to the LmiString object with the host name on success, or NULL on failure

Function: LmiUriGetName

Member Of:

LmiUri

Description:

Gets the name field from a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetName(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to a NULL-terminated C String with the name on success, or NULL on failure

Function: LmiUriGetNameStr

Member Of:

LmiUri

Description:

Gets the name field from a URI object as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString* LmiUriGetNameStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

A pointer to the LmiString object with the name on success, or NULL on failure

Function: LmiUriGetPathCount

Member Of:

LmiUri

Description:

Gets the number of paths in a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiUriGetPathCount(const LmiUri *uri)

Parameters:

uri The URI object.

Returns:

Number of paths in the Uri.

Function: LmiUriGetPathName

Member Of:

LmiUri

Description:

Gets the name of a path in a URI by index.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetPathName(const LmiUri* uri, LmiSizeT index)

Parameters:

uri The URI object.
index The index.

Returns:

A Pointer to a NULL-terminated C String with the name string on success, or NULL on failure

Function: LmiUriGetPathNameStr

Member Of:

LmiUri

Description:

Gets the name of a path in a URI by index.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriGetPathNameStr(const LmiUri* uri, LmiSizeT index)

Parameters:

uri The URI object.
index The index.

Returns:

A name string on success, or NULL on failure

Function: LmiUriGetPathParameter

Member Of:

LmiUri

Description:

Gets a parameter of a path with the position index and a name from a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char *LmiUriGetPathParameter(const LmiUri *uri, LmiSizeT index, const char *name)

Parameters:

uri The URI object.
index The position index.
name The name of the parameter.

Returns:

The value of the path parameter, or NULL if this path parameter is not contained in the given index of the URI.

Function: LmiUriGetPathParameterStr

Member Of:

LmiUri

Description:

Gets a parameter of a path with the position index and a name from a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriGetPathParameterStr(const LmiUri *uri, LmiSizeT index, const char *name)

Parameters:

uri The URI object.
index The position index.
name The name of the parameter.

Returns:

The value of the path parameter, or NULL if this path parameter is not contained in the given index of the URI.

Function: LmiUriGetPort

Member Of:

LmiUri

Description:

Gets the port number from a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiUint LmiUriGetPort(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

The port number. If the URI does not contain a port number, 0 is returned.

Function: LmiUriGetQueryCount

Member Of:

LmiUri

Description:

Gets the number of queries in a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiUriGetQueryCount(const LmiUri *uri)

Parameters:

uri The URI object.

Returns:

Number of queries in the Uri.

Function: LmiUriGetQueryName

Member Of:

LmiUri

Description:

Gets the name of a query in a URI by index.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetQueryName(const LmiUri* uri, LmiSizeT index)

Parameters:

uri The URI object.
index The index.

Returns:

A Pointer to a NULL-terminated C String with the name string on success, or NULL on failure

Function: LmiUriGetQueryNameStr

Member Of:

LmiUri

Description:

Gets the name of a query in a URI by index.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriGetQueryNameStr(const LmiUri* uri, LmiSizeT index)

Parameters:

uri The URI object.
index The index.

Returns:

A name string on success, or NULL on failure

Function: LmiUriGetQueryParameter

Member Of:

LmiUri

Description:

Gets a parameter from a query in a URI by name.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char *LmiUriGetQueryParameter(const LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The name of the parameter.

Returns:

The value of the query parameter, or NULL if this query parameter is not contained in the given URI.

Function: LmiUriGetQueryParameterStr

Member Of:

LmiUri

Description:

Gets a parameter from a query in a URI by name.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriGetQueryParameterStr(const LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The name of the parameter.

Returns:

The value of the query parameter, or NULL if this query parameter is not contained in the given URI.

Function: LmiUriGetScheme

Member Of:

LmiUri

Description:

Gets the scheme of a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const char* LmiUriGetScheme(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

The URI Scheme

Function: LmiUriGetSchemeStr

Member Of:

LmiUri

Description:

Gets the scheme of a URI as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString* LmiUriGetSchemeStr(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

The URI Scheme

Function: LmiUriSetFragment

Member Of:

LmiUri

Description:

Sets the fragment field in a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriSetFragment(LmiUri *uri, const char *fragment)

Parameters:

uri The URI object.
fragment The new fragment field.

Function: LmiUriSetHost

Member Of:

LmiUri

Description:

Sets the host name in a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriSetHost(LmiUri *uri, const char *host)

Parameters:

uri The URI object.
host The new host name.

Function: LmiUriSetName

Member Of:

LmiUri

Description:

Sets the name field in a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriSetName(LmiUri *uri, const char *name)

Parameters:

uri The URI object.
name The new name field.

Function: LmiUriSetPort

Member Of:

LmiUri

Description:

Sets the port number in a URI.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriSetPort(LmiUri *uri, LmiUint port)

Parameters:

uri The URI object.
port The new port number.

Function: LmiUriSetScheme

Member Of:

LmiUri

Description:

Sets the scheme field in a URI object.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

void LmiUriSetScheme(LmiUri *uri, const char *scheme)

Parameters:

uri The URI object.
scheme The new scheme field.

Function: LmiUriString

Member Of:

LmiUri

Description:

Gets the URI as an LmiString.

Include:

Lmi/Utils/LmiUri.h

Library:

LmiUtils

Syntax:

const LmiString *LmiUriString(const LmiUri* uri)

Parameters:

uri The URI object.

Returns:

The URI on success; NULL on failure.

Note 1:

Use with caution. The returned const LmiString * will only be valid until the next non-const operation on LmiUri.

Function: LmiUtilsGetVersion

Member Of:

Utils

Description:

Gets the version of the utilities library.

Include:

Lmi/Utils/LmiUtils.h

Library:

LmiUtils

Syntax:

LmiVersion LmiUtilsGetVersion(void)

Returns:

Returns the version of the utilities library.

Function: LmiUtilsGetVersionString

Member Of:

Utils

Description:

Gets the version of the utilities library, as a human readable string.

Include:

Lmi/Utils/LmiUtils.h

Library:

LmiUtils

Syntax:

const char *LmiUtilsGetVersionString(void)

Returns:

Returns the version string of the utilities library.

Function: LmiUtilsInitialize

Member Of:

Utils

Description:

Initialize all operating-system-independent components of the Vidyo SDK.

Include:

Lmi/Utils/LmiUtils.h

Library:

LmiUtils

Syntax:

LmiBool LmiUtilsInitialize(void)

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

This function is not reentrant.

Note 2:

This function may be called multiple times as long as its corresponding LmiUtilsUninitialize function is called the same number of times.

Function: LmiUtilsUninitialize

Member Of:

Utils

Description:

Uninitialize all operating-system-independent components of the Vidyo SDK.

Include:

Lmi/Utils/LmiUtils.h

Library:

LmiUtils

Syntax:

void LmiUtilsUninitialize(void)

Note 1:

This function is not reentrant.

Note 2:

This function must be called the same number of times as LmiUtilsInitialize was called.

Function: LmiVariableSimulatorGetDiscreteUniform

Member Of:

LmiVariableSimulator

Description:

Simulate a discrete uniform variable. Each of the values between 0 and (n-1) inclusive are equally likely to be selected.

Include:

Lmi/Utils/LmiRandomVars.h

Library:

LmiUtils

Syntax:

LmiUint LmiVariableSimulatorGetDiscreteUniform(LmiVariableSimulator *sim, LmiUint n)

Parameters:

sim The simulator object.
n The number of values to choose from.

Returns:

The value selected.

Note 1:

Returns 0 if there are no values to choose from because n is 0.

Function: LmiVariableSimulatorGetDiscreteUniformInRange

Member Of:

LmiVariableSimulator

Description:

Simulate a discrete uniform variable. Each of the values between min_ and max_ inclusive are equally likely to be selected.

Include:

Lmi/Utils/LmiRandomVars.h

Library:

LmiUtils

Syntax:

LmiInt LmiVariableSimulatorGetDiscreteUniformInRange(LmiVariableSimulator *sim, LmiInt min_, LmiInt max_)

Parameters:

sim The simulator object.
min_ The minimum value in the range.
max_ The maximum value in the range.

Returns:

The value selected.

Note 1:

The behavior is undefined if min_ > max_.

Function: LmiVariableSimulatorGetExponential

Member Of:

LmiVariableSimulator

Description:

Simulate a random variable with an exponential distribution. This distribution may be useful to model events that happen independently and with a constant average rate.

Include:

Lmi/Utils/LmiRandomVars.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiVariableSimulatorGetExponential(LmiVariableSimulator *sim, LmiFloat64 mean)

Parameters:

sim The simulator object.
mean The mean of the distribution.

Returns:

The value selected.

Note 1:

The behavior is undefined if mean <= 0.

Function: LmiVariableSimulatorGetStandardUniform

Member Of:

LmiVariableSimulator

Description:

Simulate a standard uniform variable. This is a continuous uniform variable over the range 0 to 1.

Include:

Lmi/Utils/LmiRandomVars.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiVariableSimulatorGetStandardUniform(LmiVariableSimulator *sim)

Parameters:

sim The simulator object.

Returns:

The value selected.

Function: LmiVariableSimulatorGetUniform

Member Of:

LmiVariableSimulator

Description:

Simulate a continuous uniform variable over a specified range.

Include:

Lmi/Utils/LmiRandomVars.h

Library:

LmiUtils

Syntax:

LmiFloat64 LmiVariableSimulatorGetUniform(LmiVariableSimulator *sim, LmiFloat64 min_, LmiFloat64 max_)

Parameters:

sim The simulator object.
min_ The minimum value in the range.
max_ The maximum value in the range.

Returns:

The value selected.

Note 1:

The behavior is undefined if min_ > max_.

Function: LmiVectorAssign

Member Of:

LmiVector

Description:

Copy one vector to another.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorAssign(T_)(LmiVector(T_)* x, const LmiVector(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to assign to.
y The vector to assign from.

Returns:

A pointer to the assigned to vector or NULL on error.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorAt

Member Of:

LmiVector

Description:

Retrieve a pointer to the element of the vector at index n.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

T_* LmiVectorAt(T_)(LmiVector(T_)* x, LmiVectorSizeType(T_) n)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
n The index of the element to retrieve.

Returns:

A pointer to the element of the vector at index n.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorAtConst

Member Of:

LmiVector

Description:

Retrieve a read-only pointer to the element of the vector at index n.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

const T_* LmiVectorAtConst(T_)(const LmiVector(T_)* x, LmiVectorSizeType(T_) n)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
n The index of the element to retrieve.

Returns:

A read-only pointer to the element of the vector at index n.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorBack

Member Of:

LmiVector

Description:

Retrieve a pointer to the last element of the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

T_* LmiVectorBack(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A pointer to the last element of the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorBackConst

Member Of:

LmiVector

Description:

Retrieve a read-only pointer to the last element of the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

const T_* LmiVectorBackConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only pointer to the last element of the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorBegin

Member Of:

LmiVector

Description:

Gets an iterator to the first element in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorIterator(T_) LmiVectorBegin(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

An iterator to the first element in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorBeginConst

Member Of:

LmiVector

Description:

Gets a read-only iterator to the first element in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorConstIterator(T_) LmiVectorBeginConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only iterator to the first element in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorCapacity

Member Of:

LmiVector

Description:

Gets the number of elements for which memory has been allocated in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorSizeType(T_) LmiVectorCapacity(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

The number of elements for which memory has been allocated in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorClear

Member Of:

LmiVector

Description:

Erase all elements from the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

void LmiVectorClear(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorConstructCopy

Member Of:

LmiVector

Description:

Construct a vector from another vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorConstructCopy(T_)(LmiVector(T_)* x, const LmiVector(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to construct.
y The vector to use to initialize the vector being constructed.

Returns:

A pointer to the constructed vector or NULL on error.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorConstructDefault

Member Of:

LmiVector

Description:

Construct an empty vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorConstructDefault(T_)(LmiVector(T_)* x, LmiAllocator* a)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to construct.
a The vector's allocator.

Returns:

A pointer to the constructed vector or NULL on error.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorConstructN

Member Of:

LmiVector

Description:

Construct a vector and initialize the first n entries in the vector with copies of t.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorConstructN(T_)(LmiVector(T_)* x, LmiVectorSizeType(T_) n, const T_* t, LmiAllocator* a)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to construct.
n The number of entries in the vector to initialize.
t The value to initialize the entries in the vector.
a The vector's allocator.

Returns:

A pointer to the constructed vector or NULL on error.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorConstructRange

Member Of:

LmiVector

Description:

Construct a vector and initialize it with the range specified.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorConstructRange(T_)(LmiVector(T_)* x, LmiVectorConstIterator(T_) first, LmiVectorConstIterator(T_) last, LmiAllocator* a)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to construct.
first A read-only random-access iterator to the first element in the range used to initialize the vector.
last A read-only random-access iterator one past the last element in the range used to initialize the vector.
a The vector's allocator.

Returns:

A pointer to the constructed vector or NULL on error.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorConstructRangeOther

Member Of:

LmiVector

Description:

Construct a vector from a range of another container type.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVector(T_)* LmiVectorConstructRangeOther(T_, InputIterator_)(LmiVector(T_)* x, InputIterator_ first, InputIterator_ last, LmiAllocator* a)

Template Parameters:

T_ The type stored in the vector.
InputIterator_ The input iterator of range.

Parameters:

x The vector to construct.
first A read-only input iterator to the first element in the range used to initialize the vector.
last A read-only input iterator one past the last element in the range used to initialize the vector.
a The vector's allocator.

Returns:

A pointer to the constructed vector or NULL on error.

Note 1:

The macro Declare_LmiVectorConstructRangeOther must be called at global scope before calling LmiVectorConstructRangeOther member functions. LmiVectorConstructRangeOther is not included in the default set of LmiVector functions.

Function: LmiVectorDestruct

Member Of:

LmiVector

Description:

Destruct a vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

void LmiVectorDestruct(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to destruct.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorEmpty

Member Of:

LmiVector

Description:

Test whether or not a vector is empty.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorEmpty(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to test.

Returns:

LMI_TRUE if the vector is empty or LMI_FALSE if it is not.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorEnd

Member Of:

LmiVector

Description:

Gets an iterator to the element one past the last element in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorIterator(T_) LmiVectorEnd(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

An iterator to the element one past the last element in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorEndConst

Member Of:

LmiVector

Description:

Gets a read-only iterator to the element one past the last element in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorConstIterator(T_) LmiVectorEndConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only iterator to the element one past the last element in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorEqual

Member Of:

LmiVector

Description:

Test two vectors for equality.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorEqual(T_)(const LmiVector(T_)* x, const LmiVector(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to compare.
y The other vector to compare.

Returns:

LMI_TRUE if the vectors are equal or LMI_FALSE if they are not.

Note 1:

The macro Declare_LmiVectorEqual must be called at global scope before calling LmiVectorEqual member functions. LmiVectorEqual is not included in the default set of LmiVector functions. It requires that the contained type have an Equal member function.

Function: LmiVectorErase

Member Of:

LmiVector

Description:

Erase the element at a given position from the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorIterator(T_) LmiVectorErase(T_)(LmiVector(T_)* x, LmiVectorIterator(T_) pos)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
pos An iterator pointing to the element to erase from the vector.

Returns:

An iterator to the element after the erased element.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorEraseRange

Member Of:

LmiVector

Description:

Erase the elements in the range [first, last) from the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorIterator(T_) LmiVectorEraseRange(T_)(LmiVector(T_)* x, LmiVectorIterator(T_) first, LmiVectorIterator(T_) last)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
first An iterator to the first element to erase from the vector.
last An iterator one past the last element to erase from the vector.

Returns:

An iterator to the element after the erased elements.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorFront

Member Of:

LmiVector

Description:

Retrieve a pointer to the first element of the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

T_* LmiVectorFront(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A pointer to the first element of the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorFrontConst

Member Of:

LmiVector

Description:

Retrieve a read-only pointer to the first element of the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

const T_* LmiVectorFrontConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only pointer to the first element of the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorGetAllocator

Member Of:

LmiVector

Description:

Gets a pointer to the vector's allocator.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiAllocator* LmiVectorGetAllocator(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A pointer to the vector's allocator.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorInsert

Member Of:

LmiVector

Description:

Insert t into a vector before pos.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorIterator(T_) LmiVectorInsert(T_)(LmiVector(T_)* x, LmiVectorIterator(T_) pos, const T_* t)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
pos An iterator indicating the position where the insertion should take place.
t The value to insert in the vector.

Returns:

An iterator to the newly inserted element. If an error occurred the iterator returned will be "exceptional". See LmiVectorIteratorIsExceptional for details on how to determine this condition.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorInsertN

Member Of:

LmiVector

Description:

Insert n copies of t into a vector before pos.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorInsertN(T_)(LmiVector(T_)* x, LmiVectorIterator(T_) pos, LmiVectorSizeType(T_) n, const T_* t)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
pos An iterator indicating the position where the insertion should take place.
n The number of copies to t to insert into the vector.
t The value of the newly inserted elements in the vector.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorInsertRange

Member Of:

LmiVector

Description:

Insert the elements in the range [first, last) into a vector before pos.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorInsertRange(T_)(LmiVector(T_)* x, LmiVectorIterator(T_) pos, LmiVectorConstIterator(T_) first, LmiVectorConstIterator(T_) last)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
pos An iterator indicating the position where the insertion should take place.
first An iterator to the first element to insert into the vector.
last An iterator one past the last element to insert into the vector.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorLess

Member Of:

LmiVector

Description:

Test whether one vector is lexicographically less than another.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorLess(T_)(const LmiVector(T_)* x, const LmiVector(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to compare.
y The other vector to compare.

Returns:

LMI_TRUE if the first vector is lexicographically less than the second vector or LMI_FALSE if it is not.

Note 1:

The macro Declare_LmiVectorLess must be called at global scope before calling LmiVectorLess member functions. LmiVectorLess is not included in the default set of LmiVector functions. It requires that the contained type be less-than comparable (i.e. have a Less member function).

Note 2:

Equivalent to calling LmiLexicographicalCompare with the entire range of each vector.

Function: LmiVectorMaxSize

Member Of:

LmiVector

Description:

Gets the maximum number of elements the vector could contain.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorSizeType(T_) LmiVectorMaxSize(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

The maximum number of elements the vector could contain.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorPopBack

Member Of:

LmiVector

Description:

Remove the last element from the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

void LmiVectorPopBack(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorPushBack

Member Of:

LmiVector

Description:

Add an element to the end of the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorPushBack(T_)(LmiVector(T_)* x, const T_* t)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
t A point to an object of type T to add to the end of the vector.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorRBegin

Member Of:

LmiVector

Description:

Gets a reverse iterator to the first element in the reversed vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorReverseIterator(T_) LmiVectorRBegin(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A reverse iterator to the first element in the reversed vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorRBeginConst

Member Of:

LmiVector

Description:

Gets a read-only reverse iterator to the first element in the reversed vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorConstReverseIterator(T_) LmiVectorRBeginConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only reverse iterator to the first element in the reversed vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorREnd

Member Of:

LmiVector

Description:

Gets a reverse iterator to the element one past the last element in the reversed vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorReverseIterator(T_) LmiVectorREnd(T_)(LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A reverse iterator to the element one past the last element in the reversed vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorREndConst

Member Of:

LmiVector

Description:

Gets a read-only reverse iterator to the element one past the last element in the reversed vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorConstReverseIterator(T_) LmiVectorREndConst(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

A read-only reverse iterator to the element one past the last element in the reversed vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorReserve

Member Of:

LmiVector

Description:

Reserves memory capacity in the vector. If capacity is less than or equal to LmiVectorCapacity(T) this call has no effect.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorReserve(T_)(LmiVector(T_)* x, LmiVectorSizeType(T_) capacity)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
capacity The requested memory capacity in number of elements.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorResize

Member Of:

LmiVector

Description:

Resize a vector. If the current size of the vector is less than n then additional copies of t are added to the end of the vector. If the current size of the vector is greater than n then the elements from index n to the end of the vector are erased.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorResize(T_)(LmiVector(T_)* x, LmiVectorSizeType(T_) n, const T_* t)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.
n The size to make the vector.
t A point to an object of type T to initialize new elements of the vector.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorSize

Member Of:

LmiVector

Description:

Gets the number of elements in the vector.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiVectorSizeType(T_) LmiVectorSize(T_)(const LmiVector(T_)* x)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector.

Returns:

The number of elements in the vector.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVectorSwap

Member Of:

LmiVector

Description:

Swap two vectors.

Include:

Lmi/Utils/LmiVector.h

Library:

LmiUtils

Syntax:

LmiBool LmiVectorSwap(T_)(LmiVector(T_)* x, LmiVector(T_)* y)

Template Parameters:

T_ The type stored in the vector.

Parameters:

x The vector to swap.
y The other vector to swap.

Returns:

LMI_TRUE on success or LMI_FALSE on failure.

Note 1:

The macro Declare_LmiVector must be called at global scope before calling any LmiVector member functions.

Function: LmiVersionAsString

Member Of:

LmiVersion

Description:

Gets the version as a human readable string.

Include:

Lmi/Utils/LmiVersion.h

Library:

LmiUtils

Syntax:

LmiString* LmiVersionAsString(const LmiVersion* x, LmiString* s)

Parameters:

x A version object.
s A constructed string into which the human readable version is written.

Returns:

Returns a pointer to the string on success or NULL on error.

Function: LmiVersionGetEngineering

Member Of:

LmiVersion

Description:

Gets the engineering revision field of a version.

Include:

Lmi/Utils/LmiVersion.h

Library:

LmiUtils

Syntax:

LmiUint LmiVersionGetEngineering(const LmiVersion* x)

Parameters:

x A version object.

Returns:

Returns the engineering revision field of a version.

Function: LmiVersionGetMajor

Member Of:

LmiVersion

Description:

Gets the major revision field of a version.

Include:

Lmi/Utils/LmiVersion.h

Library:

LmiUtils

Syntax:

LmiUint LmiVersionGetMajor(const LmiVersion* x)

Parameters:

x A version object.

Returns:

Returns the major revision field of a version.

Function: LmiVersionGetMinor

Member Of:

LmiVersion

Description:

Gets the minor revision field of a version.

Include:

Lmi/Utils/LmiVersion.h

Library:

LmiUtils

Syntax:

LmiUint LmiVersionGetMinor(const LmiVersion* x)

Parameters:

x A version object.

Returns:

Returns the minor revision field of a version.

Function: LmiVersionGetPatch

Member Of:

LmiVersion

Description:

Gets the patch revision field of a version.

Include:

Lmi/Utils/LmiVersion.h

Library:

LmiUtils

Syntax:

LmiUint LmiVersionGetPatch(const LmiVersion* x)

Parameters:

x A version object.

Returns:

Returns the patch revision field of a version.

Function: LmiVoidPtrAssign

Member Of:

LmiVoidPtr

Description:

Assign the value of one LmiVoidPtr object to another one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiVoidPtr* LmiVoidPtrAssign(LmiVoidPtr* dst, const LmiVoidPtr* src)

Parameters:

dst A pointer to the LmiVoidPtr object to be assigned. The object is assumed to already be initialized.
src A pointer to an existing LmiVoidPtr object.

Returns:

A pointer to dst, or NULL on failure.

Note 1:

LmiVoidPtr assignment will not fail.

Function: LmiVoidPtrConstruct

Member Of:

LmiVoidPtr

Description:

Construct a default instance of an LmiVoidPtr object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiVoidPtr* LmiVoidPtrConstruct(LmiVoidPtr* obj)

Parameters:

obj A pointer to the LmiVoidPtr object to initialize.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

The LmiVoidPtr object is initialized with the value ((void*)0) ( NULL ). LmiVoidPtr construction will not fail.

Function: LmiVoidPtrConstructCopy

Member Of:

LmiVoidPtr

Description:

Construct a new LmiVoidPtr object as a copy of an existing one.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiVoidPtr* LmiVoidPtrConstructCopy(LmiVoidPtr* dst, const LmiVoidPtr* src)

Parameters:

dst A pointer to the LmiVoidPtr object to initialize as a copy.
src An existing LmiVoidPtr object.

Returns:

A pointer to the constructed object on full successful completion, otherwise NULL.

Note 1:

LmiVoidPtr construction will not fail.

Function: LmiVoidPtrDestruct

Member Of:

LmiVoidPtr

Description:

Destruct an LmiVoidPtr object.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

void LmiVoidPtrDestruct(LmiVoidPtr* obj)

Parameters:

obj A pointer to the LmiVoidPtr object to destruct. The object is assumed to be previously initialized.

Note 1:

This function does nothing; it is provided for completeness and to support the use of container classes.

Function: LmiVoidPtrEqual

Member Of:

LmiVoidPtr

Description:

Compare the values of two LmiVoidPtr objects for equality.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiVoidPtrEqual(const LmiVoidPtr* a, const LmiVoidPtr* b)

Parameters:

a A pointer to the first LmiVoidPtr object to be compared.
b A pointer to the second LmiVoidPtr object to be compared.

Returns:

LMI_TRUE if the objects pointed to are equal, otherwise LMI_FALSE.

Function: LmiVoidPtrLess

Member Of:

LmiVoidPtr

Description:

Compare the values of two LmiVoidPtr objects for ordering.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiVoidPtrLess(const LmiVoidPtr* a, const LmiVoidPtr* b)

Parameters:

a A pointer to the first LmiVoidPtr object to be compared.
b A pointer to the second LmiVoidPtr object to be compared.

Returns:

LMI_TRUE if the parameter pointed to by a is less than the one pointed to by b, otherwise LMI_FALSE.

Function: LmiVoidPtrSwap

Member Of:

LmiVoidPtr

Description:

Swap the contents of two LmiVoidPtr objects.

Include:

Lmi/Utils/LmiTypes.h

Library:

LmiUtils

Syntax:

LmiBool LmiVoidPtrSwap(LmiVoidPtr* a, LmiVoidPtr* b)

Parameters:

a A pointer to the first LmiVoidPtr object to be swapped.
b A pointer to the second LmiVoidPtr object to be swapped.

Returns:

LMI_TRUE on success, LMI_FALSE on failure.

Note 1:

LmiVoidPtr swapping will not fail.

Function: LmiWideStringAppend

Member Of:

LmiWideString

Description:

Append the contents of one LmiWideString to another.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppend(LmiWideString* x, const LmiWideString* str)

Parameters:

x The string to append to.
str The string to be appended.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAppendCStr

Member Of:

LmiWideString

Description:

Append a NUL-terminated C wide string to an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendCStr(LmiWideString* x, const LmiWideChar* str)

Parameters:

x The string to which to append str .
str The NUL-terminated C wide string to append.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAppendCStrLen

Member Of:

LmiWideString

Description:

Append a C wide string of a given length to an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendCStrLen(LmiWideString* x, const LmiWideChar* str, LmiSizeT n)

Parameters:

x The string to which to append str .
str The C wide string to append.
n The length of str .

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAppendChar

Member Of:

LmiWideString

Description:

Append a single character to an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendChar(LmiWideString* x, LmiWideChar c)

Parameters:

x The string to append to.
c The character to be appended.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAppendN

Member Of:

LmiWideString

Description:

Append multiple copies of a character to an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendN(LmiWideString* x, LmiSizeT n, LmiWideChar c)

Parameters:

x The string to which to append n copies of c .
n The number of copies of c to append.
c The character to append.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAppendRange

Member Of:

LmiWideString

Description:

Append a range of characters to a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendRange(LmiWideString* x, LmiWideStringConstIterator first, LmiWideStringConstIterator last)

Parameters:

x The string to which to append the range.
first The beginning of the range to insert.
last The (non-inclusive) end of the range to insert. [first,last) must be a valid range.

Returns:

NULL on allocation failure, else x.

Note 1:

It is valid for the appended range to come from x .

Function: LmiWideStringAppendSubstring

Member Of:

LmiWideString

Description:

Append a substring of one LmiWideString to another.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAppendSubstring(LmiWideString* x, const LmiWideString* str, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string to append to.
str The string of which a substring is to be appended.
pos The offset within str of the beginning of the substring. Must be <= LmiWideStringLength(str).
n The length of the substring to be appended. If n is larger than LmiWideStringLength(str) - pos, the entire string following pos will be inserted. (In particular, LMI_WIDE_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAssign

Member Of:

LmiWideString

Description:

Assign the value of one LmiWideString to another. The previous data stored in the destination is overwritten.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssign(LmiWideString* x, const LmiWideString* y)

Parameters:

x A pointer to the string object to construct.
y A pointer to the string object to copy.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringAssignCStr

Member Of:

LmiWideString

Description:

Assign a NUL-terminated C wide string as the new value of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignCStr(LmiWideString* x, const LmiWideChar* str)

Parameters:

x The string to which to assign str .
str The NUL-terminated C wide string to assign.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAssignCStrLen

Member Of:

LmiWideString

Description:

Assign a C wide string of a given length as the new value of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignCStrLen(LmiWideString* x, const LmiWideChar* str, LmiSizeT n)

Parameters:

x The string to which to assign str .
str The C wide string to assign.
n The length of str .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiWideStringAssignChar

Member Of:

LmiWideString

Description:

Assign a single character as the new value of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignChar(LmiWideString* x, LmiWideChar c)

Parameters:

x The string to assign to.
c The character to be assigned.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAssignRange

Member Of:

LmiWideString

Description:

Assign a range of characters as the new value of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignRange(LmiWideString* x, LmiWideStringConstIterator first, LmiWideStringConstIterator last)

Parameters:

x The string to which to assign the range.
first The beginning of the range to assign.
last The (non-inclusive) end of the range to assign. [first,last) must be a valid range.

Returns:

NULL on allocation failure, else x.

Note 1:

It is valid for the replacement range to come from x .

Function: LmiWideStringAssignSubstring

Member Of:

LmiWideString

Description:

Assign a substring of one LmiWideString as the new value of another.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignSubstring(LmiWideString* x, const LmiWideString* str, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string to assign to.
str The string of which a substring is to be assigned.
pos The offset within str of the beginning of the substring. Must be <= LmiWideStringLength(str).
n The length of the substring to be assigned. If n is larger than LmiWideStringLength(str) - pos, the entire string following pos will be inserted. (In particular, LMI_WIDE_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringAssignUtf16

Member Of:

LmiWideString

Description:

Assign a wide string to have the Unicode values of a UTF16-encoded C string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignUtf16(LmiWideString* x, const LmiUint16* utf16)

Parameters:

x A pointer to the string to construct.
utf16 A NUL-terminated UTF-8 narrow C string.

Returns:

NULL on allocation or conversion failure, else x.

Function: LmiWideStringAssignUtf8

Member Of:

LmiWideString

Description:

Assign a wide string to have the Unicode values of a UTF8-encoded narrow C string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignUtf8(LmiWideString* x, const char* utf8)

Parameters:

x A pointer to the string to construct.
utf8 A NUL-terminated UTF-8 encoded narrow C string.

Returns:

NULL on allocation or conversion failure, else x.

Function: LmiWideStringAssignUtf8Len

Member Of:

LmiWideString

Description:

Assign a wide string to have the Unicode values of a UTF8-encoded narrow C string of a given length.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringAssignUtf8Len(LmiWideString* x, const char* utf8, LmiSizeT len)

Parameters:

x A pointer to the string to construct.
utf8 A UTF-8 encoded narrow C string. This may contain NUL bytes.
len The length of the UTF-8 encoded narrow C string, in bytes. This length must encompass entire well-formed UTF-8 characters.

Returns:

NULL on allocation or conversion failure, else x.

Function: LmiWideStringAt

Member Of:

LmiWideString

Description:

Get a pointer to the character stored at a specific position in a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideChar* LmiWideStringAt(LmiWideString* x, LmiSizeT n)

Parameters:

x The string from which the character should be extracted.
n The position of the character to be extracted.

Returns:

A pointer to the character to be extracted. This pointer is invalidated if a non-const member function, other than LmiWideStringAt, is invoked on x. It is not valid to write to this pointer.

Function: LmiWideStringAtConst

Member Of:

LmiWideString

Description:

Get a constant pointer to the character stored at a specific position in a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

const LmiWideChar* LmiWideStringAtConst(const LmiWideString* x, LmiSizeT n)

Parameters:

x The string from which the character should be extracted.
n The position of the character to be extracted.

Returns:

A pointer to the character to be extracted. This pointer is invalidated if a non-const member function, other than LmiWideStringAt, is invoked on x.

Function: LmiWideStringBack

Member Of:

LmiWideString

Description:

Return a pointer to the last character in a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideChar* LmiWideStringBack(LmiWideString* x)

Parameters:

x The string whose last character to obtain.

Returns:

A pointer to the last character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiWideStringBackConst

Member Of:

LmiWideString

Description:

Return a pointer to the last character in a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

const LmiWideChar* LmiWideStringBackConst(const LmiWideString* x)

Parameters:

x The string whose last character to obtain.

Returns:

A pointer to the last character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiWideStringBegin

Member Of:

LmiWideString

Description:

Get an iterator referring to the beginning of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringIterator LmiWideStringBegin(LmiWideString* x)

Parameters:

x The string whose begin iterator to obtain.

Returns:

An iterator referring to the beginning of the string.

Function: LmiWideStringBeginConst

Member Of:

LmiWideString

Description:

Get an iterator referring to the beginning of a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringConstIterator LmiWideStringBeginConst(const LmiWideString* x)

Parameters:

x The string whose const begin iterator to obtain.

Returns:

A constant iterator referring to the beginning of the string.

Function: LmiWideStringCStr

Member Of:

LmiWideString

Description:

Get a NUL-terminated C wide string corresponding to the contents of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

const LmiWideChar* LmiWideStringCStr(const LmiWideString* x)

Parameters:

x The string whose C wide string to obtain.

Returns:

A read-only array of LmiWideStringSize(x) characters followed by a NUL character.

Note 1:

The pointer to the C string may be invalidated by any non-const member function of LmiWideString, other than LmiWideStringAt.

Function: LmiWideStringCapacity

Member Of:

LmiWideString

Description:

Get the size of the allocated storage of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringCapacity(const LmiWideString* x)

Parameters:

x A pointer to the string object whose capacity is to be determined.

Returns:

The capacity of the string, in characters.

Function: LmiWideStringClear

Member Of:

LmiWideString

Description:

Erase the contents of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

void LmiWideStringClear(LmiWideString* x)

Parameters:

x The string to clear.

Note 1:

Does not necessarily alter the string's capacity.

Function: LmiWideStringCompare

Member Of:

LmiWideString

Description:

Compare the values of two LmiWideStrings for ordering.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiInt LmiWideStringCompare(const LmiWideString* x, const LmiWideString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringCompareCStr

Member Of:

LmiWideString

Description:

Compare the value of an LmiWideString with that of a C wide string for ordering.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiInt LmiWideStringCompareCStr(const LmiWideString* x, const LmiWideChar* y)

Parameters:

x A pointer to the LmiWideString object to compare.
y A pointer to the C wide string to compare.

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringCompareCStrLen

Member Of:

LmiWideString

Description:

Compare the value of an LmiWideString with that of a C wide string of a given length for ordering.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiInt LmiWideStringCompareCStrLen(const LmiWideString* x, const LmiWideChar* y, LmiSizeT ylen)

Parameters:

x A pointer to the LmiWideString object to compare.
y A pointer to an array of char. The contents of x will be compared to the first ylen characters of y. The array may include NUL.
ylen The length of the array pointed to by y .

Returns:

A value <0, 0, or >0, depending on whether x is lexicographically less than, equal to, or greater than y, respectively.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringConstructCStr

Member Of:

LmiWideString

Description:

Construct an LmiWideString based on a NUL-terminated C wide string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructCStr(LmiWideString* x, const LmiWideChar* str, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str A NUL-terminated C wide string. The initial contents of x will be equal to the value of str up to its terminating NUL.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructCStrLen

Member Of:

LmiWideString

Description:

Construct an LmiWideString based on a C wide string of a given length.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructCStrLen(LmiWideString* x, const LmiWideChar* str, LmiSizeT len, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str A pointer to an array of LmiWideChar. The initial contents of x will be equal to the first len characters of str. The array may include NUL characters.
len The number of characters to include from str .
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructCopy

Member Of:

LmiWideString

Description:

Construct a copy of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructCopy(LmiWideString* x, const LmiWideString* y)

Parameters:

x A pointer to the string object to construct.
y A pointer to the string object to copy.

Returns:

A pointer to the string object, or NULL on failure.

Note 1:

The newly-constructed string uses the same allocator as the source string did.

Function: LmiWideStringConstructDefault

Member Of:

LmiWideString

Description:

Construct an empty LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructDefault(LmiWideString* x, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructRange

Member Of:

LmiWideString

Description:

Construct an LmiWideString based on a range of another LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructRange(LmiWideString* x, LmiWideStringConstIterator first, LmiWideStringConstIterator last, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
first The beginning of the source range.
last The end of the source range.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructSubstring

Member Of:

LmiWideString

Description:

Construct an LmiWideString based on a substring of another LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructSubstring(LmiWideString* x, const LmiWideString* str, LmiSizeT pos, LmiSizeT n, LmiAllocator* a)

Parameters:

x A pointer to the string object to construct.
str The source LmiWideString object.
pos The initial position of the substring within the source string.
n The length of the substring within the source string. The value LMI_WIDE_STRING_NPOS indicates the entire string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructUtf16

Member Of:

LmiWideString

Description:

Construct a wide string to have the Unicode values of a UTF16-encoded C string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructUtf16(LmiWideString* x, const LmiUint16* utf16, LmiAllocator* a)

Parameters:

x A pointer to the string to construct.
utf16 A NUL-terminated UTF-16 encoded C string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructUtf8

Member Of:

LmiWideString

Description:

Construct a wide string to have the Unicode values of a UTF8-encoded narrow C string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructUtf8(LmiWideString* x, const char* utf8, LmiAllocator* a)

Parameters:

x A pointer to the string to construct.
utf8 A NUL-terminated UTF-8 encoded narrow C string.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringConstructUtf8Len

Member Of:

LmiWideString

Description:

Construct a wide string to have the Unicode values of a UTF8-encoded narrow C string of a given length.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringConstructUtf8Len(LmiWideString* x, const char* utf8, LmiSizeT len, LmiAllocator* a)

Parameters:

x A pointer to the string to construct.
utf8 A UTF-8 encoded narrow C string. This may contain NUL bytes.
len The length of the UTF-8 encoded narrow C string, in bytes. This length must encompass entire well-formed UTF-8 characters.
a The allocator the string should use.

Returns:

A pointer to the string object, or NULL on failure.

Function: LmiWideStringData

Member Of:

LmiWideString

Description:

Get a read-only buffer corresponding to the contents of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

const LmiWideChar* LmiWideStringData(const LmiWideString* x)

Parameters:

x The string whose buffer to extract.

Returns:

A read-only pointer to the string's data, as an array of LmiWideStringSize(x) characters.

Note 1:

The pointer to the buffer may be invalidated by any non-const member function of LmiWideString, other than LmiWideStringAt.

Function: LmiWideStringDestruct

Member Of:

LmiWideString

Description:

Destruct an LmiWideString, freeing all associated storage.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

void LmiWideStringDestruct(LmiWideString* x)

Parameters:

x A pointer to the string object to destruct.

Function: LmiWideStringEmpty

Member Of:

LmiWideString

Description:

Determine whether a string is empty.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringEmpty(const LmiWideString* x)

Parameters:

x The string whose emptiness to determine.

Returns:

True if the string is empty, else false.

Function: LmiWideStringEnd

Member Of:

LmiWideString

Description:

Get an iterator referring to the end of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringIterator LmiWideStringEnd(LmiWideString* x)

Parameters:

x The string whose end iterator to obtain.

Returns:

An iterator referring to the end of the string.

Function: LmiWideStringEndConst

Member Of:

LmiWideString

Description:

Get an iterator referring to the end of a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringConstIterator LmiWideStringEndConst(const LmiWideString* x)

Parameters:

x The string whose const end iterator to obtain.

Returns:

A constant iterator referring to the end of the string.

Function: LmiWideStringEqual

Member Of:

LmiWideString

Description:

Compare the values of two LmiWideStrings for equality.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringEqual(const LmiWideString* x, const LmiWideString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringEqualCStr

Member Of:

LmiWideString

Description:

Compare the value of an LmiWideString with that of a C wide string for equality.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringEqualCStr(const LmiWideString* x, const LmiWideChar* y)

Parameters:

x A pointer to the LmiWideString object to compare.
y A pointer to the C string to compare.

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringEqualCStrLen

Member Of:

LmiWideString

Description:

Compare the value of an LmiWideString with that of a C wide string of a given length for equality.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringEqualCStrLen(const LmiWideString* x, const LmiWideChar* y, LmiSizeT ylen)

Parameters:

x A pointer to the LmiWideString object to compare.
y A pointer to an array of LmiWideChar. The contents of x will be compared to the first ylen characters of y. The array may include NUL.
ylen The length of the array pointed to by y .

Returns:

LMI_TRUE if the strings are equal, LMI_FALSE otherwise.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringErase

Member Of:

LmiWideString

Description:

Remove a single character from a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringIterator LmiWideStringErase(LmiWideString* x, LmiWideStringIterator p)

Parameters:

x The string from which to erase a range.
p An iterator pointing to the character to erase. Must be a valid iterator into x.

Returns:

An iterator pointing to the element which followed 'p' prior to the range being erased. If no such element exists, end() is returned.

Function: LmiWideStringEraseRange

Member Of:

LmiWideString

Description:

Remove a range from a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringIterator LmiWideStringEraseRange(LmiWideString* x, LmiWideStringIterator b, LmiWideStringIterator e)

Parameters:

x The string from which to erase a range.
b The beginning of the range to erase. Must be a valid iterator into x.
e The end (non-inclusive) of the range to erase. Must be a valid iterator into x.

Returns:

An iterator to the element which followed 'e' prior to the range being erased. If no such element exists, end() is returned.

Function: LmiWideStringEraseSubstring

Member Of:

LmiWideString

Description:

Remove a substring from a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringEraseSubstring(LmiWideString* x, LmiSizeT pos, LmiSizeT n)

Parameters:

x The string from which to erase a substring.
pos The position of the beginning of the range to erase. Must be less than or equal to LmiWideStringLength(x).
n The number of characters to remove from the string. To remove all characters, pass LMI_WIDE_STRING_NPOS.

Returns:

The argument passed in, i.e. x.

Function: LmiWideStringFindFirstNotOf

Member Of:

LmiWideString

Description:

Find first location in a string where one of the characters in a second string does not occur.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstNotOf(const LmiWideString* x, LmiSizeT pos, const LmiWideString* y)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The string whose characters are to be searched for.

Returns:

The first position in x where a character of y does not occur or LMI_WIDE_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindFirstNotOfCStr

Member Of:

LmiWideString

Description:

Find first location in a string where one of the characters in a C wide string does not occur.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstNotOfCStr(const LmiWideString* x, LmiSizeT pos, const LmiWideChar* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The C wide string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The first position in x where a character of y does not occur or LMI_WIDE_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindFirstNotOfChar

Member Of:

LmiWideString

Description:

Find first location in a string where a given character does not occur.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstNotOfChar(const LmiWideString* x, LmiSizeT pos, LmiWideChar c)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
c The character to be searched for.

Returns:

The first position in x where character c does not occurs or LMI_WIDE_STRING_NPOS otherwise.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindFirstOf

Member Of:

LmiWideString

Description:

Find first location in a string where one of the characters in a second string occurs.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstOf(const LmiWideString* x, LmiSizeT pos, const LmiWideString* y)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The string whose characters are to be searched for.

Returns:

The first position in x where a character of y occurs or LMI_WIDE_STRING_NPOS if none of the characters were found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindFirstOfCStr

Member Of:

LmiWideString

Description:

Find first location in a string where one of the characters in a C wide string occurs.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstOfCStr(const LmiWideString* x, LmiSizeT pos, const LmiWideChar* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
y The C wide string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The first position in x where a character of y occurs or LMI_WIDE_STRING_NPOS if none of the characters were found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindFirstOfChar

Member Of:

LmiWideString

Description:

Find first location in a string where a given character occurs.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindFirstOfChar(const LmiWideString* x, LmiSizeT pos, LmiWideChar c)

Parameters:

x The string to be searched.
pos The position in x to start the search from.
c The character to be searched for.

Returns:

The first position in x where a character c occurs or LMI_WIDE_STRING_NPOS if not found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFindLastOfCStr

Member Of:

LmiWideString

Description:

Find last location in a string where one of the characters in a C wide string occurs.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindLastOfCStr(const LmiWideString* x, LmiSizeT pos, const LmiWideChar* y, LmiSizeT n)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_WIDE_STRING_NPOS to search the entire string.
y The C wide string whose characters are to be searched for.
n The number of characters from y to use in the search.

Returns:

The last position in x where a character of y occurs or LMI_WIDE_STRING_NPOS if none of the characters were found.

Function: LmiWideStringFindLastOfChar

Member Of:

LmiWideString

Description:

Find last location in a string where a given character occurs.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringFindLastOfChar(const LmiWideString* x, LmiSizeT pos, LmiWideChar c)

Parameters:

x The string to be searched.
pos The position in x to start searching backward from. Set this to LMI_WIDE_STRING_NPOS to search the entire string.
c The character to be searched for.

Returns:

The last position in x where a character c occurs or LMI_WIDE_STRING_NPOS if not found.

Note 1:

The order of the parameters has been modified from the C++ string class member function that this function was derived from, to make the interface more logical within the constraints of the C Programming language.

Function: LmiWideStringFront

Member Of:

LmiWideString

Description:

Return a pointer to the first character in a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideChar* LmiWideStringFront(LmiWideString* x)

Parameters:

x The string whose first character to obtain.

Returns:

A pointer to the first character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiWideStringFrontConst

Member Of:

LmiWideString

Description:

Return a pointer to the first character in a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

const LmiWideChar* LmiWideStringFrontConst(const LmiWideString* x)

Parameters:

x The string whose first character to obtain.

Returns:

A pointer to the first character in the string.

Note 1:

If the string is empty this function is undefined.

Function: LmiWideStringGetAllocator

Member Of:

LmiWideString

Description:

Get the allocator of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiAllocator* LmiWideStringGetAllocator(const LmiWideString* x)

Parameters:

x A pointer to the string object whose allocator is to be determined.

Returns:

The pointer to the allocator of the string.

Function: LmiWideStringGetBuffer

Member Of:

LmiWideString

Description:

Get a writeable buffer into which data can be written outside the control of the LmiWideString object.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideChar* LmiWideStringGetBuffer(LmiWideString* x)

Parameters:

x The string whose buffer to extract.

Returns:

A pointer to a buffer. It is safe to write into LmiWideStringCapacity(x) - LmiWideStringLength(x) characters of this buffer. The data in question will be appended to the end of the string.

Note 1:

When the caller is done, the function LmiWideStringReleaseBuffer must be called to set the new length of the string.

Note 2:

The pointer to the buffer may be invalidated by any non-const member function of LmiWideString, other than LmiWideStringAt.

Function: LmiWideStringHash

Member Of:

LmiWideString

Description:

Hashes a string into an integer.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringHash(const LmiWideString* x)

Parameters:

x The string to be hashed.

Returns:

Unsigned integer value of the hashed string.

Function: LmiWideStringInsert

Member Of:

LmiWideString

Description:

Insert a single character into a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringIterator LmiWideStringInsert(LmiWideString* x, LmiWideStringIterator pos, const LmiWideChar* c)

Parameters:

x The string to which to insert a character.
pos An iterator pointing to the position at which to insert the character. Must be a valid iterator into x.
c A pointer to the character to insert.

Returns:

An iterator pointing to the inserted character. On allocation failure, the string is unchanged and an exceptional iterator is returned.

Function: LmiWideStringInsertCStr

Member Of:

LmiWideString

Description:

Insert a NUL-terminated C wide string into an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringInsertCStr(LmiWideString* x, LmiSizeT pos, const LmiWideChar* str)

Parameters:

x The string into which to insert str .
pos The offset at which to insert the substring of str . Must be <= LmiWideStringLength(x).
str The NUL-terminated C wide string to insert.

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringInsertCStrLen

Member Of:

LmiWideString

Description:

Insert a C wide string of a given length into an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringInsertCStrLen(LmiWideString* x, LmiSizeT pos, const LmiWideChar* str, LmiSizeT n)

Parameters:

x The string into which to insert str .
pos The offset at which to insert the substring of str . Must be <= LmiWideStringLength(x).
str The C wide string to insert.
n The length of str .

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiWideStringInsertChar

Member Of:

LmiWideString

Description:

Insert a single character in an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringInsertChar(LmiWideString* x, LmiSizeT pos, LmiWideChar c)

Parameters:

x The string into which to insert str .
pos The offset at which to insert c . Must be <= LmiWideStringLength(x).
c The character to insert.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiWideStringInsertRange

Member Of:

LmiWideString

Description:

Insert a range of characters into a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringInsertRange(LmiWideString* x, LmiWideStringIterator pos, LmiWideStringConstIterator first, LmiWideStringConstIterator last)

Parameters:

x The string to which to insert a range of characters.
pos An iterator pointing to the position at which to insert the range of characters. Must be a valid iterator into x.
first A constant iterator pointing to the beginning of the range to insert.
last A constant iterator pointing to the end (non-inclusive) of the range to insert. [first,last) must be a valid range.

Returns:

LMI_FALSE on allocation failure, else LMI_TRUE.

Note 1:

It is valid for the replacement range to come from x .

Function: LmiWideStringInsertString

Member Of:

LmiWideString

Description:

Insert the contents of one LmiWideString into another.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringInsertString(LmiWideString* x, LmiSizeT pos, const LmiWideString* str)

Parameters:

x The string into which to insert str .
pos The offset at which to insert str . Must be <= LmiWideStringLength(x).
str The string to insert.

Returns:

NULL on allocation failure or pos out of range, else x.

Function: LmiWideStringInsertSubstring

Member Of:

LmiWideString

Description:

Insert part of the content of one LmiWideString into another.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringInsertSubstring(LmiWideString* x, LmiSizeT pos1, const LmiWideString* str, LmiSizeT pos2, LmiSizeT n)

Parameters:

x The string into which to insert str .
pos1 The offset at which to insert the substring of str . Must be <= LmiWideStringLength(x).
str The string to insert.
pos2 The offset within str to begin the substring. Must be <= LmiWideStringLength(str).
n The length of the substring within str . If this is larger than LmiWideStringLength(str) - pos2, the entire string following pos2 will be inserted. (In particular, LMI_WIDE_STRING_NPOS indicates the entire rest of the string.)

Returns:

NULL on allocation failure, else x.

Function: LmiWideStringLength

Member Of:

LmiWideString

Description:

Get the length of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringLength(const LmiWideString* x)

Parameters:

x A pointer to the string object whose length is to be determined.

Returns:

The length of the string, in characters.

Function: LmiWideStringLess

Member Of:

LmiWideString

Description:

Compare the values of two LmiWideStrings for ordering.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringLess(const LmiWideString* x, const LmiWideString* y)

Parameters:

x A pointer to the first string object to compare.
y A pointer to the second string object to compare.

Returns:

LMI_TRUE if x is lexicographically less than y, LMI_FALSE otherwise.

Note 1:

Comparison is done on a character-by-character basis. No knowledge of the strings' character sets is assumed. (Among other things, this means that the strings are compared case-sensitively.)

Function: LmiWideStringMaxSize

Member Of:

LmiWideString

Description:

Get the maximum supported length of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringMaxSize(const LmiWideString* x)

Parameters:

x A pointer to the string object whose maximum length is to be determined.

Returns:

The maximum length of the string, in characters.

Function: LmiWideStringPopBack

Member Of:

LmiWideString

Description:

Pop a single character from the end of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

void LmiWideStringPopBack(LmiWideString* x)

Parameters:

x The string from which to pop a character.

Note 1:

If the string is empty, this function is undefined.

Function: LmiWideStringPushBack

Member Of:

LmiWideString

Description:

Push a single character onto the end of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringPushBack(LmiWideString* x, const LmiWideChar* c)

Parameters:

x The string onto which to push a character.
c A pointer to the character to push.

Returns:

LMI_FALSE on allocation failure, else LMI_TRUE.

Function: LmiWideStringRBegin

Member Of:

LmiWideString

Description:

Get a reverse iterator referring to the reversed beginning (end) of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringReverseIterator LmiWideStringRBegin(LmiWideString* x)

Parameters:

x The string whose reverse begin iterator to obtain.

Returns:

An iterator referring to the reversed beginning of the string.

Function: LmiWideStringRBeginConst

Member Of:

LmiWideString

Description:

Get an iterator referring to the reversed beginning (end) of a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringConstReverseIterator LmiWideStringRBeginConst(const LmiWideString* x)

Parameters:

x The string whose const reverse begin iterator to obtain.

Returns:

A constant iterator referring to the reversed beginning of the string.

Function: LmiWideStringREnd

Member Of:

LmiWideString

Description:

Get an iterator referring to the reversed end (beginning) of a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringReverseIterator LmiWideStringREnd(LmiWideString* x)

Parameters:

x The string whose reversed end iterator to obtain.

Returns:

An iterator referring to the reversed end of the string.

Function: LmiWideStringREndConst

Member Of:

LmiWideString

Description:

Get an iterator referring to the reversed end (beginning) of a const string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideStringConstReverseIterator LmiWideStringREndConst(const LmiWideString* x)

Parameters:

x The string whose const reversed end iterator to obtain.

Returns:

A constant iterator referring to the reversed end of the string.

Function: LmiWideStringReleaseBuffer

Member Of:

LmiWideString

Description:

Release a writeable buffer previously acquired with LmiWideStringGetBuffer.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

void LmiWideStringReleaseBuffer(LmiWideString* x, LmiSizeT buflen)

Parameters:

x The string whose buffer to release.
buflen The number of characters written into the buffer. This must be less than or equal to LmiWideStringCapacity(x) - LmiWideStringLength(x). The string's length will be adjusted accordingly.

Function: LmiWideStringReplaceCStr

Member Of:

LmiWideString

Description:

Replace part of an LmiWideString with a C wide string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceCStr(LmiWideString* x, LmiSizeT pos1, LmiSizeT n1, const LmiWideChar* str)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The NUL-terminated C wide string to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiWideStringReplaceCStrLen

Member Of:

LmiWideString

Description:

Replace part of an LmiWideString with a C wide string of a given length.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceCStrLen(LmiWideString* x, LmiSizeT pos1, LmiSizeT n1, const LmiWideChar* str, LmiSizeT n2)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The C wide string to insert.
n2 The length of str .

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiWideStringReplaceChar

Member Of:

LmiWideString

Description:

Replace part of an LmiWideString with a single character.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceChar(LmiWideString* x, LmiSizeT pos1, LmiSizeT n1, LmiWideChar c)

Parameters:

x The string in which to replace a substring with a character.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
c The character to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiWideStringReplaceRange

Member Of:

LmiWideString

Description:

Replace a range of an LmiWideString with a different range of string iterators.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceRange(LmiWideString* x, LmiWideStringIterator i1, LmiWideStringIterator i2, LmiWideStringConstIterator j1, LmiWideStringConstIterator j2)

Parameters:

x The string in which to replace a range.
i1 The beginning of the range in x to be replaced.
i2 The end of the range in x to be replaced.
j1 The beginning of the replacement range.
j2 The end of the replacement range.

Returns:

NULL on allocation failure out of range, else x.

Note 1:

It is valid for the replacement range to come from x , and even for the ranges to overlap.

Function: LmiWideStringReplaceString

Member Of:

LmiWideString

Description:

Replace part of an LmiWideString with another LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceString(LmiWideString* x, LmiSizeT pos1, LmiSizeT n1, const LmiWideString* str)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The string to insert.

Returns:

NULL on allocation failure or pos1 out of range, else x.

Function: LmiWideStringReplaceSubstring

Member Of:

LmiWideString

Description:

Replace part of an LmiWideString with part of another LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiWideString* LmiWideStringReplaceSubstring(LmiWideString* x, LmiSizeT pos1, LmiSizeT n1, const LmiWideString* str, LmiSizeT pos2, LmiSizeT n2)

Parameters:

x The string in which to replace a substring.
pos1 The position within x of the beginning of the substring to replace.
n1 The length of the substring to replace.
str The string from which to obtain the replacement substring.
pos2 The position within str of the beginning of the replacement substring.
n2 The length of the replacement substring.

Returns:

NULL on allocation failure or pos1 or pos2 out of range, else x.

Function: LmiWideStringReserve

Member Of:

LmiWideString

Description:

Reserve storage for a string.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringReserve(LmiWideString* x, LmiSizeT res)

Parameters:

x A pointer to the string object for which storage is to be reserved.
res The number of characters of memory to reserve for the string. After successful return of this function, LmiWideStringCapacity(x) will be >= res.

Returns:

LMI_FALSE on allocation failure, otherwise LMI_TRUE.

Note 1:

If res is less than the string's current capacity, this function is a non-binding shrink request. If res is less than the string's current size, this function is a non-binding shrink-to-fit request.

Function: LmiWideStringResize

Member Of:

LmiWideString

Description:

Alters the length of an LmiWideString, either by truncating it or extending it.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringResize(LmiWideString* x, LmiSizeT n, const LmiWideChar* c)

Parameters:

x A pointer to the string object to resize.
n The new length for the string. If this is greater than the current length of the string, the additional contents of the string will be set to 'c'.
c A pointer to the character value with which to fill the string, if the string is being extended.

Returns:

LMI_FALSE on allocation failure, otherwise LMI_TRUE.

Function: LmiWideStringSize

Member Of:

LmiWideString

Description:

Get the size of an LmiWideString.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiSizeT LmiWideStringSize(const LmiWideString* x)

Parameters:

x A pointer to the string object whose size is to be determined.

Returns:

The size of the string, in characters.

Note 1:

This function is identical to LmiWideStringLength.

Function: LmiWideStringSwap

Member Of:

LmiWideString

Description:

Swap the values of two LmiWideStrings.

Include:

Lmi/Utils/LmiWideString.h

Library:

LmiUtils

Syntax:

LmiBool LmiWideStringSwap(LmiWideString* x, LmiWideString* y)

Parameters:

x A pointer to the first string object to swap.
y A pointer to the second string object to swap.

Returns:

LMI_TRUE on success, LMI_FALSE otherwise.

Note 1:

The strings' allocators are also swapped.