Flutter Engine
The Flutter Engine
Functions
string.cpp File Reference
#include "export.h"
#include "third_party/skia/include/core/SkString.h"

Go to the source code of this file.

Functions

SKWASM_EXPORT SkStringskString_allocate (size_t length)
 
SKWASM_EXPORT char * skString_getData (SkString *string)
 
SKWASM_EXPORT void skString_free (SkString *string)
 
SKWASM_EXPORT std::u16string * skString16_allocate (size_t length)
 
SKWASM_EXPORT char16_t * skString16_getData (std::u16string *string)
 
SKWASM_EXPORT void skString16_free (std::u16string *string)
 

Function Documentation

◆ skString16_allocate()

SKWASM_EXPORT std::u16string * skString16_allocate ( size_t  length)

Definition at line 21 of file string.cpp.

21 {
22 std::u16string* string = new std::u16string();
23 string->resize(length);
24 return string;
25}
size_t length

◆ skString16_free()

SKWASM_EXPORT void skString16_free ( std::u16string *  string)

Definition at line 31 of file string.cpp.

31 {
32 delete string;
33}

◆ skString16_getData()

SKWASM_EXPORT char16_t * skString16_getData ( std::u16string *  string)

Definition at line 27 of file string.cpp.

27 {
28 return string->data();
29}

◆ skString_allocate()

SKWASM_EXPORT SkString * skString_allocate ( size_t  length)

Definition at line 9 of file string.cpp.

9 {
10 return new SkString(length);
11}

◆ skString_free()

SKWASM_EXPORT void skString_free ( SkString string)

Definition at line 17 of file string.cpp.

17 {
18 return delete string;
19}

◆ skString_getData()

SKWASM_EXPORT char * skString_getData ( SkString string)

Definition at line 13 of file string.cpp.

13 {
14 return string->data();
15}