#include <string.h>
Class to store the character count for a string operation. StringCount allows you to specify a character count for operations like Insert or GetPart. However it also allows you to specify a StringPosition instead (implicitly defining the count).
Here an example for GetPart. The first parameter of GetPart is the class StringPosition, the second StringCount.
Public Member Functions | |
| MAXON_IMPLICIT | StringCount (Int count) | 
| MAXON_IMPLICIT | StringCount (StringPosition pos) | 
| MAXON_ATTRIBUTE_FORCE_INLINE Int | ResolvePosition (Int startPos, Int length) const | 
| MAXON_ATTRIBUTE_FORCE_INLINE Int | ResolveCount (Int startPos, Int length) const | 
Private Attributes | |
| Int | _value | 
Static Private Attributes | |
| static const Int | STRING_COUNT_BIT | 
| MAXON_IMPLICIT StringCount | ( | Int | count | ) | 
Constructor.
| [in] | count | The number of characters. | 
Constructor from a StringPosition.
| [in] | pos | The string position from the beginning or the end. | 
| MAXON_ATTRIBUTE_FORCE_INLINE Int ResolvePosition | ( | Int | startPos, | 
| Int | length | ||
| ) | const | 
Calculates the end position of a range based on a given start position and a string length.
| [in] | startPos | The starting position of the range. | 
| [in] | length | The length of the string. | 
| MAXON_ATTRIBUTE_FORCE_INLINE Int ResolveCount | ( | Int | startPos, | 
| Int | length | ||
| ) | const | 
Calculates the character count of a range based on a given start position and a string length.
| [in] | startPos | The starting position of the range. | 
| [in] | length | The length of the string. | 
      
  | 
  staticprivate | 
      
  | 
  private |