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

Method checkCanCache

framework/cacheModule/CacheModule.cpp:177–196  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

175}
176
177CacheRet CacheModule::checkCanCache()
178{
179 AF_LOGD("---> checkCanCache()");
180 bool matchConfig = mCacheChecker.checkMediaInfo();
181
182 if (!matchConfig) {
183 // not match with config
184 AF_LOGE("---> checkCanCache() not match with config");
185 return CACHE_ERROR_MEDIA_INFO_NOT_MATCH;
186 }
187
188 bool spaceEnough = mCacheChecker.checkSpaceEnough();
189
190 if (!spaceEnough) {
191 AF_LOGE("---> checkCanCache() space not Enough");
192 return CACHE_ERROR_MEDIA_INFO_NOT_MATCH;
193 }
194
195 return CACHE_SUCCESS;
196}
197
198
199void CacheModule::addFrame(const IAFPacket *frame, StreamType type)

Callers

nothing calls this directly

Calls 2

checkMediaInfoMethod · 0.80
checkSpaceEnoughMethod · 0.80

Tested by

no test coverage detected