MCPcopy Create free account
hub / github.com/alibaba/CicadaPlayer / getArray

Method getArray

framework/utils/CicadaJSON.cpp:173–188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

171}
172
173CicadaJSONArray CicadaJSONItem::getArray(const std::string& name) const
174{
175 if (nullptr == mJSON) {
176 return CicadaJSONArray();
177 }
178
179 if (cJSON_HasObjectItem(mJSON, name.c_str())) {
180 cJSON *json = cJSON_GetObjectItem(mJSON, name.c_str());
181
182 if (json != nullptr) {
183 return CicadaJSONArray(json);
184 }
185 }
186
187 return CicadaJSONArray();
188}
189
190bool CicadaJSONItem::hasItem(const std::string &name) const
191{

Callers 5

setCodecSpecificDataMethod · 0.45
setDrmInfoMethod · 0.45
convertMethod · 0.45
onRequestKeyCallbackMethod · 0.45

Calls 3

cJSON_HasObjectItemFunction · 0.85
cJSON_GetObjectItemFunction · 0.85
CicadaJSONArrayClass · 0.70

Tested by

no test coverage detected