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
118
of file
str.h
.
118
{
119
size_t
len
=
strlen
(
str
);
120
mLength
=
len
;
// Length is without null terminator
121
if
(
len
+ 1 <=
SIZE
) {
// Check capacity including null
122
memcpy
(
mInlineData
,
str
,
len
+ 1);
// Copy including null
123
mHeapData
.reset();
124
}
else
{
125
mHeapData
=
StringHolderPtr::New
(
str
);
126
}
127
}
fl::StrN::mLength
size_t mLength
Definition
str.h:108
fl::StrN::mHeapData
StringHolderPtr mHeapData
Definition
str.h:110
fl::StrN::mInlineData
char mInlineData[SIZE]
Definition
str.h:109
fl::StrN
Definition
str.h:106
References
mHeapData
,
mInlineData
, and
mLength
.
fl
StrN
Generated on Thu May 29 2025 04:44:59 for FastLED by
1.13.2