| 67 | } |
| 68 | |
| 69 | bool CookAssetsStep::CacheEntry::IsValid(bool withDependencies) |
| 70 | { |
| 71 | AssetInfo assetInfo; |
| 72 | if (Content::GetAssetInfo(ID, assetInfo)) |
| 73 | { |
| 74 | if (TypeName == assetInfo.TypeName) |
| 75 | { |
| 76 | if (FileSystem::GetFileLastEditTime(assetInfo.Path) <= FileModified) |
| 77 | { |
| 78 | bool isValid = true; |
| 79 | if (withDependencies) |
| 80 | { |
| 81 | for (auto& f : FileDependencies) |
| 82 | { |
| 83 | if (FileSystem::GetFileLastEditTime(f.First) > f.Second) |
| 84 | { |
| 85 | isValid = false; |
| 86 | break; |
| 87 | } |
| 88 | } |
| 89 | } |
| 90 | if (isValid) |
| 91 | return true; |
| 92 | } |
| 93 | } |
| 94 | } |
| 95 | return false; |
| 96 | } |
| 97 | |
| 98 | CookAssetsStep::CacheEntry& CookAssetsStep::CacheData::CreateEntry(const JsonAssetBase* asset, String& cachedFilePath) |
| 99 | { |
no outgoing calls
no test coverage detected