DIPlib Documentation - ©1995-2017 Quantitative Imaging Group, Delft University of Technology.

StringNew

Allocate a string

SYNOPSIS

#include "dip_string.h"

dip_Error dip_StringNew ( string, size, init, resources )

FUNCTION

This function allocates a string of size size. If init is not zero, its contents is copied into the new string. If size is zero, and init is not, the size of string is made equal to init plus one.

ARGUMENTS

Data typeNameDescription
dip_String *stringPointer to the new string
dip_intsizeSize of the string
char *initInitialisation string
dip_ResourcesresourcesResources tracking structure. See ResourcesNew

SEE ALSO

StringArrayNew, StringAppend, StringCat, StringCompare, StringCompareCaseInsensitive, StringCopy, StringCrop, StringReplace, UnderscoreSpaces