FastLED
3.9.15
Loading...
Searching...
No Matches
◆
StrN()
[3/5]
template<size_t SIZE = 64>
fl::StrN
< SIZE >::StrN
(
const char *
str
)
inline
Definition at line
119
of file
str.h
.
119
{
120
size_t
len
=
strlen
(
str
);
121
mLength
=
len
;
// Length is without null terminator
122
if
(
len
+ 1 <=
SIZE
) {
// Check capacity including null
123
memcpy
(
mInlineData
,
str
,
len
+ 1);
// Copy including null
124
mHeapData
.reset();
125
}
else
{
126
mHeapData
=
StringHolderPtr::New
(
str
);
127
}
128
}
fl::StrN::mLength
size_t mLength
Definition
str.h:109
fl::StrN::mHeapData
StringHolderPtr mHeapData
Definition
str.h:111
fl::StrN::mInlineData
char mInlineData[SIZE]
Definition
str.h:110
fl::StrN
Definition
str.h:107
References
mHeapData
,
mInlineData
, and
mLength
.
fl
StrN
Generated on Mon Jun 16 2025 06:27:50 for FastLED by
1.13.2