Move FileSystem to WTF
authorross.kirsling@sony.com <ross.kirsling@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jan 2019 17:25:57 +0000 (17:25 +0000)
committerross.kirsling@sony.com <ross.kirsling@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jan 2019 17:25:57 +0000 (17:25 +0000)
https://bugs.webkit.org/show_bug.cgi?id=193602

Reviewed by Yusuke Suzuki.

Source/WebCore:

* Modules/encryptedmedia/CDM.cpp:
* Modules/encryptedmedia/legacy/WebKitMediaKeySession.cpp:
* Modules/entriesapi/DOMFileSystem.cpp:
* Modules/entriesapi/FileSystemEntry.cpp:
* Modules/indexeddb/IDBDatabaseIdentifier.cpp:
* Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:
* Modules/indexeddb/server/SQLiteIDBTransaction.cpp:
* Modules/indexeddb/shared/InProcessIDBServer.cpp:
* Modules/webdatabase/DatabaseTracker.cpp:
* Modules/webdatabase/OriginLock.cpp:
* Modules/webdatabase/OriginLock.h:
* Modules/webdatabase/cocoa/DatabaseManagerCocoa.mm:
* PlatformMac.cmake:
* PlatformPlayStation.cmake:
* PlatformWin.cmake:
* Sources.txt:
* SourcesCocoa.txt:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/GCController.cpp:
* dom/DataTransferItem.cpp:
* editing/cocoa/WebContentReaderCocoa.mm:
* fileapi/File.cpp:
* fileapi/FileCocoa.mm:
* html/FileInputType.cpp:
* html/FileListCreator.cpp:
* loader/appcache/ApplicationCacheHost.cpp:
* loader/appcache/ApplicationCacheStorage.cpp:
* page/Page.cpp:
* page/SecurityOrigin.cpp:
* page/SecurityOriginData.cpp:
* platform/FileHandle.h:
* platform/FileStream.cpp:
* platform/FileStream.h:
* platform/SharedBuffer.h:
* platform/SourcesGLib.txt:
* platform/cocoa/FileMonitorCocoa.mm:
* platform/glib/FileMonitorGLib.cpp:
* platform/glib/SharedBufferGlib.cpp:
* platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm:
* platform/graphics/avfoundation/objc/CDMSessionAVStreamSession.mm:
* platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
* platform/ios/QuickLook.mm:
* platform/ios/WebItemProviderPasteboard.mm:
* platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:
* platform/network/BlobDataFileReference.cpp:
* platform/network/BlobRegistryImpl.cpp:
* platform/network/BlobResourceHandle.cpp:
* platform/network/FormData.cpp:
* platform/network/cf/FormDataStreamCFNet.cpp:
* platform/network/cocoa/ResourceRequestCocoa.mm:
* platform/network/curl/CookieJarDB.cpp:
* platform/network/curl/CurlCacheEntry.h:
* platform/network/curl/CurlCacheManager.cpp:
* platform/network/curl/CurlFormDataStream.h:
* platform/network/curl/CurlRequest.h:
* platform/network/curl/NetworkStorageSessionCurl.cpp:
* platform/network/curl/ResourceHandleCurl.cpp:
* platform/network/mac/BlobDataFileReferenceMac.mm:
* platform/network/soup/ResourceHandleSoup.cpp:
* platform/network/soup/SoupNetworkSession.cpp:
* platform/posix/SharedBufferPOSIX.cpp:
* platform/sql/SQLiteFileSystem.cpp:
* platform/text/hyphen/HyphenationLibHyphen.cpp:
* platform/win/SearchPopupMenuDB.cpp:
* rendering/RenderTheme.cpp:
* rendering/RenderThemeGtk.cpp:
* rendering/RenderThemeWin.cpp:
* workers/service/server/RegistrationDatabase.cpp:

Source/WebCore/PAL:

* PAL.xcodeproj/project.pbxproj:
* pal/PlatformMac.cmake:

Source/WebKit:

* NetworkProcess/Classifier/ResourceLoadStatisticsPersistentStorage.cpp:
* NetworkProcess/NetworkDataTaskBlob.h:
* NetworkProcess/NetworkProcess.cpp:
* NetworkProcess/cache/CacheStorageEngine.cpp:
* NetworkProcess/cache/CacheStorageEngineCaches.cpp:
* NetworkProcess/cache/NetworkCache.cpp:
* NetworkProcess/cache/NetworkCacheBlobStorage.cpp:
* NetworkProcess/cache/NetworkCacheData.cpp:
* NetworkProcess/cache/NetworkCacheFileSystem.cpp:
* NetworkProcess/cache/NetworkCacheFileSystem.h:
* NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm:
* NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:
* NetworkProcess/cache/NetworkCacheStatistics.cpp:
* NetworkProcess/cache/NetworkCacheStorage.cpp:
* NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
* NetworkProcess/cocoa/NetworkSessionCocoa.mm:
* NetworkProcess/mac/NetworkProcessMac.mm:
* NetworkProcess/soup/NetworkProcessSoup.cpp:
* PluginProcess/unix/PluginProcessMainUnix.cpp:
* Shared/PersistencyUtils.cpp:
* Shared/Plugins/Netscape/unix/NetscapePluginModuleUnix.cpp:
* Shared/Plugins/unix/PluginSearchPath.cpp:
* Shared/WebMemorySampler.h:
* Shared/glib/ProcessExecutablePathGLib.cpp:
* Shared/ios/ChildProcessIOS.mm:
* Shared/mac/ChildProcessMac.mm:
* Shared/mac/SandboxExtensionMac.mm:
* UIProcess/API/APIContentRuleListStore.cpp:
* UIProcess/API/Cocoa/APIWebsiteDataStoreCocoa.mm:
* UIProcess/API/glib/APIWebsiteDataStoreGLib.cpp:
* UIProcess/API/glib/IconDatabase.cpp:
* UIProcess/API/glib/WebKitFaviconDatabase.cpp:
* UIProcess/API/glib/WebKitFileChooserRequest.cpp:
* UIProcess/API/glib/WebKitWebContext.cpp:
* UIProcess/API/glib/WebKitWebsiteDataManager.cpp:
* UIProcess/API/win/APIWebsiteDataStoreWin.cpp:
* UIProcess/Automation/WebAutomationSession.cpp:
* UIProcess/Cocoa/DownloadClient.mm:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
* UIProcess/Cocoa/WebViewImpl.mm:
* UIProcess/DeviceIdHashSaltStorage.cpp:
* UIProcess/Downloads/DownloadProxy.cpp:
* UIProcess/Launcher/glib/BubblewrapLauncher.cpp:
* UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:
* UIProcess/Plugins/gtk/PluginInfoCache.cpp:
* UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
* UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp:
* UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
* UIProcess/ServiceWorkerProcessProxy.cpp:
* UIProcess/WebStorage/LocalStorageDatabase.cpp:
* UIProcess/WebStorage/LocalStorageDatabaseTracker.cpp:
* UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
* UIProcess/glib/WebProcessProxyGLib.cpp:
* UIProcess/gtk/WebInspectorProxyGtk.cpp:
* UIProcess/gtk/WebProcessPoolGtk.cpp:
* UIProcess/ios/WKContentViewInteraction.mm:
* UIProcess/ios/forms/WKFileUploadPanel.mm:
* UIProcess/mac/WebPageProxyMac.mm:
* UIProcess/win/WebProcessPoolWin.cpp:
* UIProcess/win/WebView.cpp:
* UIProcess/wpe/WebProcessPoolWPE.cpp:
* WebProcess/InjectedBundle/API/glib/WebKitExtensionManager.cpp:
* WebProcess/InjectedBundle/glib/InjectedBundleGlib.cpp:
* WebProcess/MediaCache/WebMediaKeyStorageManager.cpp:
* WebProcess/Plugins/Netscape/NetscapePluginStream.h:
* WebProcess/Plugins/PluginProcessConnection.cpp:
* WebProcess/WebCoreSupport/SessionStateConversion.cpp:
* WebProcess/WebPage/gtk/WebInspectorUIGtk.cpp:
* WebProcess/WebPage/win/WebInspectorUIWin.cpp:
* WebProcess/cocoa/WebProcessCocoa.mm:

Source/WebKitLegacy:

* Storage/StorageAreaSync.cpp:
* Storage/StorageSyncManager.cpp:
* Storage/StorageTracker.cpp:

Source/WebKitLegacy/mac:

* Misc/WebNSFileManagerExtras.mm:
* Storage/WebDatabaseProvider.mm:
* WebView/WebView.mm:

Source/WebKitLegacy/win:

* Plugins/PluginDatabase.cpp:
* Plugins/PluginPackage.h:
* Plugins/PluginStream.h:
* WebApplicationCache.cpp:
* WebDatabaseManager.cpp:
* WebDownloadCurl.cpp:
* WebPreferences.cpp:
* WebView.cpp:

Source/WTF:

* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/FileMetadata.h: Renamed from Source/WebCore/platform/FileMetadata.h.
* wtf/FileSystem.cpp: Renamed from Source/WebCore/platform/FileSystem.cpp.
* wtf/FileSystem.h: Renamed from Source/WebCore/platform/FileSystem.h.
* wtf/PlatformGTK.cmake:
* wtf/PlatformMac.cmake:
* wtf/PlatformPlayStation.cmake:
* wtf/PlatformWPE.cmake:
* wtf/PlatformWin.cmake:
* wtf/cf/FileSystemCF.cpp: Renamed from Source/WebCore/platform/cf/FileSystemCF.cpp.
* wtf/cocoa/FileSystemCocoa.mm: Renamed from Source/WebCore/platform/cocoa/FileSystemCocoa.mm.
* wtf/glib/FileSystemGlib.cpp: Renamed from Source/WebCore/platform/glib/FileSystemGlib.cpp.
* wtf/mac/FileSystemMac.mm: Renamed from Source/WebCore/platform/mac/FileSystemMac.mm.
* wtf/posix/FileSystemPOSIX.cpp: Renamed from Source/WebCore/platform/posix/FileSystemPOSIX.cpp.
* wtf/spi/mac/MetadataSPI.h: Renamed from Source/WebCore/PAL/pal/spi/mac/MetadataSPI.h.
* wtf/win/FileSystemWin.cpp: Renamed from Source/WebCore/platform/win/FileSystemWin.cpp.
* wtf/win/PathWalker.cpp: Renamed from Source/WebCore/platform/win/PathWalker.cpp.
* wtf/win/PathWalker.h: Renamed from Source/WebCore/platform/win/PathWalker.h.

Tools:

* DumpRenderTree/win/DumpRenderTree.cpp:
* TestWebKitAPI/CMakeLists.txt:
* TestWebKitAPI/PlatformGTK.cmake:
* TestWebKitAPI/PlatformJSCOnly.cmake:
* TestWebKitAPI/PlatformPlayStation.cmake:
* TestWebKitAPI/PlatformWPE.cmake:
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WTF/FileSystem.cpp: Renamed from Tools/TestWebKitAPI/Tests/WebCore/FileSystem.cpp.
* TestWebKitAPI/Tests/WebCore/FileMonitor.cpp:
* TestWebKitAPI/Tests/WebCore/SecurityOrigin.cpp:
* TestWebKitAPI/Tests/WebCore/SharedBufferTest.cpp:
* TestWebKitAPI/Tests/WebCore/cocoa/DatabaseTrackerTest.mm:
* TestWebKitAPI/Tests/WebCore/curl/Cookies.cpp:
* TestWebKitAPI/Tests/WebKitCocoa/Download.mm:
* TestWebKitAPI/Tests/WebKitCocoa/DownloadProgress.mm:
* TestWebKitAPI/win/PlatformUtilitiesWin.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240437 268f45cc-cd09-0410-ab3c-d52691b4dbfc

200 files changed:
Source/WTF/ChangeLog
Source/WTF/WTF.xcodeproj/project.pbxproj
Source/WTF/wtf/CMakeLists.txt
Source/WTF/wtf/FileMetadata.h [moved from Source/WebCore/platform/FileMetadata.h with 96% similarity]
Source/WTF/wtf/FileSystem.cpp [moved from Source/WebCore/platform/FileSystem.cpp with 87% similarity]
Source/WTF/wtf/FileSystem.h [moved from Source/WebCore/platform/FileSystem.h with 55% similarity]
Source/WTF/wtf/PlatformGTK.cmake
Source/WTF/wtf/PlatformMac.cmake
Source/WTF/wtf/PlatformPlayStation.cmake
Source/WTF/wtf/PlatformWPE.cmake
Source/WTF/wtf/PlatformWin.cmake
Source/WTF/wtf/cf/FileSystemCF.cpp [moved from Source/WebCore/platform/cf/FileSystemCF.cpp with 97% similarity]
Source/WTF/wtf/cocoa/FileSystemCocoa.mm [moved from Source/WebCore/platform/cocoa/FileSystemCocoa.mm with 92% similarity]
Source/WTF/wtf/glib/FileSystemGlib.cpp [moved from Source/WebCore/platform/glib/FileSystemGlib.cpp with 98% similarity]
Source/WTF/wtf/mac/FileSystemMac.mm [moved from Source/WebCore/platform/mac/FileSystemMac.mm with 97% similarity]
Source/WTF/wtf/posix/FileSystemPOSIX.cpp [moved from Source/WebCore/platform/posix/FileSystemPOSIX.cpp with 97% similarity]
Source/WTF/wtf/spi/mac/MetadataSPI.h [moved from Source/WebCore/PAL/pal/spi/mac/MetadataSPI.h with 100% similarity]
Source/WTF/wtf/win/FileSystemWin.cpp [moved from Source/WebCore/platform/win/FileSystemWin.cpp with 98% similarity]
Source/WTF/wtf/win/PathWalker.cpp [moved from Source/WebCore/platform/win/PathWalker.cpp with 96% similarity]
Source/WTF/wtf/win/PathWalker.h [moved from Source/WebCore/platform/win/PathWalker.h with 97% similarity]
Source/WebCore/ChangeLog
Source/WebCore/Modules/encryptedmedia/CDM.cpp
Source/WebCore/Modules/encryptedmedia/legacy/WebKitMediaKeySession.cpp
Source/WebCore/Modules/entriesapi/DOMFileSystem.cpp
Source/WebCore/Modules/entriesapi/FileSystemEntry.cpp
Source/WebCore/Modules/indexeddb/IDBDatabaseIdentifier.cpp
Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp
Source/WebCore/Modules/indexeddb/server/SQLiteIDBTransaction.cpp
Source/WebCore/Modules/indexeddb/shared/InProcessIDBServer.cpp
Source/WebCore/Modules/webdatabase/DatabaseTracker.cpp
Source/WebCore/Modules/webdatabase/OriginLock.cpp
Source/WebCore/Modules/webdatabase/OriginLock.h
Source/WebCore/Modules/webdatabase/cocoa/DatabaseManagerCocoa.mm
Source/WebCore/PAL/ChangeLog
Source/WebCore/PAL/PAL.xcodeproj/project.pbxproj
Source/WebCore/PAL/pal/PlatformMac.cmake
Source/WebCore/PlatformMac.cmake
Source/WebCore/PlatformPlayStation.cmake
Source/WebCore/PlatformWin.cmake
Source/WebCore/Sources.txt
Source/WebCore/SourcesCocoa.txt
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/bindings/js/GCController.cpp
Source/WebCore/dom/DataTransferItem.cpp
Source/WebCore/editing/cocoa/WebContentReaderCocoa.mm
Source/WebCore/fileapi/File.cpp
Source/WebCore/fileapi/FileCocoa.mm
Source/WebCore/html/FileInputType.cpp
Source/WebCore/html/FileListCreator.cpp
Source/WebCore/loader/appcache/ApplicationCacheHost.cpp
Source/WebCore/loader/appcache/ApplicationCacheStorage.cpp
Source/WebCore/page/Page.cpp
Source/WebCore/page/SecurityOrigin.cpp
Source/WebCore/page/SecurityOriginData.cpp
Source/WebCore/platform/FileHandle.h
Source/WebCore/platform/FileStream.cpp
Source/WebCore/platform/FileStream.h
Source/WebCore/platform/SharedBuffer.h
Source/WebCore/platform/SourcesGLib.txt
Source/WebCore/platform/cocoa/FileMonitorCocoa.mm
Source/WebCore/platform/glib/FileMonitorGLib.cpp
Source/WebCore/platform/glib/SharedBufferGlib.cpp
Source/WebCore/platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm
Source/WebCore/platform/graphics/avfoundation/objc/CDMSessionAVStreamSession.mm
Source/WebCore/platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm
Source/WebCore/platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp
Source/WebCore/platform/ios/QuickLook.mm
Source/WebCore/platform/ios/WebItemProviderPasteboard.mm
Source/WebCore/platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm
Source/WebCore/platform/network/BlobDataFileReference.cpp
Source/WebCore/platform/network/BlobRegistryImpl.cpp
Source/WebCore/platform/network/BlobResourceHandle.cpp
Source/WebCore/platform/network/FormData.cpp
Source/WebCore/platform/network/cf/FormDataStreamCFNet.cpp
Source/WebCore/platform/network/cocoa/ResourceRequestCocoa.mm
Source/WebCore/platform/network/curl/CookieJarDB.cpp
Source/WebCore/platform/network/curl/CurlCacheEntry.h
Source/WebCore/platform/network/curl/CurlCacheManager.cpp
Source/WebCore/platform/network/curl/CurlFormDataStream.h
Source/WebCore/platform/network/curl/CurlRequest.h
Source/WebCore/platform/network/curl/NetworkStorageSessionCurl.cpp
Source/WebCore/platform/network/curl/ResourceHandleCurl.cpp
Source/WebCore/platform/network/mac/BlobDataFileReferenceMac.mm
Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp
Source/WebCore/platform/network/soup/SoupNetworkSession.cpp
Source/WebCore/platform/posix/SharedBufferPOSIX.cpp
Source/WebCore/platform/sql/SQLiteFileSystem.cpp
Source/WebCore/platform/text/hyphen/HyphenationLibHyphen.cpp
Source/WebCore/platform/win/SearchPopupMenuDB.cpp
Source/WebCore/rendering/RenderTheme.cpp
Source/WebCore/rendering/RenderThemeGtk.cpp
Source/WebCore/rendering/RenderThemeWin.cpp
Source/WebCore/workers/service/server/RegistrationDatabase.cpp
Source/WebKit/ChangeLog
Source/WebKit/NetworkProcess/Classifier/ResourceLoadStatisticsPersistentStorage.cpp
Source/WebKit/NetworkProcess/NetworkDataTaskBlob.h
Source/WebKit/NetworkProcess/NetworkProcess.cpp
Source/WebKit/NetworkProcess/cache/CacheStorageEngine.cpp
Source/WebKit/NetworkProcess/cache/CacheStorageEngineCaches.cpp
Source/WebKit/NetworkProcess/cache/NetworkCache.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheBlobStorage.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheData.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheFileSystem.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheFileSystem.h
Source/WebKit/NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm
Source/WebKit/NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheStatistics.cpp
Source/WebKit/NetworkProcess/cache/NetworkCacheStorage.cpp
Source/WebKit/NetworkProcess/cocoa/NetworkDataTaskCocoa.mm
Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm
Source/WebKit/NetworkProcess/mac/NetworkProcessMac.mm
Source/WebKit/NetworkProcess/soup/NetworkProcessSoup.cpp
Source/WebKit/PluginProcess/unix/PluginProcessMainUnix.cpp
Source/WebKit/Shared/PersistencyUtils.cpp
Source/WebKit/Shared/Plugins/Netscape/unix/NetscapePluginModuleUnix.cpp
Source/WebKit/Shared/Plugins/unix/PluginSearchPath.cpp
Source/WebKit/Shared/WebMemorySampler.h
Source/WebKit/Shared/glib/ProcessExecutablePathGLib.cpp
Source/WebKit/Shared/ios/ChildProcessIOS.mm
Source/WebKit/Shared/mac/ChildProcessMac.mm
Source/WebKit/Shared/mac/SandboxExtensionMac.mm
Source/WebKit/UIProcess/API/APIContentRuleListStore.cpp
Source/WebKit/UIProcess/API/Cocoa/APIWebsiteDataStoreCocoa.mm
Source/WebKit/UIProcess/API/glib/APIWebsiteDataStoreGLib.cpp
Source/WebKit/UIProcess/API/glib/IconDatabase.cpp
Source/WebKit/UIProcess/API/glib/WebKitFaviconDatabase.cpp
Source/WebKit/UIProcess/API/glib/WebKitFileChooserRequest.cpp
Source/WebKit/UIProcess/API/glib/WebKitWebContext.cpp
Source/WebKit/UIProcess/API/glib/WebKitWebsiteDataManager.cpp
Source/WebKit/UIProcess/API/win/APIWebsiteDataStoreWin.cpp
Source/WebKit/UIProcess/Automation/WebAutomationSession.cpp
Source/WebKit/UIProcess/Cocoa/DownloadClient.mm
Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm
Source/WebKit/UIProcess/Cocoa/WebViewImpl.mm
Source/WebKit/UIProcess/DeviceIdHashSaltStorage.cpp
Source/WebKit/UIProcess/Downloads/DownloadProxy.cpp
Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
Source/WebKit/UIProcess/Launcher/glib/ProcessLauncherGLib.cpp
Source/WebKit/UIProcess/Plugins/gtk/PluginInfoCache.cpp
Source/WebKit/UIProcess/Plugins/mac/PluginProcessProxyMac.mm
Source/WebKit/UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp
Source/WebKit/UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp
Source/WebKit/UIProcess/ServiceWorkerProcessProxy.cpp
Source/WebKit/UIProcess/WebStorage/LocalStorageDatabase.cpp
Source/WebKit/UIProcess/WebStorage/LocalStorageDatabaseTracker.cpp
Source/WebKit/UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm
Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
Source/WebKit/UIProcess/glib/WebProcessProxyGLib.cpp
Source/WebKit/UIProcess/gtk/WebInspectorProxyGtk.cpp
Source/WebKit/UIProcess/gtk/WebProcessPoolGtk.cpp
Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
Source/WebKit/UIProcess/ios/forms/WKFileUploadPanel.mm
Source/WebKit/UIProcess/mac/WebPageProxyMac.mm
Source/WebKit/UIProcess/win/WebProcessPoolWin.cpp
Source/WebKit/UIProcess/win/WebView.cpp
Source/WebKit/UIProcess/wpe/WebProcessPoolWPE.cpp
Source/WebKit/WebProcess/InjectedBundle/API/glib/WebKitExtensionManager.cpp
Source/WebKit/WebProcess/InjectedBundle/glib/InjectedBundleGlib.cpp
Source/WebKit/WebProcess/MediaCache/WebMediaKeyStorageManager.cpp
Source/WebKit/WebProcess/Plugins/Netscape/NetscapePluginStream.h
Source/WebKit/WebProcess/Plugins/PluginProcessConnection.cpp
Source/WebKit/WebProcess/WebCoreSupport/SessionStateConversion.cpp
Source/WebKit/WebProcess/WebPage/gtk/WebInspectorUIGtk.cpp
Source/WebKit/WebProcess/WebPage/win/WebInspectorUIWin.cpp
Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm
Source/WebKitLegacy/ChangeLog
Source/WebKitLegacy/Storage/StorageAreaSync.cpp
Source/WebKitLegacy/Storage/StorageSyncManager.cpp
Source/WebKitLegacy/Storage/StorageTracker.cpp
Source/WebKitLegacy/mac/ChangeLog
Source/WebKitLegacy/mac/Misc/WebNSFileManagerExtras.mm
Source/WebKitLegacy/mac/Storage/WebDatabaseProvider.mm
Source/WebKitLegacy/mac/WebView/WebView.mm
Source/WebKitLegacy/win/ChangeLog
Source/WebKitLegacy/win/Plugins/PluginDatabase.cpp
Source/WebKitLegacy/win/Plugins/PluginPackage.h
Source/WebKitLegacy/win/Plugins/PluginStream.h
Source/WebKitLegacy/win/WebApplicationCache.cpp
Source/WebKitLegacy/win/WebDatabaseManager.cpp
Source/WebKitLegacy/win/WebDownloadCurl.cpp
Source/WebKitLegacy/win/WebPreferences.cpp
Source/WebKitLegacy/win/WebView.cpp
Tools/ChangeLog
Tools/DumpRenderTree/win/DumpRenderTree.cpp
Tools/TestWebKitAPI/CMakeLists.txt
Tools/TestWebKitAPI/PlatformGTK.cmake
Tools/TestWebKitAPI/PlatformJSCOnly.cmake
Tools/TestWebKitAPI/PlatformPlayStation.cmake
Tools/TestWebKitAPI/PlatformWPE.cmake
Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
Tools/TestWebKitAPI/Tests/WTF/FileSystem.cpp [moved from Tools/TestWebKitAPI/Tests/WebCore/FileSystem.cpp with 98% similarity]
Tools/TestWebKitAPI/Tests/WebCore/FileMonitor.cpp
Tools/TestWebKitAPI/Tests/WebCore/SecurityOrigin.cpp
Tools/TestWebKitAPI/Tests/WebCore/SharedBufferTest.cpp
Tools/TestWebKitAPI/Tests/WebCore/cocoa/DatabaseTrackerTest.mm
Tools/TestWebKitAPI/Tests/WebCore/curl/Cookies.cpp
Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm
Tools/TestWebKitAPI/Tests/WebKitCocoa/DownloadProgress.mm
Tools/TestWebKitAPI/win/PlatformUtilitiesWin.cpp

index 84811fd..7884ca3 100644 (file)
@@ -1,3 +1,30 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * WTF.xcodeproj/project.pbxproj:
+        * wtf/CMakeLists.txt:
+        * wtf/FileMetadata.h: Renamed from Source/WebCore/platform/FileMetadata.h.
+        * wtf/FileSystem.cpp: Renamed from Source/WebCore/platform/FileSystem.cpp.
+        * wtf/FileSystem.h: Renamed from Source/WebCore/platform/FileSystem.h.
+        * wtf/PlatformGTK.cmake:
+        * wtf/PlatformMac.cmake:
+        * wtf/PlatformPlayStation.cmake:
+        * wtf/PlatformWPE.cmake:
+        * wtf/PlatformWin.cmake:
+        * wtf/cf/FileSystemCF.cpp: Renamed from Source/WebCore/platform/cf/FileSystemCF.cpp.
+        * wtf/cocoa/FileSystemCocoa.mm: Renamed from Source/WebCore/platform/cocoa/FileSystemCocoa.mm.
+        * wtf/glib/FileSystemGlib.cpp: Renamed from Source/WebCore/platform/glib/FileSystemGlib.cpp.
+        * wtf/mac/FileSystemMac.mm: Renamed from Source/WebCore/platform/mac/FileSystemMac.mm.
+        * wtf/posix/FileSystemPOSIX.cpp: Renamed from Source/WebCore/platform/posix/FileSystemPOSIX.cpp.
+        * wtf/spi/mac/MetadataSPI.h: Renamed from Source/WebCore/PAL/pal/spi/mac/MetadataSPI.h.
+        * wtf/win/FileSystemWin.cpp: Renamed from Source/WebCore/platform/win/FileSystemWin.cpp.
+        * wtf/win/PathWalker.cpp: Renamed from Source/WebCore/platform/win/PathWalker.cpp.
+        * wtf/win/PathWalker.h: Renamed from Source/WebCore/platform/win/PathWalker.h.
+
 2019-01-24  Guillaume Emont  <guijemont@igalia.com>
 
         [JSC] Reenable baseline JIT on mips
index a9629cf..d953b1b 100644 (file)
                93934BD518A1F16900D0D6A1 /* StringViewCF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 93934BD418A1F16900D0D6A1 /* StringViewCF.cpp */; };
                93F1993E19D7958D00C2390B /* StringView.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 93F1993D19D7958D00C2390B /* StringView.cpp */; };
                9BC70F05176C379D00101DEC /* AtomicStringTable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 9BC70F04176C379D00101DEC /* AtomicStringTable.cpp */; };
+               A331D95B21F24992009F02AA /* FileSystem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A331D95A21F24992009F02AA /* FileSystem.cpp */; };
+               A331D95D21F249E4009F02AA /* FileSystemCF.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A331D95C21F249E4009F02AA /* FileSystemCF.cpp */; };
+               A331D95F21F249F6009F02AA /* FileSystemCocoa.mm in Sources */ = {isa = PBXBuildFile; fileRef = A331D95E21F249F6009F02AA /* FileSystemCocoa.mm */; };
+               A331D96121F24A0A009F02AA /* FileSystemMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = A331D96021F24A0A009F02AA /* FileSystemMac.mm */; };
+               A331D96721F24ABD009F02AA /* FileSystemPOSIX.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A331D96621F24ABD009F02AA /* FileSystemPOSIX.cpp */; };
                A3B725EC987446AD93F1A440 /* RandomDevice.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C8F597CA2A57417FBAB92FD6 /* RandomDevice.cpp */; };
                A3E4DD931F3A803400DED0B4 /* TextStream.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A3E4DD911F3A803400DED0B4 /* TextStream.cpp */; };
                A5BA15F3182433A900A82E69 /* StringCocoa.mm in Sources */ = {isa = PBXBuildFile; fileRef = A5BA15F2182433A900A82E69 /* StringCocoa.mm */; };
                9C67C542589348E285B49699 /* IndexedContainerIterator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IndexedContainerIterator.h; sourceTree = "<group>"; };
                A30D412C1F0DE0BA00B71954 /* SoftLinking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SoftLinking.h; sourceTree = "<group>"; };
                A30D412D1F0DE13F00B71954 /* SoftLinking.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SoftLinking.h; sourceTree = "<group>"; };
+               A331D95821F24978009F02AA /* FileMetadata.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileMetadata.h; sourceTree = "<group>"; };
+               A331D95921F24992009F02AA /* FileSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileSystem.h; sourceTree = "<group>"; };
+               A331D95A21F24992009F02AA /* FileSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystem.cpp; sourceTree = "<group>"; };
+               A331D95C21F249E4009F02AA /* FileSystemCF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystemCF.cpp; sourceTree = "<group>"; };
+               A331D95E21F249F6009F02AA /* FileSystemCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemCocoa.mm; sourceTree = "<group>"; };
+               A331D96021F24A0A009F02AA /* FileSystemMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemMac.mm; sourceTree = "<group>"; };
+               A331D96621F24ABD009F02AA /* FileSystemPOSIX.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystemPOSIX.cpp; sourceTree = "<group>"; };
                A36E16F7216FF828008DD87E /* WTFSemaphore.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WTFSemaphore.h; sourceTree = "<group>"; };
                A3AB6E6A1F3E1AD6009C14B1 /* ValueToString.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ValueToString.h; sourceTree = "<group>"; };
+               A3D273B921F2EE9100866971 /* MetadataSPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MetadataSPI.h; sourceTree = "<group>"; };
                A3E4DD911F3A803400DED0B4 /* TextStream.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = TextStream.cpp; sourceTree = "<group>"; };
                A3E4DD921F3A803400DED0B4 /* TextStream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextStream.h; sourceTree = "<group>"; };
                A5098AFF1C169E0700087797 /* SandboxSPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SandboxSPI.h; sourceTree = "<group>"; };
                        children = (
                                5C1F05912164356B0039302C /* CFURLExtras.cpp */,
                                5C1F05922164356B0039302C /* CFURLExtras.h */,
+                               A331D95C21F249E4009F02AA /* FileSystemCF.cpp */,
                                C2BCFC411F61D61600C9222C /* LanguageCF.cpp */,
                                2CDED0EE18115C38004DBA70 /* RunLoopCF.cpp */,
                                1AFDE647195201C300C48FFA /* TypeCastsCF.h */,
                        name = Source;
                        sourceTree = "<group>";
                };
+               A331D96321F24A2E009F02AA /* posix */ = {
+                       isa = PBXGroup;
+                       children = (
+                               A331D96621F24ABD009F02AA /* FileSystemPOSIX.cpp */,
+                       );
+                       path = posix;
+                       sourceTree = "<group>";
+               };
+               A3D273B821F2EE7B00866971 /* mac */ = {
+                       isa = PBXGroup;
+                       children = (
+                               A3D273B921F2EE9100866971 /* MetadataSPI.h */,
+                       );
+                       path = mac;
+                       sourceTree = "<group>";
+               };
                A5BA15F11824339F00A82E69 /* cocoa */ = {
                        isa = PBXGroup;
                        children = (
                                1FA47C87152502DA00568D1B /* ios */,
                                A8A472C4151A825A004123FF /* mac */,
                                E43A46851E228B5700276B05 /* persistence */,
+                               A331D96321F24A2E009F02AA /* posix */,
                                CEF4820C19DA347600CC04B8 /* spi */,
                                A8A4731B151A825B004123FF /* text */,
                                A8A47339151A825B004123FF /* threads */,
                                A8A472A2151A825A004123FF /* FastMalloc.h */,
                                0F79C7C31E73511800EB34D1 /* FastTLS.h */,
                                B38FD7BC168953E80065C969 /* FeatureDefines.h */,
+                               A331D95821F24978009F02AA /* FileMetadata.h */,
                                0F9D335B165DBA73005AD387 /* FilePrintStream.cpp */,
                                0F9D335C165DBA73005AD387 /* FilePrintStream.h */,
+                               A331D95A21F24992009F02AA /* FileSystem.cpp */,
+                               A331D95921F24992009F02AA /* FileSystem.h */,
                                0F2B66A517B6B4F700A7AE3F /* FlipBytes.h */,
                                FE86A8741E59440200111BBF /* ForbidHeapAllocation.h */,
                                A8A472A6151A825A004123FF /* Forward.h */,
                        children = (
                                1A428B8B1C8F89DD0051E9EB /* AppKitCompatibilityDeclarations.h */,
                                1ACADD821884480100D8B71D /* DeprecatedSymbolsUsedBySafari.mm */,
+                               A331D96021F24A0A009F02AA /* FileSystemMac.mm */,
                                53534F291EC0E10E00141B2F /* MachExceptions.defs */,
                        );
                        path = mac;
                                DCEE21F91CEA752F000C2396 /* cf */,
                                CE46516C19DB1FB4003ECA05 /* cocoa */,
                                CE73E02319DCB7AB00580D5C /* darwin */,
+                               A3D273B821F2EE7B00866971 /* mac */,
                        );
                        path = spi;
                        sourceTree = "<group>";
                                E38C41241EB4E04C0042957D /* CPUTimeCocoa.cpp */,
                                143DDE9720C8BE99007F76FA /* Entitlements.h */,
                                143DDE9520C8BC37007F76FA /* Entitlements.mm */,
+                               A331D95E21F249F6009F02AA /* FileSystemCocoa.mm */,
                                7A6EBA3320746C34004F9C44 /* MachSendRight.cpp */,
                                A8A472C5151A825A004123FF /* MainThreadCocoa.mm */,
                                ADF2CE651E39F106006889DB /* MemoryFootprintCocoa.cpp */,
                                0F7C5FB61D885CF20044F5E2 /* FastBitVector.cpp in Sources */,
                                A8A473C3151A825B004123FF /* FastMalloc.cpp in Sources */,
                                0F9D3360165DBA73005AD387 /* FilePrintStream.cpp in Sources */,
+                               A331D95B21F24992009F02AA /* FileSystem.cpp in Sources */,
+                               A331D95D21F249E4009F02AA /* FileSystemCF.cpp in Sources */,
+                               A331D95F21F249F6009F02AA /* FileSystemCocoa.mm in Sources */,
+                               A331D96121F24A0A009F02AA /* FileSystemMac.mm in Sources */,
+                               A331D96721F24ABD009F02AA /* FileSystemPOSIX.cpp in Sources */,
                                A8A473B5151A825B004123FF /* fixed-dtoa.cc in Sources */,
                                1A1D8B9E1731879800141DA4 /* FunctionDispatcher.cpp in Sources */,
                                0F5BF1761F23D49A0029D91D /* Gigacage.cpp in Sources */,
index e34f75d..6bfbcf5 100644 (file)
@@ -61,7 +61,9 @@ set(WTF_PUBLIC_HEADERS
     FastMalloc.h
     FastTLS.h
     FeatureDefines.h
+    FileMetadata.h
     FilePrintStream.h
+    FileSystem.h
     FlipBytes.h
     ForbidHeapAllocation.h
     Forward.h
@@ -354,6 +356,7 @@ set(WTF_SOURCES
     FastBitVector.cpp
     FastMalloc.cpp
     FilePrintStream.cpp
+    FileSystem.cpp
     FunctionDispatcher.cpp
     Gigacage.cpp
     GlobalVersion.cpp
similarity index 96%
rename from Source/WebCore/platform/FileMetadata.h
rename to Source/WTF/wtf/FileMetadata.h
index 7d88495..0bb88fc 100644 (file)
@@ -32,7 +32,7 @@
 
 #include <wtf/WallTime.h>
 
-namespace WebCore {
+namespace WTF {
 
 struct FileMetadata {
     // The last modification time of the file, in seconds.
@@ -47,4 +47,6 @@ struct FileMetadata {
     Type type;
 };
 
-} // namespace WebCore
+} // namespace WTF
+
+using WTF::FileMetadata;
similarity index 87%
rename from Source/WebCore/platform/FileSystem.cpp
rename to Source/WTF/wtf/FileSystem.cpp
index ed9d37a..06dec7d 100644 (file)
@@ -25,9 +25,9 @@
  */
 
 #include "config.h"
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
-#include "FileMetadata.h"
+#include <wtf/FileMetadata.h>
 #include <wtf/HexNumber.h>
 #include <wtf/Scope.h>
 #include <wtf/text/CString.h>
@@ -40,9 +40,9 @@
 #include <unistd.h>
 #endif
 
-namespace WebCore {
+namespace WTF {
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 // The following lower-ASCII characters need escaping to be used in a filename
 // across all systems, including Windows:
@@ -61,29 +61,29 @@ namespace FileSystem {
 //     - Delete            (7F)
 
 static const bool needsEscaping[128] = {
-    /* 00-07 */ true,  true,  true,  true,  true,  true,  true,  true, 
-    /* 08-0F */ true,  true,  true,  true,  true,  true,  true,  true, 
-
-    /* 10-17 */ true,  true,  true,  true,  true,  true,  true,  true, 
-    /* 18-1F */ true,  true,  true,  true,  true,  true,  true,  true, 
-
-    /* 20-27 */ true,  false, true,  false, false, true,  false, false, 
-    /* 28-2F */ false, false, true,  false, false, false, false, true, 
-    
-    /* 30-37 */ false, false, false, false, false, false, false, false, 
-    /* 38-3F */ false, false, true,  false, true,  false, true,  true, 
-    
-    /* 40-47 */ false, false, false, false, false, false, false, false, 
-    /* 48-4F */ false, false, false, false, false, false, false, false,
-    
-    /* 50-57 */ false, false, false, false, false, false, false, false, 
-    /* 58-5F */ false, false, false, false, true,  false, false, false,
-    
-    /* 60-67 */ false, false, false, false, false, false, false, false, 
-    /* 68-6F */ false, false, false, false, false, false, false, false,
-    
-    /* 70-77 */ false, false, false, false, false, false, false, false, 
-    /* 78-7F */ false, false, false, false, true,  false, false, true, 
+    true,  true,  true,  true,  true,  true,  true,  true,  /* 00-07 */
+    true,  true,  true,  true,  true,  true,  true,  true,  /* 08-0F */
+
+    true,  true,  true,  true,  true,  true,  true,  true,  /* 10-17 */
+    true,  true,  true,  true,  true,  true,  true,  true,  /* 18-1F */
+
+    true,  false, true,  false, false, true,  false, false, /* 20-27 */
+    false, false, true,  false, false, false, false, true,  /* 28-2F */
+
+    false, false, false, false, false, false, false, false, /* 30-37 */
+    false, false, true,  false, true,  false, true,  true,  /* 38-3F */
+
+    false, false, false, false, false, false, false, false, /* 40-47 */
+    false, false, false, false, false, false, false, false, /* 48-4F */
+
+    false, false, false, false, false, false, false, false, /* 50-57 */
+    false, false, false, false, true,  false, false, false, /* 58-5F */
+
+    false, false, false, false, false, false, false, false, /* 60-67 */
+    false, false, false, false, false, false, false, false, /* 68-6F */
+
+    false, false, false, false, false, false, false, false, /* 70-77 */
+    false, false, false, false, true,  false, false, true,  /* 78-7F */
 };
 
 static inline bool shouldEscapeUChar(UChar character, UChar previousCharacter, UChar nextCharacter)
@@ -222,7 +222,7 @@ bool appendFileContentsToFileHandle(const String& path, PlatformFileHandle& targ
 
     do {
         int readBytes = readFromFile(source, buffer.data(), bufferSize);
-        
+
         if (readBytes < 0)
             return false;
 
@@ -236,12 +236,12 @@ bool appendFileContentsToFileHandle(const String& path, PlatformFileHandle& targ
     ASSERT_NOT_REACHED();
 }
 
-    
+
 bool filesHaveSameVolume(const String& fileA, const String& fileB)
 {
     auto fsRepFileA = fileSystemRepresentation(fileA);
     auto fsRepFileB = fileSystemRepresentation(fileB);
-    
+
     if (fsRepFileA.isNull() || fsRepFileB.isNull())
         return false;
 
@@ -252,7 +252,7 @@ bool filesHaveSameVolume(const String& fileA, const String& fileB)
 
     if (fileADev && fileBDev)
         result = (fileADev == fileBDev);
-    
+
     return result;
 }
 
@@ -363,5 +363,5 @@ bool fileIsDirectory(const String& path, ShouldFollowSymbolicLinks shouldFollowS
     return metadata.value().type == FileMetadata::Type::Directory;
 }
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
similarity index 55%
rename from Source/WebCore/platform/FileSystem.h
rename to Source/WTF/wtf/FileSystem.h
index 3cebcaa..95c3baf 100644 (file)
@@ -8,13 +8,13 @@
  * are met:
  *
  * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer. 
+ *     notice, this list of conditions and the following disclaimer.
  * 2.  Redistributions in binary form must reproduce the above copyright
  *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution. 
+ *     documentation and/or other materials provided with the distribution.
  * 3.  Neither the name of Apple Inc. ("Apple") nor the names of
  *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission. 
+ *     from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
@@ -56,11 +56,11 @@ typedef void *HANDLE;
 typedef struct _GFileIOStream GFileIOStream;
 #endif
 
-namespace WebCore {
+namespace WTF {
 
 struct FileMetadata;
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 // PlatformFileHandle
 #if USE(GLIB) && !PLATFORM(WIN)
@@ -69,7 +69,7 @@ const PlatformFileHandle invalidPlatformFileHandle = 0;
 #elif PLATFORM(WIN)
 typedef HANDLE PlatformFileHandle;
 // FIXME: -1 is INVALID_HANDLE_VALUE, defined in <winbase.h>. Chromium tries to
-// avoid using Windows headers in headers.  We'd rather move this into the .cpp.
+// avoid using Windows headers in headers. We'd rather move this into the .cpp.
 const PlatformFileHandle invalidPlatformFileHandle = reinterpret_cast<HANDLE>(-1);
 #else
 typedef int PlatformFileHandle;
@@ -98,75 +98,75 @@ enum class FileLockMode {
 
 enum class ShouldFollowSymbolicLinks { No, Yes };
 
-WEBCORE_EXPORT bool fileExists(const String&);
-WEBCORE_EXPORT bool deleteFile(const String&);
-WEBCORE_EXPORT bool deleteEmptyDirectory(const String&);
-WEBCORE_EXPORT bool moveFile(const String& oldPath, const String& newPath);
-WEBCORE_EXPORT bool getFileSize(const String&, long long& result);
-WEBCORE_EXPORT bool getFileSize(PlatformFileHandle, long long& result);
-WEBCORE_EXPORT Optional<WallTime> getFileModificationTime(const String&);
-WEBCORE_EXPORT Optional<WallTime> getFileCreationTime(const String&); // Not all platforms store file creation time.
-WEBCORE_EXPORT Optional<FileMetadata> fileMetadata(const String& path);
-WEBCORE_EXPORT Optional<FileMetadata> fileMetadataFollowingSymlinks(const String& path);
-WEBCORE_EXPORT bool fileIsDirectory(const String&, ShouldFollowSymbolicLinks);
-WEBCORE_EXPORT String pathByAppendingComponent(const String& path, const String& component);
-String pathByAppendingComponents(StringView path, const Vector<StringView>& components);
-String lastComponentOfPathIgnoringTrailingSlash(const String& path);
-WEBCORE_EXPORT bool makeAllDirectories(const String& path);
-String homeDirectoryPath();
-WEBCORE_EXPORT String pathGetFileName(const String&);
-WEBCORE_EXPORT String directoryName(const String&);
-WEBCORE_EXPORT bool getVolumeFreeSpace(const String&, uint64_t&);
-WEBCORE_EXPORT Optional<int32_t> getFileDeviceId(const CString&);
-WEBCORE_EXPORT bool createSymbolicLink(const String& targetPath, const String& symbolicLinkPath);
-
-WEBCORE_EXPORT void setMetadataURL(const String& path, const String& urlString, const String& referrer = { });
+WTF_EXPORT_PRIVATE bool fileExists(const String&);
+WTF_EXPORT_PRIVATE bool deleteFile(const String&);
+WTF_EXPORT_PRIVATE bool deleteEmptyDirectory(const String&);
+WTF_EXPORT_PRIVATE bool moveFile(const String& oldPath, const String& newPath);
+WTF_EXPORT_PRIVATE bool getFileSize(const String&, long long& result);
+WTF_EXPORT_PRIVATE bool getFileSize(PlatformFileHandle, long long& result);
+WTF_EXPORT_PRIVATE Optional<WallTime> getFileModificationTime(const String&);
+WTF_EXPORT_PRIVATE Optional<WallTime> getFileCreationTime(const String&); // Not all platforms store file creation time.
+WTF_EXPORT_PRIVATE Optional<FileMetadata> fileMetadata(const String& path);
+WTF_EXPORT_PRIVATE Optional<FileMetadata> fileMetadataFollowingSymlinks(const String& path);
+WTF_EXPORT_PRIVATE bool fileIsDirectory(const String&, ShouldFollowSymbolicLinks);
+WTF_EXPORT_PRIVATE String pathByAppendingComponent(const String& path, const String& component);
+WTF_EXPORT_PRIVATE String pathByAppendingComponents(StringView path, const Vector<StringView>& components);
+WTF_EXPORT_PRIVATE String lastComponentOfPathIgnoringTrailingSlash(const String& path);
+WTF_EXPORT_PRIVATE bool makeAllDirectories(const String& path);
+WTF_EXPORT_PRIVATE String homeDirectoryPath();
+WTF_EXPORT_PRIVATE String pathGetFileName(const String&);
+WTF_EXPORT_PRIVATE String directoryName(const String&);
+WTF_EXPORT_PRIVATE bool getVolumeFreeSpace(const String&, uint64_t&);
+WTF_EXPORT_PRIVATE Optional<int32_t> getFileDeviceId(const CString&);
+WTF_EXPORT_PRIVATE bool createSymbolicLink(const String& targetPath, const String& symbolicLinkPath);
+
+WTF_EXPORT_PRIVATE void setMetadataURL(const String& path, const String& urlString, const String& referrer = { });
 
 bool canExcludeFromBackup(); // Returns true if any file can ever be excluded from backup.
 bool excludeFromBackup(const String&); // Returns true if successful.
 
-WEBCORE_EXPORT Vector<String> listDirectory(const String& path, const String& filter = String());
+WTF_EXPORT_PRIVATE Vector<String> listDirectory(const String& path, const String& filter = String());
 
-WEBCORE_EXPORT CString fileSystemRepresentation(const String&);
+WTF_EXPORT_PRIVATE CString fileSystemRepresentation(const String&);
 String stringFromFileSystemRepresentation(const char*);
 
 inline bool isHandleValid(const PlatformFileHandle& handle) { return handle != invalidPlatformFileHandle; }
 
 // Prefix is what the filename should be prefixed with, not the full path.
-WEBCORE_EXPORT String openTemporaryFile(const String& prefix, PlatformFileHandle&);
-WEBCORE_EXPORT PlatformFileHandle openFile(const String& path, FileOpenMode);
-WEBCORE_EXPORT void closeFile(PlatformFileHandle&);
+WTF_EXPORT_PRIVATE String openTemporaryFile(const String& prefix, PlatformFileHandle&);
+WTF_EXPORT_PRIVATE PlatformFileHandle openFile(const String& path, FileOpenMode);
+WTF_EXPORT_PRIVATE void closeFile(PlatformFileHandle&);
 // Returns the resulting offset from the beginning of the file if successful, -1 otherwise.
-WEBCORE_EXPORT long long seekFile(PlatformFileHandle, long long offset, FileSeekOrigin);
+WTF_EXPORT_PRIVATE long long seekFile(PlatformFileHandle, long long offset, FileSeekOrigin);
 bool truncateFile(PlatformFileHandle, long long offset);
 // Returns number of bytes actually read if successful, -1 otherwise.
-WEBCORE_EXPORT int writeToFile(PlatformFileHandle, const char* data, int length);
+WTF_EXPORT_PRIVATE int writeToFile(PlatformFileHandle, const char* data, int length);
 // Returns number of bytes actually written if successful, -1 otherwise.
-WEBCORE_EXPORT int readFromFile(PlatformFileHandle, char* data, int length);
+WTF_EXPORT_PRIVATE int readFromFile(PlatformFileHandle, char* data, int length);
 
-WEBCORE_EXPORT PlatformFileHandle openAndLockFile(const String&, FileOpenMode, OptionSet<FileLockMode> = FileLockMode::Exclusive);
-WEBCORE_EXPORT void unlockAndCloseFile(PlatformFileHandle);
+WTF_EXPORT_PRIVATE PlatformFileHandle openAndLockFile(const String&, FileOpenMode, OptionSet<FileLockMode> = FileLockMode::Exclusive);
+WTF_EXPORT_PRIVATE void unlockAndCloseFile(PlatformFileHandle);
 
 // Appends the contents of the file found at 'path' to the open PlatformFileHandle.
 // Returns true if the write was successful, false if it was not.
-bool appendFileContentsToFileHandle(const String& path, PlatformFileHandle&);
+WTF_EXPORT_PRIVATE bool appendFileContentsToFileHandle(const String& path, PlatformFileHandle&);
 
 // Hard links a file if possible, copies it if not.
-bool hardLinkOrCopyFile(const String& source, const String& destination);
+WTF_EXPORT_PRIVATE bool hardLinkOrCopyFile(const String& source, const String& destination);
 
 #if USE(FILE_LOCK)
-WEBCORE_EXPORT bool lockFile(PlatformFileHandle, OptionSet<FileLockMode>);
-WEBCORE_EXPORT bool unlockFile(PlatformFileHandle);
+WTF_EXPORT_PRIVATE bool lockFile(PlatformFileHandle, OptionSet<FileLockMode>);
+WTF_EXPORT_PRIVATE bool unlockFile(PlatformFileHandle);
 #endif
 
 // Encode a string for use within a file name.
-WEBCORE_EXPORT String encodeForFileName(const String&);
-WEBCORE_EXPORT String decodeFromFilename(const String&);
+WTF_EXPORT_PRIVATE String encodeForFileName(const String&);
+WTF_EXPORT_PRIVATE String decodeFromFilename(const String&);
 
-WEBCORE_EXPORT bool filesHaveSameVolume(const String&, const String&);
+WTF_EXPORT_PRIVATE bool filesHaveSameVolume(const String&, const String&);
 
 #if USE(CF)
-RetainPtr<CFURLRef> pathAsURL(const String&);
+WTF_EXPORT_PRIVATE RetainPtr<CFURLRef> pathAsURL(const String&);
 #endif
 
 #if PLATFORM(GTK) || PLATFORM(WPE)
@@ -174,28 +174,28 @@ String filenameForDisplay(const String&);
 #endif
 
 #if PLATFORM(WIN)
-WEBCORE_EXPORT String localUserSpecificStorageDirectory();
-String roamingUserSpecificStorageDirectory();
+WTF_EXPORT_PRIVATE String localUserSpecificStorageDirectory();
+WTF_EXPORT_PRIVATE String roamingUserSpecificStorageDirectory();
 #endif
 
 #if PLATFORM(COCOA)
-WEBCORE_EXPORT NSString *createTemporaryDirectory(NSString *directoryPrefix);
-WEBCORE_EXPORT bool deleteNonEmptyDirectory(const String&);
+WTF_EXPORT_PRIVATE NSString *createTemporaryDirectory(NSString *directoryPrefix);
+WTF_EXPORT_PRIVATE bool deleteNonEmptyDirectory(const String&);
 #endif
 
 #if PLATFORM(WIN_CAIRO)
-WEBCORE_EXPORT String createTemporaryDirectory();
-WEBCORE_EXPORT bool deleteNonEmptyDirectory(const String&);
+WTF_EXPORT_PRIVATE String createTemporaryDirectory();
+WTF_EXPORT_PRIVATE bool deleteNonEmptyDirectory(const String&);
 #endif
 
-WEBCORE_EXPORT String realPath(const String&);
+WTF_EXPORT_PRIVATE String realPath(const String&);
 
 class MappedFileData {
 public:
     MappedFileData() { }
     MappedFileData(MappedFileData&&);
-    WEBCORE_EXPORT MappedFileData(const String& filePath, bool& success);
-    WEBCORE_EXPORT ~MappedFileData();
+    WTF_EXPORT_PRIVATE MappedFileData(const String& filePath, bool& success);
+    WTF_EXPORT_PRIVATE ~MappedFileData();
     MappedFileData& operator=(MappedFileData&&);
 
     explicit operator bool() const { return !!m_fileData; }
@@ -220,6 +220,7 @@ inline MappedFileData& MappedFileData::operator=(MappedFileData&& other)
     return *this;
 }
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
 
+namespace FileSystem = WTF::FileSystemImpl;
index 673f02d..7fec12d 100644 (file)
@@ -22,6 +22,7 @@ list(APPEND WTF_SOURCES
     generic/MainThreadGeneric.cpp
     generic/WorkQueueGeneric.cpp
 
+    glib/FileSystemGlib.cpp
     glib/GLibUtilities.cpp
     glib/GRefPtr.cpp
     glib/RunLoopGLib.cpp
@@ -55,5 +56,6 @@ list(APPEND WTF_LIBRARIES
 )
 
 list(APPEND WTF_SYSTEM_INCLUDE_DIRECTORIES
+    ${GIO_UNIX_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
 )
index fc1e57b..0e3e141 100644 (file)
@@ -32,6 +32,8 @@ list(APPEND WTF_PUBLIC_HEADERS
     spi/darwin/XPCSPI.h
     spi/darwin/dyldSPI.h
 
+    spi/mac/MetadataSPI.h
+
     text/cf/TextBreakIteratorCF.h
 )
 
@@ -42,6 +44,7 @@ list(APPEND WTF_SOURCES
     SchedulePairMac.mm
 
     cf/CFURLExtras.cpp
+    cf/FileSystemCF.cpp
     cf/LanguageCF.cpp
     cf/RunLoopCF.cpp
     cf/URLCF.cpp
@@ -49,6 +52,7 @@ list(APPEND WTF_SOURCES
     cocoa/AutodrainedPool.cpp
     cocoa/CPUTimeCocoa.cpp
     cocoa/Entitlements.mm
+    cocoa/FileSystemCocoa.mm
     cocoa/MachSendRight.cpp
     cocoa/MainThreadCocoa.mm
     cocoa/MemoryFootprintCocoa.cpp
@@ -58,6 +62,9 @@ list(APPEND WTF_SOURCES
     cocoa/WorkQueueCocoa.cpp
 
     mac/DeprecatedSymbolsUsedBySafari.mm
+    mac/FileSystemMac.mm
+
+    posix/FileSystemPOSIX.cpp
 
     text/cf/AtomicStringImplCF.cpp
     text/cf/StringCF.cpp
index b97fec4..3e9e75c 100644 (file)
@@ -5,6 +5,8 @@ list(APPEND WTF_SOURCES
     generic/RunLoopGeneric.cpp
     generic/WorkQueueGeneric.cpp
 
+    posix/FileSystemPOSIX.cpp
+
     text/unix/TextBreakIteratorInternalICUUnix.cpp
 
     unix/CPUTimeUnix.cpp
index 473cfd6..086add3 100644 (file)
@@ -16,6 +16,7 @@ list(APPEND WTF_SOURCES
     generic/MainThreadGeneric.cpp
     generic/WorkQueueGeneric.cpp
 
+    glib/FileSystemGlib.cpp
     glib/GLibUtilities.cpp
     glib/GRefPtr.cpp
     glib/RunLoopGLib.cpp
@@ -40,5 +41,6 @@ list(APPEND WTF_LIBRARIES
 )
 
 list(APPEND WTF_SYSTEM_INCLUDE_DIRECTORIES
+    ${GIO_UNIX_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
 )
index 2b8b5f8..b6c0ac6 100644 (file)
@@ -12,14 +12,20 @@ list(APPEND WTF_SOURCES
 
     win/CPUTimeWin.cpp
     win/DbgHelperWin.cpp
+    win/FileSystemWin.cpp
     win/LanguageWin.cpp
     win/MainThreadWin.cpp
     win/MemoryFootprintWin.cpp
     win/MemoryPressureHandlerWin.cpp
+    win/PathWalker.cpp
     win/RunLoopWin.cpp
     win/WorkQueueWin.cpp
 )
 
+list(APPEND WTF_LIBRARIES
+    shlwapi
+)
+
 if (USE_CF)
     list(APPEND WTF_PUBLIC_HEADERS
         cf/CFURLExtras.h
@@ -29,6 +35,7 @@ if (USE_CF)
     )
     list(APPEND WTF_SOURCES
         cf/CFURLExtras.cpp
+        cf/FileSystemCF.cpp
         cf/URLCF.cpp
 
         text/cf/AtomicStringImplCF.cpp
similarity index 97%
rename from Source/WebCore/platform/cf/FileSystemCF.cpp
rename to Source/WTF/wtf/cf/FileSystemCF.cpp
index 08470a0..712d65f 100644 (file)
  */
 
 #include "config.h"
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
 #include <CoreFoundation/CFString.h>
 #include <wtf/RetainPtr.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/WTFString.h>
 
-namespace WebCore {
+namespace WTF {
 
 CString FileSystem::fileSystemRepresentation(const String& path)
 {
@@ -71,4 +71,4 @@ RetainPtr<CFURLRef> FileSystem::pathAsURL(const String& path)
     return adoptCF(CFURLCreateWithFileSystemPath(0, path.createCFString().get(), pathStyle, FALSE));
 }
 
-} // namespace WebCore
+} // namespace WTF
similarity index 92%
rename from Source/WebCore/platform/cocoa/FileSystemCocoa.mm
rename to Source/WTF/wtf/cocoa/FileSystemCocoa.mm
index d38b0c8..e122200 100644 (file)
@@ -6,13 +6,13 @@
  * are met:
  *
  * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer. 
+ *     notice, this list of conditions and the following disclaimer.
  * 2.  Redistributions in binary form must reproduce the above copyright
  *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution. 
+ *     documentation and/or other materials provided with the distribution.
  * 3.  Neither the name of Apple Inc. ("Apple") nor the names of
  *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission. 
+ *     from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  */
 
 #import "config.h"
-#import "FileSystem.h"
+#import <wtf/FileSystem.h>
 
-@interface WebFileManagerDelegate : NSObject <NSFileManagerDelegate>
+@interface WTFWebFileManagerDelegate : NSObject <NSFileManagerDelegate>
 @end
 
-@implementation WebFileManagerDelegate
+@implementation WTFWebFileManagerDelegate
 
 - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error movingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL
 {
     UNUSED_PARAM(fileManager);
     UNUSED_PARAM(srcURL);
-    UNUSED_PARAM(dstURL);    
+    UNUSED_PARAM(dstURL);
     return error.code == NSFileWriteFileExistsError;
 }
 
 @end
 
-namespace WebCore {
+namespace WTF {
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 String homeDirectoryPath()
 {
@@ -56,12 +56,12 @@ String homeDirectoryPath()
 String openTemporaryFile(const String& prefix, PlatformFileHandle& platformFileHandle)
 {
     platformFileHandle = invalidPlatformFileHandle;
-    
+
     Vector<char> temporaryFilePath(PATH_MAX);
     if (!confstr(_CS_DARWIN_USER_TEMP_DIR, temporaryFilePath.data(), temporaryFilePath.size()))
         return String();
 
-    // Shrink the vector.   
+    // Shrink the vector.
     temporaryFilePath.shrink(strlen(temporaryFilePath.data()));
 
     // FIXME: Change to a runtime assertion that the path ends with a slash once <rdar://problem/23579077> is
@@ -86,9 +86,9 @@ bool moveFile(const String& oldPath, const String& newPath)
 {
     // Overwrite existing files.
     auto manager = adoptNS([[NSFileManager alloc] init]);
-    auto delegate = adoptNS([[WebFileManagerDelegate alloc] init]);
+    auto delegate = adoptNS([[WTFWebFileManagerDelegate alloc] init]);
     [manager setDelegate:delegate.get()];
-    
+
     NSError *error = nil;
     bool success = [manager moveItemAtURL:[NSURL fileURLWithPath:oldPath] toURL:[NSURL fileURLWithPath:newPath] error:&error];
     if (!success)
@@ -139,5 +139,5 @@ bool deleteNonEmptyDirectory(const String& path)
     return [[NSFileManager defaultManager] removeItemAtPath:path error:nil];
 }
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
similarity index 98%
rename from Source/WebCore/platform/glib/FileSystemGlib.cpp
rename to Source/WTF/wtf/glib/FileSystemGlib.cpp
index ca6c3df..c3ec99a 100644 (file)
  */
 
 #include "config.h"
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
-#include "FileMetadata.h"
-#include "NotImplemented.h"
 #include <gio/gfiledescriptorbased.h>
 #include <gio/gio.h>
 #include <glib.h>
 #include <glib/gstdio.h>
 #include <sys/file.h>
 #include <wtf/EnumTraits.h>
+#include <wtf/FileMetadata.h>
 #include <wtf/UUID.h>
 #include <wtf/glib/GLibUtilities.h>
 #include <wtf/glib/GRefPtr.h>
@@ -39,9 +38,9 @@
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/WTFString.h>
 
-namespace WebCore {
+namespace WTF {
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 /* On linux file names are just raw bytes, so also strings that cannot be encoded in any way
  * are valid file names. This mean that we cannot just store a file name as-is in a String
@@ -466,5 +465,5 @@ bool unlockFile(PlatformFileHandle handle)
 }
 #endif // USE(FILE_LOCK)
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
similarity index 97%
rename from Source/WebCore/platform/mac/FileSystemMac.mm
rename to Source/WTF/wtf/mac/FileSystemMac.mm
index 8ed751a..92692a1 100644 (file)
  */
 
 #import "config.h"
-#import "FileSystem.h"
+#import <wtf/FileSystem.h>
 
 #if PLATFORM(MAC)
 
-#import <pal/spi/mac/MetadataSPI.h>
 #import <wtf/cocoa/NSURLExtras.h>
+#import <wtf/spi/mac/MetadataSPI.h>
 #import <wtf/text/WTFString.h>
 
-namespace WebCore {
+namespace WTF {
 
 bool FileSystem::deleteEmptyDirectory(const String& path)
 {
@@ -83,6 +83,6 @@ bool FileSystem::excludeFromBackup(const String& path)
     return true;
 }
 
-} // namespace WebCore
+} // namespace WTF
 
 #endif // PLATFORM(MAC)
similarity index 97%
rename from Source/WebCore/platform/posix/FileSystemPOSIX.cpp
rename to Source/WTF/wtf/posix/FileSystemPOSIX.cpp
index 9485135..fb1efd6 100644 (file)
@@ -27,9 +27,8 @@
  */
 
 #include "config.h"
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
-#include "FileMetadata.h"
 #include <dirent.h>
 #include <errno.h>
 #include <fcntl.h>
 #include <sys/types.h>
 #include <unistd.h>
 #include <wtf/EnumTraits.h>
+#include <wtf/FileMetadata.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/WTFString.h>
 
-namespace WebCore {
+namespace WTF {
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 bool fileExists(const String& path)
 {
@@ -317,19 +317,22 @@ bool makeAllDirectories(const String& path)
     char* p = fullPath.mutableData() + 1;
     int length = fullPath.length();
 
-    if(p[length - 1] == '/')
+    if (p[length - 1] == '/')
         p[length - 1] = '\0';
-    for (; *p; ++p)
+    for (; *p; ++p) {
         if (*p == '/') {
             *p = '\0';
-            if (access(fullPath.data(), F_OK))
+            if (access(fullPath.data(), F_OK)) {
                 if (mkdir(fullPath.data(), S_IRWXU))
                     return false;
+            }
             *p = '/';
         }
-    if (access(fullPath.data(), F_OK))
+    }
+    if (access(fullPath.data(), F_OK)) {
         if (mkdir(fullPath.data(), S_IRWXU))
             return false;
+    }
 
     return true;
 }
@@ -489,5 +492,5 @@ String realPath(const String& filePath)
     return result ? String::fromUTF8(result) : filePath;
 }
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
similarity index 98%
rename from Source/WebCore/platform/win/FileSystemWin.cpp
rename to Source/WTF/wtf/win/FileSystemWin.cpp
index bb702cb..00e3352 100644 (file)
@@ -7,13 +7,13 @@
  * are met:
  *
  * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer. 
+ *     notice, this list of conditions and the following disclaimer.
  * 2.  Redistributions in binary form must reproduce the above copyright
  *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution. 
+ *     documentation and/or other materials provided with the distribution.
  * 3.  Neither the name of Apple Inc. ("Apple") nor the names of
  *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission. 
+ *     from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  */
 
 #include "config.h"
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
-#include "FileMetadata.h"
-#include "NotImplemented.h"
-#include "PathWalker.h"
 #include <io.h>
 #include <shlobj.h>
 #include <shlwapi.h>
 #include <sys/stat.h>
 #include <windows.h>
 #include <wtf/CryptographicallyRandomNumber.h>
+#include <wtf/FileMetadata.h>
 #include <wtf/HashMap.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/win/WCharStringExtras.h>
+#include <wtf/win/PathWalker.h>
 
-namespace WebCore {
+namespace WTF {
 
-namespace FileSystem {
+namespace FileSystemImpl {
 
 static const ULONGLONG kSecondsFromFileTimeToTimet = 11644473600;
 
@@ -310,7 +309,6 @@ bool makeAllDirectories(const String& path)
 
 String homeDirectoryPath()
 {
-    notImplemented();
     return "";
 }
 
@@ -537,7 +535,6 @@ Vector<String> listDirectory(const String& directory, const String& filter)
 
 bool getVolumeFreeSpace(const String&, uint64_t&)
 {
-    notImplemented();
     return false;
 }
 
@@ -585,5 +582,5 @@ bool deleteNonEmptyDirectory(const String& directoryPath)
     return !SHFileOperation(&deleteOperation);
 }
 
-} // namespace FileSystem
-} // namespace WebCore
+} // namespace FileSystemImpl
+} // namespace WTF
similarity index 96%
rename from Source/WebCore/platform/win/PathWalker.cpp
rename to Source/WTF/wtf/win/PathWalker.cpp
index f20407b..c6d3f97 100644 (file)
  */
 
 #include "config.h"
-#include "PathWalker.h"
+#include <wtf/win/PathWalker.h>
 
 #include <wtf/text/WTFString.h>
 #include <wtf/text/win/WCharStringExtras.h>
 
-namespace WebCore {
+namespace WTF {
 
 PathWalker::PathWalker(const String& directory, const String& pattern)
 {
@@ -49,4 +49,4 @@ bool PathWalker::step()
     return ::FindNextFileW(m_handle, &m_data);
 }
 
-} // namespace WebCore
+} // namespace WTF
similarity index 97%
rename from Source/WebCore/platform/win/PathWalker.h
rename to Source/WTF/wtf/win/PathWalker.h
index fc59d67..953ae2e 100644 (file)
@@ -27,7 +27,7 @@
 #include <wtf/Forward.h>
 #include <wtf/Noncopyable.h>
 
-namespace WebCore {
+namespace WTF {
 
 class PathWalker {
     WTF_MAKE_NONCOPYABLE(PathWalker);
@@ -45,4 +45,4 @@ private:
     WIN32_FIND_DATAW m_data;
 };
 
-} // namespace WebCore
+} // namespace WTF
index 674fa72..c2ba43f 100644 (file)
@@ -1,3 +1,81 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * Modules/encryptedmedia/CDM.cpp:
+        * Modules/encryptedmedia/legacy/WebKitMediaKeySession.cpp:
+        * Modules/entriesapi/DOMFileSystem.cpp:
+        * Modules/entriesapi/FileSystemEntry.cpp:
+        * Modules/indexeddb/IDBDatabaseIdentifier.cpp:
+        * Modules/indexeddb/server/SQLiteIDBBackingStore.cpp:
+        * Modules/indexeddb/server/SQLiteIDBTransaction.cpp:
+        * Modules/indexeddb/shared/InProcessIDBServer.cpp:
+        * Modules/webdatabase/DatabaseTracker.cpp:
+        * Modules/webdatabase/OriginLock.cpp:
+        * Modules/webdatabase/OriginLock.h:
+        * Modules/webdatabase/cocoa/DatabaseManagerCocoa.mm:
+        * PlatformMac.cmake:
+        * PlatformPlayStation.cmake:
+        * PlatformWin.cmake:
+        * Sources.txt:
+        * SourcesCocoa.txt:
+        * WebCore.xcodeproj/project.pbxproj:
+        * bindings/js/GCController.cpp:
+        * dom/DataTransferItem.cpp:
+        * editing/cocoa/WebContentReaderCocoa.mm:
+        * fileapi/File.cpp:
+        * fileapi/FileCocoa.mm:
+        * html/FileInputType.cpp:
+        * html/FileListCreator.cpp:
+        * loader/appcache/ApplicationCacheHost.cpp:
+        * loader/appcache/ApplicationCacheStorage.cpp:
+        * page/Page.cpp:
+        * page/SecurityOrigin.cpp:
+        * page/SecurityOriginData.cpp:
+        * platform/FileHandle.h:
+        * platform/FileStream.cpp:
+        * platform/FileStream.h:
+        * platform/SharedBuffer.h:
+        * platform/SourcesGLib.txt:
+        * platform/cocoa/FileMonitorCocoa.mm:
+        * platform/glib/FileMonitorGLib.cpp:
+        * platform/glib/SharedBufferGlib.cpp:
+        * platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm:
+        * platform/graphics/avfoundation/objc/CDMSessionAVStreamSession.mm:
+        * platform/graphics/avfoundation/objc/CDMSessionMediaSourceAVFObjC.mm:
+        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
+        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
+        * platform/ios/QuickLook.mm:
+        * platform/ios/WebItemProviderPasteboard.mm:
+        * platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:
+        * platform/network/BlobDataFileReference.cpp:
+        * platform/network/BlobRegistryImpl.cpp:
+        * platform/network/BlobResourceHandle.cpp:
+        * platform/network/FormData.cpp:
+        * platform/network/cf/FormDataStreamCFNet.cpp:
+        * platform/network/cocoa/ResourceRequestCocoa.mm:
+        * platform/network/curl/CookieJarDB.cpp:
+        * platform/network/curl/CurlCacheEntry.h:
+        * platform/network/curl/CurlCacheManager.cpp:
+        * platform/network/curl/CurlFormDataStream.h:
+        * platform/network/curl/CurlRequest.h:
+        * platform/network/curl/NetworkStorageSessionCurl.cpp:
+        * platform/network/curl/ResourceHandleCurl.cpp:
+        * platform/network/mac/BlobDataFileReferenceMac.mm:
+        * platform/network/soup/ResourceHandleSoup.cpp:
+        * platform/network/soup/SoupNetworkSession.cpp:
+        * platform/posix/SharedBufferPOSIX.cpp:
+        * platform/sql/SQLiteFileSystem.cpp:
+        * platform/text/hyphen/HyphenationLibHyphen.cpp:
+        * platform/win/SearchPopupMenuDB.cpp:
+        * rendering/RenderTheme.cpp:
+        * rendering/RenderThemeGtk.cpp:
+        * rendering/RenderThemeWin.cpp:
+        * workers/service/server/RegistrationDatabase.cpp:
+
 2019-01-24  Zalan Bujtas  <zalan@apple.com>
 
         [LFC][BFC][MarginCollapsing] MarginCollapse::collapsedVerticalValues should not return computed non-collapsed values.
index 4fe250b..ebf067f 100644 (file)
@@ -31,7 +31,6 @@
 #include "CDMFactory.h"
 #include "CDMPrivate.h"
 #include "Document.h"
-#include "FileSystem.h"
 #include "InitDataRegistry.h"
 #include "MediaKeysRequirement.h"
 #include "MediaPlayer.h"
@@ -42,6 +41,7 @@
 #include "SecurityOrigin.h"
 #include "SecurityOriginData.h"
 #include "Settings.h"
+#include <wtf/FileSystem.h>
 #include <wtf/NeverDestroyed.h>
 
 namespace WebCore {
index e666ce9..65edda1 100644 (file)
 
 #include "Document.h"
 #include "EventNames.h"
-#include "FileSystem.h"
 #include "Page.h"
 #include "SecurityOriginData.h"
 #include "Settings.h"
 #include "WebKitMediaKeyError.h"
 #include "WebKitMediaKeyMessageEvent.h"
 #include "WebKitMediaKeys.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 6dd4171..368794e 100644 (file)
 #include "DOMFileSystem.h"
 
 #include "File.h"
-#include "FileMetadata.h"
-#include "FileSystem.h"
 #include "FileSystemDirectoryEntry.h"
 #include "FileSystemFileEntry.h"
 #include "ScriptExecutionContext.h"
 #include <wtf/CrossThreadCopier.h>
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 #include <wtf/UUID.h>
 #include <wtf/text/StringBuilder.h>
 
index dccb5a1..424cca2 100644 (file)
 #include "DOMException.h"
 #include "DOMFileSystem.h"
 #include "ErrorCallback.h"
-#include "FileSystem.h"
 #include "FileSystemDirectoryEntry.h"
 #include "FileSystemEntryCallback.h"
 #include "ScriptExecutionContext.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index c7fdfd0..b429b3f 100644 (file)
@@ -28,8 +28,8 @@
 
 #if ENABLE(INDEXED_DATABASE)
 
-#include "FileSystem.h"
 #include "SecurityOrigin.h"
+#include <wtf/FileSystem.h>
 #include <wtf/Ref.h>
 #include <wtf/text/WTFString.h>
 
index 2178cc4..285d502 100644 (file)
@@ -28,7 +28,6 @@
 
 #if ENABLE(INDEXED_DATABASE)
 
-#include "FileSystem.h"
 #include "IDBBindingUtilities.h"
 #include "IDBGetAllRecordsData.h"
 #include "IDBGetAllResult.h"
@@ -54,6 +53,7 @@
 #include <JavaScriptCore/JSGlobalObject.h>
 #include <JavaScriptCore/StrongInlines.h>
 #include <JavaScriptCore/StructureInlines.h>
+#include <wtf/FileSystem.h>
 #include <wtf/NeverDestroyed.h>
 
 namespace WebCore {
index 781b79f..beea6b1 100644 (file)
 
 #if ENABLE(INDEXED_DATABASE)
 
-#include "FileSystem.h"
 #include "IDBCursorInfo.h"
 #include "IndexedDB.h"
 #include "Logging.h"
 #include "SQLiteIDBBackingStore.h"
 #include "SQLiteIDBCursor.h"
 #include "SQLiteTransaction.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 namespace IDBServer {
index 61aeb8f..dd9f5ad 100644 (file)
@@ -28,7 +28,6 @@
 
 #if ENABLE(INDEXED_DATABASE)
 
-#include "FileSystem.h"
 #include "IDBConnectionToClient.h"
 #include "IDBConnectionToServer.h"
 #include "IDBCursorInfo.h"
@@ -40,6 +39,7 @@
 #include "IDBResultData.h"
 #include "IDBValue.h"
 #include "Logging.h"
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 
 namespace WebCore {
index d96541e..408f622 100644 (file)
@@ -34,7 +34,6 @@
 #include "DatabaseManager.h"
 #include "DatabaseManagerClient.h"
 #include "DatabaseThread.h"
-#include "FileSystem.h"
 #include "Logging.h"
 #include "OriginLock.h"
 #include "SecurityOrigin.h"
@@ -43,6 +42,7 @@
 #include "SQLiteFileSystem.h"
 #include "SQLiteStatement.h"
 #include "SQLiteTransaction.h"
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/StdLibExtras.h>
index 423b2e6..a21bcdb 100644 (file)
@@ -26,8 +26,6 @@
 #include "config.h"
 #include "OriginLock.h"
 
-#include "FileSystem.h"
-
 namespace WebCore {
 
 String OriginLock::lockFileNameForPath(String originPath)
index a16e84f..ecc29e8 100644 (file)
@@ -25,7 +25,7 @@
 
 #pragma once
 
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 #include <wtf/Lock.h>
 #include <wtf/ThreadSafeRefCounted.h>
 #include <wtf/text/WTFString.h>
index 7cfe9fb..8d32507 100644 (file)
@@ -29,7 +29,7 @@
 #import "config.h"
 #import "DatabaseManager.h"
 
-#import "FileSystem.h"
+#import <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 7f2e02e..ea49060 100644 (file)
@@ -1,3 +1,13 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * PAL.xcodeproj/project.pbxproj:
+        * pal/PlatformMac.cmake:
+
 2019-01-24  David Kilzer  <ddkilzer@apple.com>
 
         Follow-up #2: Override the session configuration for cookieAcceptPolicy
index 4fbdde3..d164a4c 100644 (file)
                A1175B571F6B470500C4B9F0 /* DefaultSearchProvider.h in Headers */ = {isa = PBXBuildFile; fileRef = A1175B551F6B470500C4B9F0 /* DefaultSearchProvider.h */; };
                A1175B581F6B470500C4B9F0 /* DefaultSearchProvider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A1175B561F6B470500C4B9F0 /* DefaultSearchProvider.cpp */; };
                A1175B5A1F6B4A8400C4B9F0 /* NSScrollViewSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = A1175B591F6B4A8400C4B9F0 /* NSScrollViewSPI.h */; };
-               A1F55DCF1F5528EC00EDB75F /* MetadataSPI.h in Headers */ = {isa = PBXBuildFile; fileRef = A1F55DCE1F5528EC00EDB75F /* MetadataSPI.h */; };
                A1F63C9F21A4DBF7006FB43B /* PassKitSoftLink.h in Headers */ = {isa = PBXBuildFile; fileRef = A1F63C9D21A4DBF7006FB43B /* PassKitSoftLink.h */; };
                A1F63CA021A4DBF7006FB43B /* PassKitSoftLink.mm in Sources */ = {isa = PBXBuildFile; fileRef = A1F63C9E21A4DBF7006FB43B /* PassKitSoftLink.mm */; };
                A30D41211F0DD0EA00B71954 /* KillRing.h in Headers */ = {isa = PBXBuildFile; fileRef = A30D411E1F0DD0EA00B71954 /* KillRing.h */; };
                A1175B551F6B470500C4B9F0 /* DefaultSearchProvider.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DefaultSearchProvider.h; sourceTree = "<group>"; };
                A1175B561F6B470500C4B9F0 /* DefaultSearchProvider.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = DefaultSearchProvider.cpp; sourceTree = "<group>"; };
                A1175B591F6B4A8400C4B9F0 /* NSScrollViewSPI.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = NSScrollViewSPI.h; sourceTree = "<group>"; };
-               A1F55DCE1F5528EC00EDB75F /* MetadataSPI.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MetadataSPI.h; sourceTree = "<group>"; };
                A1F63C9D21A4DBF7006FB43B /* PassKitSoftLink.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PassKitSoftLink.h; sourceTree = "<group>"; };
                A1F63C9E21A4DBF7006FB43B /* PassKitSoftLink.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = PassKitSoftLink.mm; sourceTree = "<group>"; };
                A30D411E1F0DD0EA00B71954 /* KillRing.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KillRing.h; sourceTree = "<group>"; };
                                A10265881F56747A00B4C844 /* HIToolboxSPI.h */,
                                0C7785721F45130F00F4EBB6 /* LookupSPI.h */,
                                0C7785731F45130F00F4EBB6 /* MediaRemoteSPI.h */,
-                               A1F55DCE1F5528EC00EDB75F /* MetadataSPI.h */,
                                0C7785741F45130F00F4EBB6 /* NSAccessibilitySPI.h */,
                                1CCEE4F620D8743F0047B097 /* NSAppearanceSPI.h */,
                                0C7785751F45130F00F4EBB6 /* NSApplicationSPI.h */,
                                0C5AF91D1F43A4C7002EAC02 /* MediaPlayerSPI.h in Headers */,
                                0C77858C1F45130F00F4EBB6 /* MediaRemoteSPI.h in Headers */,
                                0C00CFD41F68CE4600AAC26D /* MediaTimeAVFoundation.h in Headers */,
-                               A1F55DCF1F5528EC00EDB75F /* MetadataSPI.h in Headers */,
                                0C5AF91E1F43A4C7002EAC02 /* MobileGestaltSPI.h in Headers */,
                                0C2DA1491F3BEB4900DBC317 /* NEFilterSourceSPI.h in Headers */,
                                0C77858D1F45130F00F4EBB6 /* NSAccessibilitySPI.h in Headers */,
index 6b1bd25..f130768 100644 (file)
@@ -58,7 +58,6 @@ list(APPEND PAL_PUBLIC_HEADERS
     spi/mac/HIToolboxSPI.h
     spi/mac/LookupSPI.h
     spi/mac/MediaRemoteSPI.h
-    spi/mac/MetadataSPI.h
     spi/mac/NSAccessibilitySPI.h
     spi/mac/NSAppearanceSPI.h
     spi/mac/NSApplicationSPI.h
index 866ea6a..4d72f9d 100644 (file)
@@ -189,7 +189,6 @@ list(APPEND WebCore_SOURCES
     platform/audio/mac/CARingBuffer.cpp
     platform/audio/mac/FFTFrameMac.cpp
 
-    platform/cf/FileSystemCF.cpp
     platform/cf/KeyedDecoderCF.cpp
     platform/cf/KeyedEncoderCF.cpp
     platform/cf/MainThreadSharedTimerCF.cpp
@@ -200,7 +199,6 @@ list(APPEND WebCore_SOURCES
     platform/cocoa/ContentFilterUnblockHandlerCocoa.mm
     platform/cocoa/CoreVideoSoftLink.cpp
     platform/cocoa/FileMonitorCocoa.mm
-    platform/cocoa/FileSystemCocoa.mm
     platform/cocoa/KeyEventCocoa.mm
     platform/cocoa/LocalizedStringsCocoa.mm
     platform/cocoa/MIMETypeRegistryCocoa.mm
@@ -347,7 +345,6 @@ list(APPEND WebCore_SOURCES
     platform/mac/DragDataMac.mm
     platform/mac/DragImageMac.mm
     platform/mac/EventLoopMac.mm
-    platform/mac/FileSystemMac.mm
     platform/mac/KeyEventMac.mm
     platform/mac/LocalCurrentGraphicsContext.mm
     platform/mac/LoggingMac.mm
@@ -418,8 +415,6 @@ list(APPEND WebCore_SOURCES
     platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm
     platform/network/mac/WebCoreURLResponse.mm
 
-    platform/posix/FileSystemPOSIX.cpp
-
     platform/text/cf/HyphenationCF.cpp
 
     platform/text/mac/LocaleMac.mm
index 9037603..6d44535 100644 (file)
@@ -63,7 +63,6 @@ list(APPEND WebCore_SOURCES
     platform/playstation/ScrollbarThemePlayStation.cpp
     platform/playstation/UserAgentPlayStation.cpp
 
-    platform/posix/FileSystemPOSIX.cpp
     platform/posix/SharedBufferPOSIX.cpp
 
     platform/text/Hyphenation.cpp
index 4fab308..fcb57a4 100644 (file)
@@ -84,7 +84,6 @@ list(APPEND WebCore_SOURCES
     platform/win/DragDataWin.cpp
     platform/win/DragImageWin.cpp
     platform/win/EventLoopWin.cpp
-    platform/win/FileSystemWin.cpp
     platform/win/GDIObjectCounter.cpp
     platform/win/GDIUtilities.cpp
     platform/win/KeyEventWin.cpp
@@ -93,7 +92,6 @@ list(APPEND WebCore_SOURCES
     platform/win/MIMETypeRegistryWin.cpp
     platform/win/MainThreadSharedTimerWin.cpp
     platform/win/PasteboardWin.cpp
-    platform/win/PathWalker.cpp
     platform/win/PlatformMouseEventWin.cpp
     platform/win/PlatformScreenWin.cpp
     platform/win/PopupMenuWin.cpp
@@ -248,7 +246,6 @@ if (USE_CF)
     list(APPEND WebCore_SOURCES
         loader/archive/cf/LegacyWebArchive.cpp
 
-        platform/cf/FileSystemCF.cpp
         platform/cf/KeyedDecoderCF.cpp
         platform/cf/KeyedEncoderCF.cpp
         platform/cf/SharedBufferCF.cpp
index b26d75a..40fa474 100644 (file)
@@ -1605,7 +1605,6 @@ platform/FileChooser.cpp
 platform/FileHandle.cpp
 platform/FileMonitor.cpp
 platform/FileStream.cpp
-platform/FileSystem.cpp
 platform/GenericTaskQueue.cpp
 platform/LayoutUnit.cpp
 platform/Length.cpp
index 0e15b90..c24185f 100644 (file)
@@ -181,7 +181,6 @@ platform/audio/mac/AudioSessionMac.cpp
 platform/audio/mac/CARingBuffer.cpp
 platform/audio/mac/FFTFrameMac.cpp
 
-platform/cf/FileSystemCF.cpp
 platform/cf/KeyedDecoderCF.cpp
 platform/cf/KeyedEncoderCF.cpp
 platform/cf/MainThreadSharedTimerCF.cpp
@@ -193,7 +192,6 @@ platform/cocoa/ContentFilterUnblockHandlerCocoa.mm @no-unify
 platform/cocoa/CoreVideoSoftLink.cpp
 platform/cocoa/DataDetectorsCoreSoftLink.mm
 platform/cocoa/FileMonitorCocoa.mm
-platform/cocoa/FileSystemCocoa.mm
 platform/cocoa/KeyEventCocoa.mm
 platform/cocoa/LocalizedStringsCocoa.mm
 platform/cocoa/MIMETypeRegistryCocoa.mm
@@ -446,7 +444,6 @@ platform/mac/CursorMac.mm
 platform/mac/DragDataMac.mm
 platform/mac/DragImageMac.mm
 platform/mac/EventLoopMac.mm
-platform/mac/FileSystemMac.mm
 platform/mac/KeyEventMac.mm @no-unify
 platform/mac/PlaybackSessionInterfaceMac.mm @no-unify
 platform/mac/LocalCurrentGraphicsContext.mm
@@ -541,8 +538,6 @@ platform/network/mac/UTIUtilities.mm
 platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm
 platform/network/mac/WebCoreURLResponse.mm
 
-platform/posix/FileSystemPOSIX.cpp
-
 platform/text/cf/HyphenationCF.cpp
 
 platform/text/ios/LocalizedDateCache.mm
index 10c2595..c3d8fdb 100644 (file)
                467302021C4EFE7800BCB357 /* IgnoreOpensDuringUnloadCountIncrementer.h in Headers */ = {isa = PBXBuildFile; fileRef = 467302011C4EFE6600BCB357 /* IgnoreOpensDuringUnloadCountIncrementer.h */; };
                4682D2001F79783000C863DB /* StoredCredentialsPolicy.h in Headers */ = {isa = PBXBuildFile; fileRef = 4682D1FF1F79782300C863DB /* StoredCredentialsPolicy.h */; settings = {ATTRIBUTES = (Private, ); }; };
                468344E01EDDFAAA00B7795B /* DOMRectList.h in Headers */ = {isa = PBXBuildFile; fileRef = 468344DE1EDDFA5F00B7795B /* DOMRectList.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               4689F1AF1267BAE100E8D380 /* FileMetadata.h in Headers */ = {isa = PBXBuildFile; fileRef = 4689F1AE1267BAE100E8D380 /* FileMetadata.h */; settings = {ATTRIBUTES = (Private, ); }; };
                46B63F6C1C6E8D19002E914B /* JSEventTargetCustom.h in Headers */ = {isa = PBXBuildFile; fileRef = 46B63F6B1C6E8CDF002E914B /* JSEventTargetCustom.h */; settings = {ATTRIBUTES = (Private, ); }; };
                46B95195207D633400A7D2DD /* AbstractDOMWindow.h in Headers */ = {isa = PBXBuildFile; fileRef = 46B9518A207D632800A7D2DD /* AbstractDOMWindow.h */; settings = {ATTRIBUTES = (Private, ); }; };
                46B95196207D633A00A7D2DD /* AbstractFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 46B9518F207D632B00A7D2DD /* AbstractFrame.h */; settings = {ATTRIBUTES = (Private, ); }; };
                5143B2631DDD15200014FAC6 /* LinkIcon.h in Headers */ = {isa = PBXBuildFile; fileRef = 5143B2621DDD14900014FAC6 /* LinkIcon.h */; settings = {ATTRIBUTES = (Private, ); }; };
                5145B10A1BC48E2E00E86219 /* IDBResourceIdentifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 5145B1081BC4890B00E86219 /* IDBResourceIdentifier.h */; settings = {ATTRIBUTES = (Private, ); }; };
                5148453F1BB9D07E006A72ED /* IDBError.h in Headers */ = {isa = PBXBuildFile; fileRef = 5148453D1BB9D076006A72ED /* IDBError.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               514B3F730C722047000530DF /* FileSystem.h in Headers */ = {isa = PBXBuildFile; fileRef = 514B3F720C722047000530DF /* FileSystem.h */; settings = {ATTRIBUTES = (Private, ); }; };
                514C764C0CE9234E007EF3CD /* AuthenticationMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 514C76420CE9234E007EF3CD /* AuthenticationMac.h */; settings = {ATTRIBUTES = (Private, ); }; };
                514C764E0CE9234E007EF3CD /* FormDataStreamMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 514C76440CE9234E007EF3CD /* FormDataStreamMac.h */; settings = {ATTRIBUTES = (Private, ); }; };
                514C766E0CE923A1007EF3CD /* Credential.h in Headers */ = {isa = PBXBuildFile; fileRef = 514C76590CE923A1007EF3CD /* Credential.h */; settings = {ATTRIBUTES = (Private, ); }; };
                468344DC1EDDFA5F00B7795B /* DOMRectList.idl */ = {isa = PBXFileReference; lastKnownFileType = text; path = DOMRectList.idl; sourceTree = "<group>"; };
                468344DD1EDDFA5F00B7795B /* DOMRectList.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = DOMRectList.cpp; sourceTree = "<group>"; };
                468344DE1EDDFA5F00B7795B /* DOMRectList.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DOMRectList.h; sourceTree = "<group>"; };
-               4689F1AE1267BAE100E8D380 /* FileMetadata.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileMetadata.h; sourceTree = "<group>"; };
                46B63F6B1C6E8CDF002E914B /* JSEventTargetCustom.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSEventTargetCustom.h; sourceTree = "<group>"; };
                46B9518A207D632800A7D2DD /* AbstractDOMWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AbstractDOMWindow.h; sourceTree = "<group>"; };
                46B9518C207D632900A7D2DD /* RemoteFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RemoteFrame.cpp; sourceTree = "<group>"; };
                5145B1081BC4890B00E86219 /* IDBResourceIdentifier.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBResourceIdentifier.h; sourceTree = "<group>"; };
                5148453C1BB9D076006A72ED /* IDBError.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBError.cpp; sourceTree = "<group>"; };
                5148453D1BB9D076006A72ED /* IDBError.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBError.h; sourceTree = "<group>"; };
-               514B3F720C722047000530DF /* FileSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FileSystem.h; sourceTree = "<group>"; };
-               514B3F750C722055000530DF /* FileSystemCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemCocoa.mm; sourceTree = "<group>"; };
                514C76350CE9225E007EF3CD /* JSSQLError.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSQLError.cpp; sourceTree = "<group>"; };
                514C76360CE9225E007EF3CD /* JSSQLTransaction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSQLTransaction.cpp; sourceTree = "<group>"; };
                514C76420CE9234E007EF3CD /* AuthenticationMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AuthenticationMac.h; sourceTree = "<group>"; };
                515E37F41FAA938800D7F22A /* ServiceWorkerTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ServiceWorkerTypes.h; sourceTree = "<group>"; };
                515F79511CFCA3C700CCED93 /* WebCoreCrossThreadCopier.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebCoreCrossThreadCopier.cpp; sourceTree = "<group>"; };
                515F79521CFCA3C700CCED93 /* WebCoreCrossThreadCopier.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebCoreCrossThreadCopier.h; sourceTree = "<group>"; };
-               5160300A0CC4251200C8AC25 /* FileSystemPOSIX.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystemPOSIX.cpp; sourceTree = "<group>"; };
-               5160306B0CC4362300C8AC25 /* FileSystemCF.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystemCF.cpp; sourceTree = "<group>"; };
                5160712B1BD8305300DBC4F2 /* TransactionOperation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TransactionOperation.h; sourceTree = "<group>"; };
                5160712C1BD8307200DBC4F2 /* IDBObjectStoreInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBObjectStoreInfo.cpp; sourceTree = "<group>"; };
                5160712D1BD8307200DBC4F2 /* IDBObjectStoreInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBObjectStoreInfo.h; sourceTree = "<group>"; };
                A1C2C5751FA2851600BA46FA /* PaymentSession.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = PaymentSession.cpp; sourceTree = "<group>"; };
                A1C7FAA1133A5D3500D6732D /* JSXPathResultCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSXPathResultCustom.cpp; sourceTree = "<group>"; };
                A1CBEF631F9F11290028DE7C /* MockPaymentMethod.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MockPaymentMethod.h; sourceTree = "<group>"; };
-               A1CC11621E493D0100EFA69C /* FileSystemMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FileSystemMac.mm; sourceTree = "<group>"; };
                A1CC564C1F46145000A4555B /* JSPaymentMethodData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSPaymentMethodData.h; sourceTree = "<group>"; };
                A1CC564D1F46145100A4555B /* JSPaymentMethodData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSPaymentMethodData.cpp; sourceTree = "<group>"; };
                A1CC564E1F46145200A4555B /* JSPaymentComplete.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSPaymentComplete.h; sourceTree = "<group>"; };
                C5592F771A92AA28001F8862 /* CharacterProperties.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CharacterProperties.h; sourceTree = "<group>"; };
                C55C7BA01718AFBA001327E4 /* RenderThemeIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = RenderThemeIOS.mm; sourceTree = "<group>"; };
                C572EE1D1201C9BC007D8F82 /* JSIDBIndex.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSIDBIndex.h; sourceTree = "<group>"; };
-               C57FEDE01212EE9C0097BE65 /* FileSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FileSystem.cpp; sourceTree = "<group>"; };
                C585A66011D4FAC5004C3E4B /* IDBBindingUtilities.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBBindingUtilities.cpp; sourceTree = "<group>"; };
                C585A66111D4FAC5004C3E4B /* IDBBindingUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IDBBindingUtilities.h; sourceTree = "<group>"; };
                C585A66B11D4FB07004C3E4B /* JSIDBDatabase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSIDBDatabase.h; sourceTree = "<group>"; };
                1AE42F670AA4B8CB00C8612D /* cf */ = {
                        isa = PBXGroup;
                        children = (
-                               5160306B0CC4362300C8AC25 /* FileSystemCF.cpp */,
                                517A63BF1B74317E00E7DCDC /* KeyedDecoderCF.cpp */,
                                517A63C01B74317E00E7DCDC /* KeyedDecoderCF.h */,
                                517A63C11B74317E00E7DCDC /* KeyedEncoderCF.cpp */,
                        path = mac;
                        sourceTree = "<group>";
                };
-               516030090CC4245400C8AC25 /* posix */ = {
-                       isa = PBXGroup;
-                       children = (
-                               5160300A0CC4251200C8AC25 /* FileSystemPOSIX.cpp */,
-                       );
-                       path = posix;
-                       sourceTree = "<group>";
-               };
                5160F4920B0AA71500C1D2AF /* mac */ = {
                        isa = PBXGroup;
                        children = (
                                A7CFB3D40B7ED1180070C32D /* DragImageMac.mm */,
                                E1BA66F01742BD8600C20251 /* DynamicLinkerInterposing.h */,
                                1CA19E030DC255950065A994 /* EventLoopMac.mm */,
-                               A1CC11621E493D0100EFA69C /* FileSystemMac.mm */,
                                935C476E09AC4D7300A6AAB4 /* KeyEventMac.mm */,
                                F44A5F571FED3830007F5944 /* LegacyNSPasteboardTypes.h */,
                                06E81ED60AB5D5E900C87837 /* LocalCurrentGraphicsContext.h */,
                                7C7941E31C56C29300A4C58E /* DataDetectorsCoreSoftLink.h */,
                                7C7941E21C56C29300A4C58E /* DataDetectorsCoreSoftLink.mm */,
                                7A09CEF01F01D1F700E93BDB /* FileMonitorCocoa.mm */,
-                               514B3F750C722055000530DF /* FileSystemCocoa.mm */,
                                A5C974CF11485FF10066F2AB /* KeyEventCocoa.h */,
                                A5C974D011485FF10066F2AB /* KeyEventCocoa.mm */,
                                1A4832B21A953BA6008B4DFE /* LocalizedStringsCocoa.mm */,
                                07221B9217CF0AD400848E51 /* mediastream */,
                                59C77F101054591C00506104 /* mock */,
                                656B84D70AEA1CE900A095B4 /* network */,
-                               516030090CC4245400C8AC25 /* posix */,
                                1A2E6E560CC551E0004A2062 /* sql */,
                                B2C3D9EC0D006C1D00EF6F26 /* text */,
                                E188235F2031F50F00B42DF3 /* vr */,
                                066C772A0AB603B700238CC4 /* FileChooser.h */,
                                5351D4AE1DF916AC008010CD /* FileHandle.cpp */,
                                5351D4AF1DF916AC008010CD /* FileHandle.h */,
-                               4689F1AE1267BAE100E8D380 /* FileMetadata.h */,
                                7A09CEEB1F01CC9300E93BDB /* FileMonitor.cpp */,
                                7A09CEEC1F01CC9300E93BDB /* FileMonitor.h */,
                                2EF1BFE8121C9F4200C27627 /* FileStream.cpp */,
                                2EF1BFE9121C9F4200C27627 /* FileStream.h */,
                                2EF1BFF8121CB0CE00C27627 /* FileStreamClient.h */,
-                               C57FEDE01212EE9C0097BE65 /* FileSystem.cpp */,
-                               514B3F720C722047000530DF /* FileSystem.h */,
                                BC073BA90C399B1F000F5979 /* FloatConversion.h */,
                                CD4BE5291CE13425009D87DA /* GenericTaskQueue.cpp */,
                                CD62FB941AF018E70012ED7D /* GenericTaskQueue.h */,
                                F55B3DBE1251F12D003EF269 /* FileInputType.h in Headers */,
                                976D6C86122B8A3D001FD1F7 /* FileList.h in Headers */,
                                835D54C51F4DE53800E60671 /* FileListCreator.h in Headers */,
-                               4689F1AF1267BAE100E8D380 /* FileMetadata.h in Headers */,
                                7A09CEF11F02069B00E93BDB /* FileMonitor.h in Headers */,
                                976D6C89122B8A3D001FD1F7 /* FileReader.h in Headers */,
                                2E75841E12779ADA0062628B /* FileReaderLoader.h in Headers */,
                                2EDF369D122C94B4002F7D4E /* FileReaderSync.h in Headers */,
                                2EF1BFEB121C9F4200C27627 /* FileStream.h in Headers */,
                                2EF1BFF9121CB0CE00C27627 /* FileStreamClient.h in Headers */,
-                               514B3F730C722047000530DF /* FileSystem.h in Headers */,
                                83FB33711F508A5400986E54 /* FileSystemDirectoryEntry.h in Headers */,
                                830335021F549057004DF707 /* FileSystemDirectoryReader.h in Headers */,
                                830335031F54905A004DF707 /* FileSystemEntriesCallback.h in Headers */,
index d251d2e..8a83c4b 100644 (file)
@@ -27,7 +27,6 @@
 #include "GCController.h"
 
 #include "CommonVM.h"
-#include "FileSystem.h"
 #include "JSHTMLDocument.h"
 #include "Location.h"
 #include <JavaScriptCore/Heap.h>
@@ -36,6 +35,7 @@
 #include <JavaScriptCore/VM.h>
 #include <pal/Logging.h>
 #include <wtf/FastMalloc.h>
+#include <wtf/FileSystem.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/StdLibExtras.h>
 
index a3ecc5a..59f9786 100644 (file)
 #include "DataTransferItemList.h"
 #include "Document.h"
 #include "File.h"
-#include "FileSystem.h"
 #include "FileSystemDirectoryEntry.h"
 #include "FileSystemFileEntry.h"
 #include "ScriptExecutionContext.h"
 #include "StringCallback.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 97217f1..254a368 100644 (file)
@@ -37,7 +37,6 @@
 #import "Editor.h"
 #import "EditorClient.h"
 #import "File.h"
-#import "FileSystem.h"
 #import "Frame.h"
 #import "FrameLoader.h"
 #import "FrameLoaderClient.h"
@@ -65,6 +64,7 @@
 #import "WebNSAttributedStringExtras.h"
 #import "markup.h"
 #import <pal/spi/cocoa/NSAttributedStringSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/SoftLinking.h>
 #import <wtf/URLParser.h>
 
index b73fcde..adb30c9 100644 (file)
 #include "File.h"
 
 #include "BlobURL.h"
-#include "FileMetadata.h"
-#include "FileSystem.h"
 #include "MIMETypeRegistry.h"
 #include "ThreadableBlobRegistry.h"
 #include <wtf/DateMath.h>
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/WTFString.h>
 
 namespace WebCore {
index 20be6f7..664f9a5 100644 (file)
@@ -28,7 +28,7 @@
 
 #if ENABLE(FILE_REPLACEMENT)
 
-#import "FileSystem.h"
+#import <wtf/FileSystem.h>
 
 #if PLATFORM(IOS_FAMILY)
 #import <MobileCoreServices/MobileCoreServices.h>
index 03af3a9..998f9ef 100644 (file)
@@ -30,7 +30,6 @@
 #include "File.h"
 #include "FileList.h"
 #include "FileListCreator.h"
-#include "FileSystem.h"
 #include "FormController.h"
 #include "Frame.h"
 #include "HTMLInputElement.h"
@@ -43,6 +42,7 @@
 #include "Settings.h"
 #include "ShadowRoot.h"
 #include "UserGestureIndicator.h"
+#include <wtf/FileSystem.h>
 #include <wtf/IsoMallocInlines.h>
 #include <wtf/TypeCasts.h>
 #include <wtf/text/StringBuilder.h>
index 76f5659..1556fc2 100644 (file)
@@ -28,9 +28,9 @@
 
 #include "FileChooser.h"
 #include "FileList.h"
-#include "FileMetadata.h"
-#include "FileSystem.h"
 #include <wtf/CrossThreadCopier.h>
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 755f1a2..8a33e88 100644 (file)
@@ -33,7 +33,6 @@
 #include "DocumentLoader.h"
 #include "DOMApplicationCache.h"
 #include "EventNames.h"
-#include "FileSystem.h"
 #include "Frame.h"
 #include "FrameLoader.h"
 #include "FrameLoaderClient.h"
@@ -44,6 +43,7 @@
 #include "ResourceRequest.h"
 #include "Settings.h"
 #include "SubresourceLoader.h"
+#include <wtf/FileSystem.h>
 #include <wtf/UUID.h>
 
 namespace WebCore {
index e81483c..82adff3 100644 (file)
 #include "ApplicationCacheGroup.h"
 #include "ApplicationCacheHost.h"
 #include "ApplicationCacheResource.h"
-#include "FileSystem.h"
 #include "SQLiteDatabaseTracker.h"
 #include "SQLiteStatement.h"
 #include "SQLiteTransaction.h"
 #include "SecurityOrigin.h"
 #include "SecurityOriginData.h"
+#include <wtf/FileSystem.h>
 #include <wtf/StdLibExtras.h>
 #include <wtf/URL.h>
 #include <wtf/UUID.h>
index db177e8..26a2581 100644 (file)
@@ -51,7 +51,6 @@
 #include "Event.h"
 #include "EventNames.h"
 #include "ExtensionStyleSheets.h"
-#include "FileSystem.h"
 #include "FocusController.h"
 #include "FrameLoader.h"
 #include "FrameLoaderClient.h"
 #include "WebGLStateTracker.h"
 #include "WheelEventDeltaFilter.h"
 #include "Widget.h"
+#include <wtf/FileSystem.h>
 #include <wtf/RefCountedLeakCounter.h>
 #include <wtf/StdLibExtras.h>
 #include <wtf/text/Base64.h>
index b58faaa..3ad921c 100644 (file)
 #include "SecurityOrigin.h"
 
 #include "BlobURL.h"
-#include "FileSystem.h"
-#include <wtf/URL.h>
 #include "SchemeRegistry.h"
 #include "SecurityPolicy.h"
 #include "TextEncoding.h"
 #include "ThreadableBlobRegistry.h"
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/StdLibExtras.h>
+#include <wtf/URL.h>
 #include <wtf/text/StringBuilder.h>
 
 namespace WebCore {
index 05f8b19..430cb8b 100644 (file)
@@ -27,9 +27,9 @@
 #include "SecurityOriginData.h"
 
 #include "Document.h"
-#include "FileSystem.h"
 #include "Frame.h"
 #include "SecurityOrigin.h"
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/StringConcatenateNumbers.h>
index d118308..50d824c 100644 (file)
@@ -28,9 +28,8 @@
 
 #pragma once
 
-#include "FileSystem.h"
-
 #include <wtf/Assertions.h>
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index ea91737..893bb33 100644 (file)
  */
 
 #include "config.h"
-
 #include "FileStream.h"
 
-#include "FileSystem.h"
 #include <wtf/text/WTFString.h>
 
 namespace WebCore {
index aa011ea..a2fb8e5 100644 (file)
  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef FileStream_h
-#define FileStream_h
+#pragma once
 
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
@@ -64,5 +63,3 @@ private:
 };
 
 } // namespace WebCore
-
-#endif // FileStream_h
index 81318e8..ec37134 100644 (file)
@@ -26,8 +26,8 @@
 
 #pragma once
 
-#include "FileSystem.h"
 #include <JavaScriptCore/ArrayBuffer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/Forward.h>
 #include <wtf/RefCounted.h>
 #include <wtf/ThreadSafeRefCounted.h>
index 2773c2a..090b84a 100644 (file)
@@ -25,7 +25,6 @@ platform/audio/glib/AudioBusGLib.cpp
 
 platform/glib/EventLoopGlib.cpp
 platform/glib/FileMonitorGLib.cpp
-platform/glib/FileSystemGlib.cpp
 platform/glib/KeyedDecoderGlib.cpp
 platform/glib/KeyedEncoderGlib.cpp
 platform/glib/LowPowerModeNotifierGLib.cpp
index 1ab3c33..cc7fe6b 100644 (file)
@@ -26,9 +26,9 @@
 #import "config.h"
 #import "FileMonitor.h"
 
-#import "FileSystem.h"
 #import "Logging.h"
 #import <wtf/BlockPtr.h>
+#import <wtf/FileSystem.h>
 
 namespace WebCore {
     
index 463f327..5a982f4 100644 (file)
@@ -26,7 +26,7 @@
 #include "config.h"
 #include "FileMonitor.h"
 
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GUniquePtr.h>
 #include <wtf/threads/BinarySemaphore.h>
 
index b4896c0..c747357 100644 (file)
@@ -19,7 +19,6 @@
 #include "config.h"
 #include "SharedBuffer.h"
 
-#include "FileSystem.h"
 #include <wtf/glib/GUniquePtr.h>
 #include <wtf/text/CString.h>
 
index e8dd3b5..24f95e8 100644 (file)
@@ -29,7 +29,6 @@
 #if ENABLE(LEGACY_ENCRYPTED_MEDIA) && ENABLE(MEDIA_SOURCE)
 
 #import "CDMPrivateMediaSourceAVFObjC.h"
-#import "FileSystem.h"
 #import "LegacyCDM.h"
 #import "Logging.h"
 #import "MediaPlayer.h"
@@ -39,6 +38,7 @@
 #import <CoreMedia/CMBase.h>
 #import <JavaScriptCore/TypedArrayInlines.h>
 #import <objc/objc-runtime.h>
+#import <wtf/FileSystem.h>
 #import <wtf/SoftLinking.h>
 
 SOFT_LINK_FRAMEWORK_OPTIONAL(AVFoundation)
index 9929431..c3573e5 100644 (file)
@@ -29,7 +29,6 @@
 #if ENABLE(LEGACY_ENCRYPTED_MEDIA) && ENABLE(MEDIA_SOURCE)
 
 #import "CDMPrivateMediaSourceAVFObjC.h"
-#import "FileSystem.h"
 #import "LegacyCDM.h"
 #import "Logging.h"
 #import "MediaPlayer.h"
@@ -40,6 +39,7 @@
 #import <JavaScriptCore/TypedArrayInlines.h>
 #import <objc/objc-runtime.h>
 #import <pal/spi/mac/AVFoundationSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/SoftLinking.h>
 #import <wtf/UUID.h>
 
index 2cb2d6f..ec58378 100644 (file)
@@ -29,9 +29,9 @@
 #if ENABLE(LEGACY_ENCRYPTED_MEDIA) && ENABLE(MEDIA_SOURCE)
 
 #import "CDMPrivateMediaSourceAVFObjC.h"
-#import "FileSystem.h"
 #import "WebCoreNSErrorExtras.h"
 #import <AVFoundation/AVError.h>
+#import <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 5e36dd0..d6d5e82 100644 (file)
@@ -31,7 +31,6 @@
 #import "AVAssetTrackUtilities.h"
 #import "AVFoundationMIMETypeCache.h"
 #import "CDMSessionAVStreamSession.h"
-#import "FileSystem.h"
 #import "GraphicsContextCG.h"
 #import "Logging.h"
 #import "MediaSourcePrivateAVFObjC.h"
@@ -49,6 +48,7 @@
 #import <pal/avfoundation/MediaTimeAVFoundation.h>
 #import <pal/spi/mac/AVFoundationSPI.h>
 #import <wtf/Deque.h>
+#import <wtf/FileSystem.h>
 #import <wtf/MainThread.h>
 #import <wtf/NeverDestroyed.h>
 
index 0f05eb9..4140c11 100644 (file)
@@ -28,7 +28,6 @@
 
 #if ENABLE(VIDEO) && USE(GSTREAMER)
 
-#include "FileSystem.h"
 #include "GStreamerCommon.h"
 #include "HTTPHeaderNames.h"
 #include "MIMETypeRegistry.h"
@@ -42,6 +41,7 @@
 #include <gst/gst.h>
 #include <gst/pbutils/missing-plugins.h>
 #include <limits>
+#include <wtf/FileSystem.h>
 #include <wtf/HexNumber.h>
 #include <wtf/MediaTime.h>
 #include <wtf/NeverDestroyed.h>
index 7bf91b2..a9d9e47 100644 (file)
 
 #if USE(QUICK_LOOK)
 
-#import "FileSystem.h"
 #import "PreviewConverter.h"
 #import "ResourceRequest.h"
 #import "SchemeRegistry.h"
 #import <pal/ios/QuickLookSoftLink.h>
 #import <pal/spi/cocoa/NSFileManagerSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/Lock.h>
 #import <wtf/NeverDestroyed.h>
 
index bf82183..3545d7e 100644 (file)
 #import <UIKit/NSItemProvider+UIKitAdditions.h>
 #import <UIKit/UIColor.h>
 #import <UIKit/UIImage.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/Pasteboard.h>
 #import <pal/ios/UIKitSoftLink.h>
 #import <pal/spi/ios/UIKitSPI.h>
 #import <wtf/BlockPtr.h>
+#import <wtf/FileSystem.h>
 #import <wtf/OSObjectPtr.h>
 #import <wtf/RetainPtr.h>
 
@@ -694,7 +694,7 @@ static NSURL *linkTemporaryItemProviderFilesToDropStagingDirectory(NSURL *url, N
     if (!url)
         return nil;
 
-    NSString *temporaryDataInteractionDirectory = WebCore::FileSystem::createTemporaryDirectory(dataInteractionDirectoryPrefix);
+    NSString *temporaryDataInteractionDirectory = FileSystem::createTemporaryDirectory(dataInteractionDirectoryPrefix);
     if (!temporaryDataInteractionDirectory)
         return nil;
 
index d7e3f39..d79e2f6 100644 (file)
 #if ENABLE(MEDIA_STREAM) && USE(AVFOUNDATION)
 
 #include "AudioStreamDescription.h"
-#include "FileSystem.h"
 #include "Logging.h"
 #include "MediaStreamTrackPrivate.h"
 #include "WebAudioBufferList.h"
 #include <AVFoundation/AVAssetWriter.h>
 #include <AVFoundation/AVAssetWriterInput.h>
 #include <pal/cf/CoreMediaSoftLink.h>
+#include <wtf/FileSystem.h>
 
 typedef AVAssetWriter AVAssetWriterType;
 typedef AVAssetWriterInput AVAssetWriterInputType;
index b63f061..5abfd75 100644 (file)
@@ -27,8 +27,8 @@
 #include "BlobDataFileReference.h"
 
 #include "File.h"
-#include "FileMetadata.h"
-#include "FileSystem.h"
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 80b41e9..1c706aa 100644 (file)
 #include "BlobData.h"
 #include "BlobPart.h"
 #include "BlobResourceHandle.h"
-#include "FileMetadata.h"
-#include "FileSystem.h"
 #include "ResourceError.h"
 #include "ResourceHandle.h"
 #include "ResourceRequest.h"
 #include "ResourceResponse.h"
 #include <wtf/CompletionHandler.h>
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/Scope.h>
index c94e394..cc67ce6 100644 (file)
 #include "AsyncFileStream.h"
 #include "BlobData.h"
 #include "FileStream.h"
-#include "FileSystem.h"
 #include "HTTPHeaderNames.h"
 #include "HTTPParsers.h"
 #include "ParsedContentRange.h"
-#include <wtf/URL.h>
 #include "ResourceError.h"
 #include "ResourceHandleClient.h"
 #include "ResourceRequest.h"
 #include "ResourceResponse.h"
 #include "SharedBuffer.h"
 #include <wtf/CompletionHandler.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/Ref.h>
+#include <wtf/URL.h>
 
 namespace WebCore {
 
index 54e4ac0..7b76a5e 100644 (file)
 #include "DOMFormData.h"
 #include "Document.h"
 #include "File.h"
-#include "FileSystem.h"
 #include "FormDataBuilder.h"
 #include "Page.h"
 #include "SharedBuffer.h"
 #include "TextEncoding.h"
 #include "ThreadableBlobRegistry.h"
+#include <wtf/FileSystem.h>
 #include <wtf/text/LineEnding.h>
 
 namespace WebCore {
index 9e2d881..a74ae5a 100644 (file)
 #include "FormDataStreamCFNet.h"
 
 #include "BlobData.h"
-#include "FileSystem.h"
 #include "FormData.h"
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <wtf/Assertions.h>
+#include <wtf/FileSystem.h>
 #include <wtf/HashMap.h>
 #include <wtf/MainThread.h>
 #include <wtf/RetainPtr.h>
index 27ff9d1..2fec1f3 100644 (file)
 
 #if PLATFORM(COCOA)
 
-#import "FileSystem.h"
 #import "FormDataStreamMac.h"
 #import "HTTPHeaderNames.h"
 #import "ResourceRequestCFNet.h"
 #import "RuntimeApplicationChecks.h"
 #import <Foundation/Foundation.h>
 #import <pal/spi/cf/CFNetworkSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/text/CString.h>
 
 namespace WebCore {
index c23fd72..2636228 100644 (file)
 #include "CookieJarDB.h"
 
 #include "CookieUtil.h"
-#include "FileSystem.h"
 #include "Logging.h"
 #include "SQLiteFileSystem.h"
-
+#include <wtf/FileSystem.h>
 #include <wtf/MonotonicTime.h>
 #include <wtf/URL.h>
 
index cbc45fe..11027ce 100644 (file)
 
 #pragma once
 
-#include "FileSystem.h"
 #include "HTTPHeaderMap.h"
 #include "ResourceHandle.h"
 #include "ResourceRequest.h"
 #include "ResourceResponse.h"
+#include <wtf/FileSystem.h>
 #include <wtf/Forward.h>
 #include <wtf/HashMap.h>
 #include <wtf/ListHashSet.h>
index 43bc2e7..fa5c8d2 100644 (file)
 
 #include "CurlCacheManager.h"
 
-#include "FileSystem.h"
 #include "HTTPHeaderMap.h"
 #include "Logging.h"
 #include "ResourceHandleClient.h"
 #include "ResourceHandleInternal.h"
 #include "ResourceRequest.h"
+#include <wtf/FileSystem.h>
 #include <wtf/HashMap.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/text/CString.h>
index c8ef333..09e7fdb 100644 (file)
@@ -26,8 +26,8 @@
 
 #pragma once
 
-#include "FileSystem.h"
 #include "FormData.h"
+#include <wtf/FileSystem.h>
 #include <wtf/Vector.h>
 
 namespace WebCore {
index fdc4b59..93ca610 100644 (file)
 #include "CurlRequestSchedulerClient.h"
 #include "CurlResponse.h"
 #include "CurlSSLVerifier.h"
-#include "FileSystem.h"
 #include "NetworkLoadMetrics.h"
 #include "ProtectionSpace.h"
 #include "ResourceRequest.h"
+#include <wtf/FileSystem.h>
 #include <wtf/MessageQueue.h>
 #include <wtf/MonotonicTime.h>
 #include <wtf/Noncopyable.h>
index a342ec5..05b5672 100644 (file)
 #include "CookieJarDB.h"
 #include "CookieRequestHeaderFieldProxy.h"
 #include "CurlContext.h"
-#include "FileSystem.h"
 #include "NetworkingContext.h"
 #include "ResourceHandle.h"
-
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/URL.h>
index e51e7ab..7be00ad 100644 (file)
@@ -38,7 +38,6 @@
 #include "CurlCacheManager.h"
 #include "CurlContext.h"
 #include "CurlRequest.h"
-#include "FileSystem.h"
 #include "HTTPParsers.h"
 #include "Logging.h"
 #include "NetworkStorageSession.h"
@@ -48,6 +47,7 @@
 #include "SynchronousLoaderClient.h"
 #include "TextEncoding.h"
 #include <wtf/CompletionHandler.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/Base64.h>
 
 namespace WebCore {
index fcf55d7..b692920 100644 (file)
@@ -28,8 +28,8 @@
 
 #if ENABLE(FILE_REPLACEMENT)
 
-#include "FileMetadata.h"
-#include "FileSystem.h"
+#include <wtf/FileMetadata.h>
+#include <wtf/FileSystem.h>
 #include <wtf/SoftLinking.h>
 #include <wtf/text/CString.h>
 
index 63734c6..0815ea6 100644 (file)
@@ -32,7 +32,6 @@
 #if USE(SOUP)
 
 #include "CredentialStorage.h"
-#include "FileSystem.h"
 #include "GUniquePtrSoup.h"
 #include "HTTPParsers.h"
 #include "LocalizedStrings.h"
@@ -57,6 +56,7 @@
 #include <unistd.h>
 #endif
 #include <wtf/CompletionHandler.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GRefPtr.h>
 #include <wtf/glib/RunLoopSourcePriority.h>
 #include <wtf/text/CString.h>
index 343faeb..b967795 100644 (file)
 #include "SoupNetworkSession.h"
 
 #include "AuthenticationChallenge.h"
-#include "FileSystem.h"
 #include "GUniquePtrSoup.h"
 #include "Logging.h"
 #include "SoupNetworkProxySettings.h"
 #include <glib/gstdio.h>
 #include <libsoup/soup.h>
 #include <pal/crypto/CryptoDigest.h>
+#include <wtf/FileSystem.h>
 #include <wtf/HashSet.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/text/Base64.h>
index 513375d..8ed5717 100644 (file)
 #include "config.h"
 #include "SharedBuffer.h"
 
-#include "FileSystem.h"
-
 #include <fcntl.h>
 #include <sys/stat.h>
 #include <unistd.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 
 namespace WebCore {
index 90c20c7..364bff7 100644 (file)
 #include "config.h"
 #include "SQLiteFileSystem.h"
 
-#include "FileSystem.h"
 #include "SQLiteDatabase.h"
 #include "SQLiteStatement.h"
 #include <sqlite3.h>
+#include <wtf/FileSystem.h>
 
 #if PLATFORM(IOS_FAMILY)
 #include <pal/spi/ios/SQLite3SPI.h>
index 2d7b66d..5eeb9bf 100644 (file)
 
 #if USE(LIBHYPHEN)
 
-#include "FileSystem.h"
 #include <hyphen.h>
 #include <limits>
 #include <stdlib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/HashMap.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/TinyLRUCache.h>
@@ -224,7 +224,7 @@ public:
 
     static RefPtr<WebCore::HyphenationDictionary> createValueForKey(const AtomicString& dictionaryPath)
     {
-        return WebCore::HyphenationDictionary::create(WebCore::FileSystem::fileSystemRepresentation(dictionaryPath.string()));
+        return WebCore::HyphenationDictionary::create(FileSystem::fileSystemRepresentation(dictionaryPath.string()));
     }
 };
 
index 9e6e4c5..e5730b3 100644 (file)
@@ -25,9 +25,9 @@
 #include "config.h"
 #include "SearchPopupMenuDB.h"
 
-#include "FileSystem.h"
 #include "SQLiteFileSystem.h"
 #include "SQLiteTransaction.h"
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 
index 76c9c5c..c4fa356 100644 (file)
@@ -25,7 +25,6 @@
 #include "ControlStates.h"
 #include "Document.h"
 #include "FileList.h"
-#include "FileSystem.h"
 #include "FloatConversion.h"
 #include "FloatRoundedRect.h"
 #include "FocusController.h"
@@ -45,6 +44,7 @@
 #include "SpinButtonElement.h"
 #include "StringTruncator.h"
 #include "TextControlInnerElements.h"
+#include <wtf/FileSystem.h>
 #include <wtf/NeverDestroyed.h>
 
 #if ENABLE(METER_ELEMENT)
index b696eac..b25966c 100644 (file)
@@ -27,7 +27,6 @@
 
 #include "CSSValueKeywords.h"
 #include "FileList.h"
-#include "FileSystem.h"
 #include "FloatRoundedRect.h"
 #include "FontDescription.h"
 #include "GRefPtrGtk.h"
@@ -55,6 +54,7 @@
 #include <gdk/gdk.h>
 #include <glib.h>
 #include <gtk/gtk.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GRefPtr.h>
 #include <wtf/glib/GUniquePtr.h>
 #include <wtf/text/CString.h>
index eeb9985..219657e 100644 (file)
@@ -24,7 +24,6 @@
 
 #include "CSSValueKeywords.h"
 #include "Element.h"
-#include "FileSystem.h"
 #include "FontMetrics.h"
 #include "Frame.h"
 #include "FrameSelection.h"
@@ -38,6 +37,7 @@
 #include "SystemInfo.h"
 #include "UserAgentStyleSheets.h"
 #include "WebCoreBundleWin.h"
+#include <wtf/FileSystem.h>
 #include <wtf/SoftLinking.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/win/WCharStringExtras.h>
index 60eeb8c..1af4378 100644 (file)
@@ -28,7 +28,6 @@
 
 #if ENABLE(SERVICE_WORKER)
 
-#include "FileSystem.h"
 #include "Logging.h"
 #include "RegistrationStore.h"
 #include "SQLiteDatabase.h"
@@ -39,6 +38,7 @@
 #include "SecurityOrigin.h"
 #include <wtf/CompletionHandler.h>
 #include <wtf/CrossThreadCopier.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/Scope.h>
index 78f2b08..3f5ce26 100644 (file)
@@ -1,3 +1,82 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * NetworkProcess/Classifier/ResourceLoadStatisticsPersistentStorage.cpp:
+        * NetworkProcess/NetworkDataTaskBlob.h:
+        * NetworkProcess/NetworkProcess.cpp:
+        * NetworkProcess/cache/CacheStorageEngine.cpp:
+        * NetworkProcess/cache/CacheStorageEngineCaches.cpp:
+        * NetworkProcess/cache/NetworkCache.cpp:
+        * NetworkProcess/cache/NetworkCacheBlobStorage.cpp:
+        * NetworkProcess/cache/NetworkCacheData.cpp:
+        * NetworkProcess/cache/NetworkCacheFileSystem.cpp:
+        * NetworkProcess/cache/NetworkCacheFileSystem.h:
+        * NetworkProcess/cache/NetworkCacheIOChannelCocoa.mm:
+        * NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp:
+        * NetworkProcess/cache/NetworkCacheStatistics.cpp:
+        * NetworkProcess/cache/NetworkCacheStorage.cpp:
+        * NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
+        * NetworkProcess/cocoa/NetworkSessionCocoa.mm:
+        * NetworkProcess/mac/NetworkProcessMac.mm:
+        * NetworkProcess/soup/NetworkProcessSoup.cpp:
+        * PluginProcess/unix/PluginProcessMainUnix.cpp:
+        * Shared/PersistencyUtils.cpp:
+        * Shared/Plugins/Netscape/unix/NetscapePluginModuleUnix.cpp:
+        * Shared/Plugins/unix/PluginSearchPath.cpp:
+        * Shared/WebMemorySampler.h:
+        * Shared/glib/ProcessExecutablePathGLib.cpp:
+        * Shared/ios/ChildProcessIOS.mm:
+        * Shared/mac/ChildProcessMac.mm:
+        * Shared/mac/SandboxExtensionMac.mm:
+        * UIProcess/API/APIContentRuleListStore.cpp:
+        * UIProcess/API/Cocoa/APIWebsiteDataStoreCocoa.mm:
+        * UIProcess/API/glib/APIWebsiteDataStoreGLib.cpp:
+        * UIProcess/API/glib/IconDatabase.cpp:
+        * UIProcess/API/glib/WebKitFaviconDatabase.cpp:
+        * UIProcess/API/glib/WebKitFileChooserRequest.cpp:
+        * UIProcess/API/glib/WebKitWebContext.cpp:
+        * UIProcess/API/glib/WebKitWebsiteDataManager.cpp:
+        * UIProcess/API/win/APIWebsiteDataStoreWin.cpp:
+        * UIProcess/Automation/WebAutomationSession.cpp:
+        * UIProcess/Cocoa/DownloadClient.mm:
+        * UIProcess/Cocoa/WebProcessPoolCocoa.mm:
+        * UIProcess/Cocoa/WebViewImpl.mm:
+        * UIProcess/DeviceIdHashSaltStorage.cpp:
+        * UIProcess/Downloads/DownloadProxy.cpp:
+        * UIProcess/Launcher/glib/BubblewrapLauncher.cpp:
+        * UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:
+        * UIProcess/Plugins/gtk/PluginInfoCache.cpp:
+        * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
+        * UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp:
+        * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
+        * UIProcess/ServiceWorkerProcessProxy.cpp:
+        * UIProcess/WebStorage/LocalStorageDatabase.cpp:
+        * UIProcess/WebStorage/LocalStorageDatabaseTracker.cpp:
+        * UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:
+        * UIProcess/WebsiteData/WebsiteDataStore.cpp:
+        * UIProcess/glib/WebProcessProxyGLib.cpp:
+        * UIProcess/gtk/WebInspectorProxyGtk.cpp:
+        * UIProcess/gtk/WebProcessPoolGtk.cpp:
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        * UIProcess/ios/forms/WKFileUploadPanel.mm:
+        * UIProcess/mac/WebPageProxyMac.mm:
+        * UIProcess/win/WebProcessPoolWin.cpp:
+        * UIProcess/win/WebView.cpp:
+        * UIProcess/wpe/WebProcessPoolWPE.cpp:
+        * WebProcess/InjectedBundle/API/glib/WebKitExtensionManager.cpp:
+        * WebProcess/InjectedBundle/glib/InjectedBundleGlib.cpp:
+        * WebProcess/MediaCache/WebMediaKeyStorageManager.cpp:
+        * WebProcess/Plugins/Netscape/NetscapePluginStream.h:
+        * WebProcess/Plugins/PluginProcessConnection.cpp:
+        * WebProcess/WebCoreSupport/SessionStateConversion.cpp:
+        * WebProcess/WebPage/gtk/WebInspectorUIGtk.cpp:
+        * WebProcess/WebPage/win/WebInspectorUIWin.cpp:
+        * WebProcess/cocoa/WebProcessCocoa.mm:
+
 2019-01-23  Simon Fraser  <simon.fraser@apple.com>
 
         Create "frame hosting" nodes for the scrolling tree
index c210eca..105dd02 100644 (file)
@@ -33,9 +33,9 @@
 #include "ResourceLoadStatisticsMemoryStore.h"
 #include "WebResourceLoadStatisticsStore.h"
 #include <WebCore/FileMonitor.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/KeyedCoding.h>
 #include <WebCore/SharedBuffer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 #include <wtf/WorkQueue.h>
 
index 75d31a6..eb79447 100644 (file)
@@ -33,7 +33,7 @@
 
 #include "NetworkDataTask.h"
 #include <WebCore/FileStreamClient.h>
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 namespace WebCore {
 class AsyncFileStream;
@@ -113,7 +113,7 @@ private:
     unsigned m_sizeItemCount { 0 };
     unsigned m_readItemCount { 0 };
     bool m_fileOpened { false };
-    WebCore::FileSystem::PlatformFileHandle m_downloadFile { WebCore::FileSystem::invalidPlatformFileHandle };
+    FileSystem::PlatformFileHandle m_downloadFile { FileSystem::invalidPlatformFileHandle };
 
     Vector<RefPtr<WebCore::BlobDataFileReference>> m_fileReferences;
     RefPtr<SandboxExtension> m_sandboxExtension;
index c6adc9f..f971f80 100644 (file)
@@ -1746,7 +1746,7 @@ void NetworkProcess::setCacheModel(CacheModel cacheModel)
     unsigned urlCacheMemoryCapacity = 0;
     uint64_t urlCacheDiskCapacity = 0;
     uint64_t diskFreeSize = 0;
-    if (WebCore::FileSystem::getVolumeFreeSpace(m_diskCacheDirectory, diskFreeSize)) {
+    if (FileSystem::getVolumeFreeSpace(m_diskCacheDirectory, diskFreeSize)) {
         // As a fudge factor, use 1000 instead of 1024, in case the reported byte
         // count doesn't align exactly to a megabyte boundary.
         diskFreeSize /= KB * 1000;
index f17fd9f..1e3e11b 100644 (file)
@@ -52,7 +52,7 @@ String Engine::cachesRootPath(const WebCore::ClientOrigin& origin)
         return { };
 
     Key key(origin.topOrigin.toString(), origin.clientOrigin.toString(), { }, { }, salt());
-    return WebCore::FileSystem::pathByAppendingComponent(rootPath(), key.hashAsString());
+    return FileSystem::pathByAppendingComponent(rootPath(), key.hashAsString());
 }
 
 Engine::~Engine()
@@ -291,9 +291,9 @@ void Engine::initialize(CompletionCallback&& callback)
     if (!shouldComputeSalt)
         return;
 
-    String saltPath = WebCore::FileSystem::pathByAppendingComponent(m_rootPath, "salt"_s);
+    String saltPath = FileSystem::pathByAppendingComponent(m_rootPath, "salt"_s);
     m_ioQueue->dispatch([this, weakThis = makeWeakPtr(this), saltPath = WTFMove(saltPath)] () mutable {
-        WebCore::FileSystem::makeAllDirectories(m_rootPath);
+        FileSystem::makeAllDirectories(m_rootPath);
         RunLoop::main().dispatch([this, weakThis = WTFMove(weakThis), salt = readOrMakeSalt(saltPath)]() mutable {
             if (!weakThis)
                 return;
@@ -383,9 +383,9 @@ void Engine::writeFile(const String& filename, NetworkCache::Data&& data, WebCor
     m_pendingWriteCallbacks.add(++m_pendingCallbacksCounter, WTFMove(callback));
     m_ioQueue->dispatch([this, weakThis = makeWeakPtr(this), identifier = m_pendingCallbacksCounter, data = WTFMove(data), filename = filename.isolatedCopy()]() mutable {
 
-        String directoryPath = WebCore::FileSystem::directoryName(filename);
-        if (!WebCore::FileSystem::fileExists(directoryPath))
-            WebCore::FileSystem::makeAllDirectories(directoryPath);
+        String directoryPath = FileSystem::directoryName(filename);
+        if (!FileSystem::fileExists(directoryPath))
+            FileSystem::makeAllDirectories(directoryPath);
 
         auto channel = IOChannel::open(filename, IOChannel::Type::Create);
         channel->write(0, data, nullptr, [this, weakThis = WTFMove(weakThis), identifier](int error) mutable {
@@ -445,7 +445,7 @@ void Engine::removeFile(const String& filename)
         return;
 
     m_ioQueue->dispatch([filename = filename.isolatedCopy()]() mutable {
-        WebCore::FileSystem::deleteFile(filename);
+        FileSystem::deleteFile(filename);
     });
 }
 
@@ -487,8 +487,8 @@ void Engine::fetchEntries(bool shouldComputeSize, WTF::CompletionHandler<void(Ve
     }
 
     auto taskCounter = ReadOriginsTaskCounter::create(WTFMove(completionHandler));
-    for (auto& folderPath : WebCore::FileSystem::listDirectory(m_rootPath, "*")) {
-        if (!WebCore::FileSystem::fileIsDirectory(folderPath, WebCore::FileSystem::ShouldFollowSymbolicLinks::No))
+    for (auto& folderPath : FileSystem::listDirectory(m_rootPath, "*")) {
+        if (!FileSystem::fileIsDirectory(folderPath, FileSystem::ShouldFollowSymbolicLinks::No))
             continue;
         Caches::retrieveOriginFromDirectory(folderPath, *m_ioQueue, [protectedThis = makeRef(*this), shouldComputeSize, taskCounter = taskCounter.copyRef()] (auto&& origin) mutable {
             ASSERT(RunLoop::isMain());
@@ -531,8 +531,8 @@ void Engine::clearAllCachesFromDisk(CompletionHandler<void()>&& completionHandle
     ASSERT(RunLoop::isMain());
 
     m_ioQueue->dispatch([path = m_rootPath.isolatedCopy(), completionHandler = WTFMove(completionHandler)]() mutable {
-        for (auto& filename : WebCore::FileSystem::listDirectory(path, "*")) {
-            if (WebCore::FileSystem::fileIsDirectory(filename, WebCore::FileSystem::ShouldFollowSymbolicLinks::No))
+        for (auto& filename : FileSystem::listDirectory(path, "*")) {
+            if (FileSystem::fileIsDirectory(filename, FileSystem::ShouldFollowSymbolicLinks::No))
                 deleteDirectoryRecursively(filename);
         }
         RunLoop::main().dispatch(WTFMove(completionHandler));
@@ -562,8 +562,8 @@ void Engine::clearCachesForOriginFromDisk(const WebCore::SecurityOriginData& ori
 
     auto callbackAggregator = CallbackAggregator::create(WTFMove(completionHandler));
 
-    for (auto& folderPath : WebCore::FileSystem::listDirectory(m_rootPath, "*")) {
-        if (!WebCore::FileSystem::fileIsDirectory(folderPath, WebCore::FileSystem::ShouldFollowSymbolicLinks::No))
+    for (auto& folderPath : FileSystem::listDirectory(m_rootPath, "*")) {
+        if (!FileSystem::fileIsDirectory(folderPath, FileSystem::ShouldFollowSymbolicLinks::No))
             continue;
         Caches::retrieveOriginFromDirectory(folderPath, *m_ioQueue, [this, protectedThis = makeRef(*this), origin, callbackAggregator = callbackAggregator.copyRef(), folderPath] (Optional<WebCore::ClientOrigin>&& folderOrigin) mutable {
             if (!folderOrigin)
index 1913470..1f608cf 100644 (file)
@@ -42,12 +42,12 @@ using namespace NetworkCache;
 
 static inline String cachesListFilename(const String& cachesRootPath)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(cachesRootPath, "cacheslist"_s);
+    return FileSystem::pathByAppendingComponent(cachesRootPath, "cacheslist"_s);
 }
 
 static inline String cachesOriginFilename(const String& cachesRootPath)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(cachesRootPath, "origin"_s);
+    return FileSystem::pathByAppendingComponent(cachesRootPath, "origin"_s);
 }
 
 Caches::~Caches()
@@ -58,7 +58,7 @@ Caches::~Caches()
 void Caches::retrieveOriginFromDirectory(const String& folderPath, WorkQueue& queue, WTF::CompletionHandler<void(Optional<WebCore::ClientOrigin>&&)>&& completionHandler)
 {
     queue.dispatch([completionHandler = WTFMove(completionHandler), filename = cachesOriginFilename(folderPath)]() mutable {
-        if (!WebCore::FileSystem::fileExists(filename)) {
+        if (!FileSystem::fileExists(filename)) {
             RunLoop::main().dispatch([completionHandler = WTFMove(completionHandler)]() mutable {
                 completionHandler(WTF::nullopt);
             });
@@ -408,7 +408,7 @@ void Caches::readCachesFromDisk(WTF::Function<void(Expected<Vector<Cache>, Error
     }
 
     auto filename = cachesListFilename(m_rootPath);
-    if (!WebCore::FileSystem::fileExists(filename)) {
+    if (!FileSystem::fileExists(filename)) {
         callback(Vector<Cache> { });
         return;
     }
index fd27cf0..ba5c8b2 100644 (file)
 #include "NetworkCacheStorage.h"
 #include "NetworkProcess.h"
 #include <WebCore/CacheValidation.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/HTTPHeaderNames.h>
 #include <WebCore/LowPowerModeNotifier.h>
 #include <WebCore/NetworkStorageSession.h>
 #include <WebCore/ResourceRequest.h>
 #include <WebCore/ResourceResponse.h>
 #include <WebCore/SharedBuffer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/RunLoop.h>
@@ -51,7 +51,7 @@
 namespace WebKit {
 namespace NetworkCache {
 
-using namespace WebCore::FileSystem;
+using namespace FileSystem;
 
 static const AtomicString& resourceType()
 {
index f73c50d..9538da6 100644 (file)
@@ -28,8 +28,8 @@
 
 #include "Logging.h"
 #include "NetworkCacheFileSystem.h"
-#include <WebCore/FileSystem.h>
 #include <fcntl.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 #include <wtf/SHA1.h>
 
@@ -57,15 +57,15 @@ void BlobStorage::synchronize()
 {
     ASSERT(!RunLoop::isMain());
 
-    WebCore::FileSystem::makeAllDirectories(blobDirectoryPath());
+    FileSystem::makeAllDirectories(blobDirectoryPath());
 
     m_approximateSize = 0;
     auto blobDirectory = blobDirectoryPath();
     traverseDirectory(blobDirectory, [this, &blobDirectory](const String& name, DirectoryEntryType type) {
         if (type != DirectoryEntryType::File)
             return;
-        auto path = WebCore::FileSystem::pathByAppendingComponent(blobDirectory, name);
-        auto filePath = WebCore::FileSystem::fileSystemRepresentation(path);
+        auto path = FileSystem::pathByAppendingComponent(blobDirectory, name);
+        auto filePath = FileSystem::fileSystemRepresentation(path);
         struct stat stat;
         ::stat(filePath.data(), &stat);
         // No clients left for this blob.
@@ -81,7 +81,7 @@ void BlobStorage::synchronize()
 String BlobStorage::blobPathForHash(const SHA1::Digest& hash) const
 {
     auto hashAsString = SHA1::hexDigest(hash);
-    return WebCore::FileSystem::pathByAppendingComponent(blobDirectoryPath(), String::fromUTF8(hashAsString));
+    return FileSystem::pathByAppendingComponent(blobDirectoryPath(), String::fromUTF8(hashAsString));
 }
 
 BlobStorage::Blob BlobStorage::add(const String& path, const Data& data)
@@ -93,8 +93,8 @@ BlobStorage::Blob BlobStorage::add(const String& path, const Data& data)
     if (data.isEmpty())
         return { data, hash };
 
-    auto blobPath = WebCore::FileSystem::fileSystemRepresentation(blobPathForHash(hash));
-    auto linkPath = WebCore::FileSystem::fileSystemRepresentation(path);
+    auto blobPath = FileSystem::fileSystemRepresentation(blobPathForHash(hash));
+    auto linkPath = FileSystem::fileSystemRepresentation(path);
     unlink(linkPath.data());
 
     bool blobExists = access(blobPath.data(), F_OK) != -1;
@@ -127,7 +127,7 @@ BlobStorage::Blob BlobStorage::get(const String& path)
 {
     ASSERT(!RunLoop::isMain());
 
-    auto linkPath = WebCore::FileSystem::fileSystemRepresentation(path);
+    auto linkPath = FileSystem::fileSystemRepresentation(path);
     auto data = mapFile(linkPath.data());
 
     return { data, computeSHA1(data, m_salt) };
@@ -137,7 +137,7 @@ void BlobStorage::remove(const String& path)
 {
     ASSERT(!RunLoop::isMain());
 
-    auto linkPath = WebCore::FileSystem::fileSystemRepresentation(path);
+    auto linkPath = FileSystem::fileSystemRepresentation(path);
     unlink(linkPath.data());
 }
 
@@ -145,7 +145,7 @@ unsigned BlobStorage::shareCount(const String& path)
 {
     ASSERT(!RunLoop::isMain());
 
-    auto linkPath = WebCore::FileSystem::fileSystemRepresentation(path);
+    auto linkPath = FileSystem::fileSystemRepresentation(path);
     struct stat stat;
     if (::stat(linkPath.data(), &stat) < 0)
         return 0;
index 9e31894..1a32aa9 100644 (file)
@@ -26,9 +26,9 @@
 #include "config.h"
 #include "NetworkCacheData.h"
 
-#include <WebCore/FileSystem.h>
 #include <fcntl.h>
 #include <wtf/CryptographicallyRandomNumber.h>
+#include <wtf/FileSystem.h>
 
 #if !OS(WINDOWS)
 #include <sys/mman.h>
@@ -156,7 +156,7 @@ static Salt makeSalt()
 Optional<Salt> readOrMakeSalt(const String& path)
 {
 #if !OS(WINDOWS)
-    auto cpath = WebCore::FileSystem::fileSystemRepresentation(path);
+    auto cpath = FileSystem::fileSystemRepresentation(path);
     auto fd = open(cpath.data(), O_RDONLY, 0);
     Salt salt;
     auto bytesRead = read(fd, salt.data(), salt.size());
index 25bef7f..b0b2e71 100644 (file)
@@ -27,8 +27,8 @@
 #include "NetworkCacheFileSystem.h"
 
 #include "Logging.h"
-#include <WebCore/FileSystem.h>
 #include <wtf/Assertions.h>
+#include <wtf/FileSystem.h>
 #include <wtf/Function.h>
 #include <wtf/text/CString.h>
 
@@ -70,7 +70,7 @@ static DirectoryEntryType directoryEntryType(uint8_t dtype)
 void traverseDirectory(const String& path, const Function<void (const String&, DirectoryEntryType)>& function)
 {
 #if !OS(WINDOWS)
-    DIR* dir = opendir(WebCore::FileSystem::fileSystemRepresentation(path).data());
+    DIR* dir = opendir(FileSystem::fileSystemRepresentation(path).data());
     if (!dir)
         return;
     dirent* dp;
@@ -94,10 +94,10 @@ void traverseDirectory(const String& path, const Function<void (const String&, D
 void deleteDirectoryRecursively(const String& path)
 {
     traverseDirectory(path, [&path](const String& name, DirectoryEntryType type) {
-        String entryPath = WebCore::FileSystem::pathByAppendingComponent(path, name);
+        String entryPath = FileSystem::pathByAppendingComponent(path, name);
         switch (type) {
         case DirectoryEntryType::File:
-            WebCore::FileSystem::deleteFile(entryPath);
+            FileSystem::deleteFile(entryPath);
             break;
         case DirectoryEntryType::Directory:
             deleteDirectoryRecursively(entryPath);
@@ -105,19 +105,19 @@ void deleteDirectoryRecursively(const String& path)
         // This doesn't follow symlinks.
         }
     });
-    WebCore::FileSystem::deleteEmptyDirectory(path);
+    FileSystem::deleteEmptyDirectory(path);
 }
 
 FileTimes fileTimes(const String& path)
 {
 #if HAVE(STAT_BIRTHTIME)
     struct stat fileInfo;
-    if (stat(WebCore::FileSystem::fileSystemRepresentation(path).data(), &fileInfo))
+    if (stat(FileSystem::fileSystemRepresentation(path).data(), &fileInfo))
         return { };
     return { WallTime::fromRawSeconds(fileInfo.st_birthtime), WallTime::fromRawSeconds(fileInfo.st_mtime) };
 #elif USE(SOUP)
     // There's no st_birthtime in some operating systems like Linux, so we use xattrs to set/get the creation time.
-    GRefPtr<GFile> file = adoptGRef(g_file_new_for_path(WebCore::FileSystem::fileSystemRepresentation(path).data()));
+    GRefPtr<GFile> file = adoptGRef(g_file_new_for_path(FileSystem::fileSystemRepresentation(path).data()));
     GRefPtr<GFileInfo> fileInfo = adoptGRef(g_file_query_info(file.get(), "xattr::birthtime,time::modified", G_FILE_QUERY_INFO_NONE, nullptr, nullptr));
     if (!fileInfo)
         return { };
@@ -141,7 +141,7 @@ void updateFileModificationTimeIfNeeded(const String& path)
     }
 #if !OS(WINDOWS)
     // This really updates both the access time and the modification time.
-    utimes(WebCore::FileSystem::fileSystemRepresentation(path).data(), nullptr);
+    utimes(FileSystem::fileSystemRepresentation(path).data(), nullptr);
 #endif
 }
 
@@ -156,7 +156,7 @@ bool isSafeToUseMemoryMapForPath(const String& path)
     attrlist attrList = { };
     attrList.bitmapcount = ATTR_BIT_MAP_COUNT;
     attrList.commonattr = ATTR_CMN_DATA_PROTECT_FLAGS;
-    int32_t error = getattrlist(WebCore::FileSystem::fileSystemRepresentation(path).data(), &attrList, &attrBuffer, sizeof(attrBuffer), FSOPT_NOFOLLOW);
+    int32_t error = getattrlist(FileSystem::fileSystemRepresentation(path).data(), &attrList, &attrBuffer, sizeof(attrBuffer), FSOPT_NOFOLLOW);
     if (error) {
         RELEASE_LOG_ERROR(Network, "Unable to get cache directory protection class, disabling use of shared mapped memory");
         return false;
index 7dcce6c..1831a35 100644 (file)
@@ -25,7 +25,7 @@
 
 #pragma once
 
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
 namespace NetworkCache {
index 369bcf9..c652164 100644 (file)
@@ -41,7 +41,7 @@ IOChannel::IOChannel(const String& filePath, Type type)
     : m_path(filePath)
     , m_type(type)
 {
-    auto path = WebCore::FileSystem::fileSystemRepresentation(filePath);
+    auto path = FileSystem::fileSystemRepresentation(filePath);
     int oflag;
     mode_t mode;
     bool useLowIOPriority = false;
index 5392c79..b56f965 100644 (file)
@@ -41,7 +41,7 @@ IOChannel::IOChannel(const String& filePath, Type type)
     : m_path(filePath)
     , m_type(type)
 {
-    auto path = WebCore::FileSystem::fileSystemRepresentation(filePath);
+    auto path = FileSystem::fileSystemRepresentation(filePath);
     GRefPtr<GFile> file = adoptGRef(g_file_new_for_path(path.data()));
     switch (m_type) {
     case Type::Create: {
index b4a1314..61bef1e 100644 (file)
@@ -77,7 +77,7 @@ std::unique_ptr<Statistics> Statistics::open(Cache& cache, const String& cachePa
 {
     ASSERT(RunLoop::isMain());
 
-    String databasePath = WebCore::FileSystem::pathByAppendingComponent(cachePath, StatisticsDatabaseName);
+    String databasePath = FileSystem::pathByAppendingComponent(cachePath, StatisticsDatabaseName);
     return std::make_unique<Statistics>(cache, databasePath);
 }
 
@@ -98,7 +98,7 @@ void Statistics::initialize(const String& databasePath)
     serialBackgroundIOQueue().dispatch([this, databasePath = databasePath.isolatedCopy(), networkCachePath = m_cache.recordsPath(), startTime] {
         WebCore::SQLiteTransactionInProgressAutoCounter transactionCounter;
 
-        if (!WebCore::FileSystem::makeAllDirectories(WebCore::FileSystem::directoryName(databasePath)))
+        if (!FileSystem::makeAllDirectories(FileSystem::directoryName(databasePath)))
             return;
 
         LOG(NetworkCache, "(NetworkProcess) Opening network cache statistics database at %s...", databasePath.utf8().data());
index 4ea7430..c26aa1b 100644 (file)
@@ -145,29 +145,29 @@ public:
 static String makeVersionedDirectoryPath(const String& baseDirectoryPath)
 {
     String versionSubdirectory = versionDirectoryPrefix + String::number(Storage::version);
-    return WebCore::FileSystem::pathByAppendingComponent(baseDirectoryPath, versionSubdirectory);
+    return FileSystem::pathByAppendingComponent(baseDirectoryPath, versionSubdirectory);
 }
 
 static String makeRecordsDirectoryPath(const String& baseDirectoryPath)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), recordsDirectoryName);
+    return FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), recordsDirectoryName);
 }
 
 static String makeBlobDirectoryPath(const String& baseDirectoryPath)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), blobsDirectoryName);
+    return FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), blobsDirectoryName);
 }
 
 static String makeSaltFilePath(const String& baseDirectoryPath)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), saltFileName);
+    return FileSystem::pathByAppendingComponent(makeVersionedDirectoryPath(baseDirectoryPath), saltFileName);
 }
 
 RefPtr<Storage> Storage::open(const String& cachePath, Mode mode)
 {
     ASSERT(RunLoop::isMain());
 
-    if (!WebCore::FileSystem::makeAllDirectories(makeVersionedDirectoryPath(cachePath)))
+    if (!FileSystem::makeAllDirectories(makeVersionedDirectoryPath(cachePath)))
         return nullptr;
     auto salt = readOrMakeSalt(makeSaltFilePath(cachePath));
     if (!salt)
@@ -180,13 +180,13 @@ void traverseRecordsFiles(const String& recordsPath, const String& expectedType,
     traverseDirectory(recordsPath, [&](const String& partitionName, DirectoryEntryType entryType) {
         if (entryType != DirectoryEntryType::Directory)
             return;
-        String partitionPath = WebCore::FileSystem::pathByAppendingComponent(recordsPath, partitionName);
+        String partitionPath = FileSystem::pathByAppendingComponent(recordsPath, partitionName);
         traverseDirectory(partitionPath, [&](const String& actualType, DirectoryEntryType entryType) {
             if (entryType != DirectoryEntryType::Directory)
                 return;
             if (!expectedType.isEmpty() && expectedType != actualType)
                 return;
-            String recordDirectoryPath = WebCore::FileSystem::pathByAppendingComponent(partitionPath, actualType);
+            String recordDirectoryPath = FileSystem::pathByAppendingComponent(partitionPath, actualType);
             traverseDirectory(recordDirectoryPath, [&function, &recordDirectoryPath, &actualType](const String& fileName, DirectoryEntryType entryType) {
                 if (entryType != DirectoryEntryType::File || fileName.length() < Key::hashStringLength())
                     return;
@@ -206,18 +206,18 @@ static void deleteEmptyRecordsDirectories(const String& recordsPath)
             return;
 
         // Delete [type] sub-folders.
-        String partitionPath = WebCore::FileSystem::pathByAppendingComponent(recordsPath, partitionName);
+        String partitionPath = FileSystem::pathByAppendingComponent(recordsPath, partitionName);
         traverseDirectory(partitionPath, [&partitionPath](const String& subdirName, DirectoryEntryType entryType) {
             if (entryType != DirectoryEntryType::Directory)
                 return;
 
             // Let system figure out if it is really empty.
-            WebCore::FileSystem::deleteEmptyDirectory(WebCore::FileSystem::pathByAppendingComponent(partitionPath, subdirName));
+            FileSystem::deleteEmptyDirectory(FileSystem::pathByAppendingComponent(partitionPath, subdirName));
         });
 
         // Delete [Partition] folders.
         // Let system figure out if it is really empty.
-        WebCore::FileSystem::deleteEmptyDirectory(WebCore::FileSystem::pathByAppendingComponent(recordsPath, partitionName));
+        FileSystem::deleteEmptyDirectory(FileSystem::pathByAppendingComponent(recordsPath, partitionName));
     });
 }
 
@@ -300,11 +300,11 @@ void Storage::synchronize()
 
         String anyType;
         traverseRecordsFiles(recordsPath(), anyType, [&](const String& fileName, const String& hashString, const String& type, bool isBlob, const String& recordDirectoryPath) {
-            auto filePath = WebCore::FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
+            auto filePath = FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
 
             Key::HashType hash;
             if (!Key::stringToHash(hashString, hash)) {
-                WebCore::FileSystem::deleteFile(filePath);
+                FileSystem::deleteFile(filePath);
                 return;
             }
 
@@ -318,7 +318,7 @@ void Storage::synchronize()
 
             if (shouldComputeExactRecordsSize) {
                 long long fileSize = 0;
-                WebCore::FileSystem::getFileSize(filePath, fileSize);
+                FileSystem::getFileSize(filePath, fileSize);
                 recordsSize += fileSize;
             }
 
@@ -381,12 +381,12 @@ bool Storage::mayContainBlob(const Key& key) const
 String Storage::recordDirectoryPathForKey(const Key& key) const
 {
     ASSERT(!key.type().isEmpty());
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::pathByAppendingComponent(recordsPath(), key.partitionHashAsString()), key.type());
+    return FileSystem::pathByAppendingComponent(FileSystem::pathByAppendingComponent(recordsPath(), key.partitionHashAsString()), key.type());
 }
 
 String Storage::recordPathForKey(const Key& key) const
 {
-    return WebCore::FileSystem::pathByAppendingComponent(recordDirectoryPathForKey(key), key.hashAsString());
+    return FileSystem::pathByAppendingComponent(recordDirectoryPathForKey(key), key.hashAsString());
 }
 
 static String blobPathForRecordPath(const String& recordPath)
@@ -629,7 +629,7 @@ void Storage::deleteFiles(const Key& key)
 {
     ASSERT(!RunLoop::isMain());
 
-    WebCore::FileSystem::deleteFile(recordPathForKey(key));
+    FileSystem::deleteFile(recordPathForKey(key));
     m_blobStorage.remove(blobPathForKey(key));
 }
 
@@ -809,7 +809,7 @@ void Storage::dispatchWriteOperation(std::unique_ptr<WriteOperation> writeOperat
         auto recordDirectorPath = recordDirectoryPathForKey(writeOperation.record.key);
         auto recordPath = recordPathForKey(writeOperation.record.key);
 
-        WebCore::FileSystem::makeAllDirectories(recordDirectorPath);
+        FileSystem::makeAllDirectories(recordDirectorPath);
 
         ++writeOperation.activeCount;
 
@@ -917,7 +917,7 @@ void Storage::traverse(const String& type, OptionSet<TraverseFlag> flags, Traver
             if (isBlob)
                 return;
 
-            auto recordPath = WebCore::FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
+            auto recordPath = FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
 
             double worth = -1;
             if (traverseOperation.flags & TraverseFlag::ComputeWorth)
@@ -1009,13 +1009,13 @@ void Storage::clear(const String& type, WallTime modifiedSinceTime, CompletionHa
     ioQueue().dispatch([this, protectedThis = makeRef(*this), modifiedSinceTime, completionHandler = WTFMove(completionHandler), type = type.isolatedCopy()] () mutable {
         auto recordsPath = this->recordsPath();
         traverseRecordsFiles(recordsPath, type, [modifiedSinceTime](const String& fileName, const String& hashString, const String& type, bool isBlob, const String& recordDirectoryPath) {
-            auto filePath = WebCore::FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
+            auto filePath = FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
             if (modifiedSinceTime > -WallTime::infinity()) {
                 auto times = fileTimes(filePath);
                 if (times.modification < modifiedSinceTime)
                     return;
             }
-            WebCore::FileSystem::deleteFile(filePath);
+            FileSystem::deleteFile(filePath);
         });
 
         deleteEmptyRecordsDirectories(recordsPath);
@@ -1089,7 +1089,7 @@ void Storage::shrink()
             if (isBlob)
                 return;
 
-            auto recordPath = WebCore::FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
+            auto recordPath = FileSystem::pathByAppendingComponent(recordDirectoryPath, fileName);
             auto blobPath = blobPathForRecordPath(recordPath);
 
             auto times = fileTimes(recordPath);
@@ -1101,7 +1101,7 @@ void Storage::shrink()
             LOG(NetworkCacheStorage, "Deletion probability=%f bodyLinkCount=%d shouldDelete=%d", probability, bodyShareCount, shouldDelete);
 
             if (shouldDelete) {
-                WebCore::FileSystem::deleteFile(recordPath);
+                FileSystem::deleteFile(recordPath);
                 m_blobStorage.remove(blobPath);
             }
         });
@@ -1137,7 +1137,7 @@ void Storage::deleteOldVersions()
                 return;
 #endif
 
-            auto oldVersionPath = WebCore::FileSystem::pathByAppendingComponent(cachePath, subdirName);
+            auto oldVersionPath = FileSystem::pathByAppendingComponent(cachePath, subdirName);
             LOG(NetworkCacheStorage, "(NetworkProcess) deleting old cache version, path %s", oldVersionPath.utf8().data());
 
             deleteDirectoryRecursively(oldVersionPath);
index a61f938..f47bd81 100644 (file)
 #import "NetworkSessionCocoa.h"
 #import "WebCoreArgumentCoders.h"
 #import <WebCore/AuthenticationChallenge.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/NetworkStorageSession.h>
 #import <WebCore/NotImplemented.h>
 #import <WebCore/ResourceRequest.h>
 #import <pal/spi/cf/CFNetworkSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/MainThread.h>
 #import <wtf/ProcessPrivilege.h>
 #import <wtf/text/Base64.h>
@@ -403,8 +403,8 @@ void NetworkDataTaskCocoa::setPendingDownloadLocation(const WTF::String& filenam
 
     m_task.get()._pathToDownloadTaskFile = m_pendingDownloadLocation;
 
-    if (allowOverwrite && WebCore::FileSystem::fileExists(m_pendingDownloadLocation))
-        WebCore::FileSystem::deleteFile(filename);
+    if (allowOverwrite && FileSystem::fileExists(m_pendingDownloadLocation))
+        FileSystem::deleteFile(filename);
 }
 
 bool NetworkDataTaskCocoa::tryPasswordBasedAuthentication(const WebCore::AuthenticationChallenge& challenge, ChallengeCompletionHandler& completionHandler)
index f6ad49f..4a1d792 100644 (file)
@@ -779,7 +779,7 @@ static NSURLRequest* updateIgnoreStrictTransportSecuritySettingIfNecessary(NSURL
         auto& downloadManager = _session->networkProcess().downloadManager();
         auto download = std::make_unique<WebKit::Download>(downloadManager, downloadID, downloadTask, _session->sessionID(), networkDataTask->suggestedFilename());
         networkDataTask->transferSandboxExtensionToDownload(*download);
-        ASSERT(WebCore::FileSystem::fileExists(networkDataTask->pendingDownloadLocation()));
+        ASSERT(FileSystem::fileExists(networkDataTask->pendingDownloadLocation()));
         download->didCreateDestination(networkDataTask->pendingDownloadLocation());
         downloadManager.dataTaskBecameDownloadTask(downloadID, WTFMove(download));
 
index 37f3b7f..f5bf04a 100644 (file)
 #import "StringUtilities.h"
 #import "WKFoundation.h"
 #import <WebCore/CertificateInfo.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/LocalizedStrings.h>
 #import <notify.h>
 #import <pal/spi/cf/CFNetworkSPI.h>
 #import <pal/spi/cocoa/LaunchServicesSPI.h>
 #import <sysexits.h>
+#import <wtf/FileSystem.h>
 #import <wtf/MemoryPressureHandler.h>
 #import <wtf/text/WTFString.h>
 
index acb92c6..72fb654 100644 (file)
 #include "ResourceCachesToClear.h"
 #include "WebCookieManager.h"
 #include <WebCore/CertificateInfo.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/NetworkStorageSession.h>
 #include <WebCore/NotImplemented.h>
 #include <WebCore/ResourceHandle.h>
 #include <WebCore/SoupNetworkSession.h>
 #include <libsoup/soup.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RAMSize.h>
 #include <wtf/glib/GRefPtr.h>
 #include <wtf/glib/GUniquePtr.h>
@@ -108,7 +108,7 @@ void NetworkProcess::platformInitializeNetworkProcess(const NetworkProcessCreati
     ASSERT(!parameters.diskCacheDirectory.isEmpty());
     m_diskCacheDirectory = parameters.diskCacheDirectory;
 
-    SoupNetworkSession::clearOldSoupCache(WebCore::FileSystem::directoryName(m_diskCacheDirectory));
+    SoupNetworkSession::clearOldSoupCache(FileSystem::directoryName(m_diskCacheDirectory));
 
     OptionSet<NetworkCache::Cache::Option> cacheOptions { NetworkCache::Cache::Option::RegisterNotify };
     if (parameters.shouldEnableNetworkCacheEfficacyLogging)
index 2bd2ed5..3ade4c9 100644 (file)
@@ -34,8 +34,8 @@
 #include "Logging.h"
 #include "NetscapePlugin.h"
 #include "PluginProcess.h"
-#include <WebCore/FileSystem.h>
 #include <stdlib.h>
+#include <wtf/FileSystem.h>
 
 #if PLATFORM(GTK)
 #include <gtk/gtk.h>
index 5dba968..eca9641 100644 (file)
@@ -27,8 +27,8 @@
 #include "PersistencyUtils.h"
 
 #include "Logging.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/SharedBuffer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 
 namespace WebKit {
index fb1d9dc..eec4761 100644 (file)
 
 #include "NetscapeBrowserFuncs.h"
 #include "PluginProcessProxy.h"
-#include <WebCore/FileSystem.h>
 #include <errno.h>
 #include <fcntl.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <unistd.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/StringBuilder.h>
 
 namespace WebKit {
index e8af960..2bd549a 100644 (file)
@@ -26,7 +26,7 @@
 #include "config.h"
 #include "PluginSearchPath.h"
 
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
 using namespace WebCore;
index 80813fe..721cdbf 100644 (file)
@@ -52,8 +52,8 @@
 #if ENABLE(MEMORY_SAMPLER)
 
 #include "SandboxExtension.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/Timer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/Noncopyable.h>
 #include <wtf/RefPtr.h>
 #include <wtf/Vector.h>
@@ -87,7 +87,7 @@ private:
     void initializeTimers(double);
     void sampleTimerFired();
     void stopTimerFired();
-    void appendCurrentMemoryUsageToFile(WebCore::FileSystem::PlatformFileHandle&);
+    void appendCurrentMemoryUsageToFile(FileSystem::PlatformFileHandle&);
     void sendMemoryPressureEvent();
     
     SystemMallocStats sampleSystemMalloc() const;
@@ -95,7 +95,7 @@ private:
     WebMemoryStatistics sampleWebKit() const;
     String processName() const;
     
-    WebCore::FileSystem::PlatformFileHandle m_sampleLogFile { WebCore::FileSystem::invalidPlatformFileHandle };
+    FileSystem::PlatformFileHandle m_sampleLogFile { FileSystem::invalidPlatformFileHandle };
     String m_sampleLogFilePath;
     WebCore::Timer m_sampleTimer;
     WebCore::Timer m_stopTimer;
index a70b41a..4ff35d3 100644 (file)
 #include "config.h"
 #include "ProcessExecutablePath.h"
 
-#include <WebCore/FileSystem.h>
 #include <glib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GLibUtilities.h>
 
 namespace WebKit {
-using namespace WebCore;
 
 #if ENABLE(DEVELOPER_MODE)
 static String getExecutablePath()
index 81d54f3..69d53cf 100644 (file)
@@ -31,7 +31,6 @@
 
 #import "SandboxInitializationParameters.h"
 #import "XPCServiceEntryPoint.h"
-#import <WebCore/FileSystem.h>
 #import <WebCore/FloatingPointEnvironment.h>
 #import <WebCore/SystemVersion.h>
 #import <mach/mach.h>
@@ -39,6 +38,7 @@
 #import <pwd.h>
 #import <stdlib.h>
 #import <sysexits.h>
+#import <wtf/FileSystem.h>
 
 #if ENABLE(MANUAL_SANDBOXING)
 #import <wtf/spi/darwin/SandboxSPI.h>
index 3c394cc..78536aa 100644 (file)
@@ -35,7 +35,6 @@
 #import "WKFoundation.h"
 #import "XPCServiceEntryPoint.h"
 #import <WebCore/FileHandle.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/SystemVersion.h>
 #import <mach-o/dyld.h>
 #import <mach/mach.h>
@@ -47,6 +46,7 @@
 #import <sys/sysctl.h>
 #import <sysexits.h>
 #import <wtf/DataLog.h>
+#import <wtf/FileSystem.h>
 #import <wtf/RandomNumber.h>
 #import <wtf/Scope.h>
 #import <wtf/SystemTracing.h>
index 0cec985..afbc6b2 100644 (file)
 #import "DataReference.h"
 #import "Decoder.h"
 #import "Encoder.h"
-#import <WebCore/FileSystem.h>
 #import <sys/stat.h>
+#import <wtf/FileSystem.h>
 #import <wtf/spi/darwin/SandboxSPI.h>
 #import <wtf/text/CString.h>
 
 namespace WebKit {
-using namespace WebCore;
 
 class SandboxExtensionImpl {
 public:
index 38f42cb..c767e28 100644 (file)
@@ -39,6 +39,7 @@
 #include <WebCore/QualifiedName.h>
 #include <string>
 #include <wtf/CompletionHandler.h>
+#include <wtf/FileSystem.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/RunLoop.h>
 #include <wtf/WorkQueue.h>
@@ -48,7 +49,7 @@
 
 namespace API {
 using namespace WebKit::NetworkCache;
-using namespace WebCore::FileSystem;
+using namespace FileSystem;
 
 ContentRuleListStore& ContentRuleListStore::legacyDefaultStore()
 {
index 4a2ec38..3884f43 100644 (file)
@@ -28,9 +28,8 @@
 
 #include "SandboxExtension.h"
 #include "SandboxUtilities.h"
-
 #include <Foundation/Foundation.h>
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 #if PLATFORM(IOS_FAMILY)
 #import <WebCore/RuntimeApplicationChecks.h>
@@ -169,7 +168,7 @@ WTF::String WebsiteDataStore::legacyDefaultIndexedDBDatabaseDirectory()
     // Currently, the top level of that directory contains entities related to WebSQL databases.
     // We should fix this, and move WebSQL into a subdirectory (https://bugs.webkit.org/show_bug.cgi?id=124807)
     // In the meantime, an entity name prefixed with three underscores will not conflict with any WebSQL entities.
-    return WebCore::FileSystem::pathByAppendingComponent(legacyDefaultWebSQLDatabaseDirectory(), "___IndexedDB");
+    return FileSystem::pathByAppendingComponent(legacyDefaultWebSQLDatabaseDirectory(), "___IndexedDB");
 }
 
 WTF::String WebsiteDataStore::legacyDefaultLocalStorageDirectory()
index e1c4529..f5ab931 100644 (file)
@@ -26,7 +26,7 @@
 #include "config.h"
 #include "APIWebsiteDataStore.h"
 
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GUniquePtr.h>
 
 #if PLATFORM(GTK)
@@ -46,12 +46,12 @@ WTF::String WebsiteDataStore::defaultApplicationCacheDirectory()
 // Why is only this directory namespaced to a particular application?
 WTF::String WebsiteDataStore::defaultNetworkCacheDirectory()
 {
-    return cacheDirectoryFileSystemRepresentation(WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(g_get_prgname()), "WebKitCache"));
+    return cacheDirectoryFileSystemRepresentation(FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(g_get_prgname()), "WebKitCache"));
 }
 
 WTF::String WebsiteDataStore::defaultCacheStorageDirectory()
 {
-    return cacheDirectoryFileSystemRepresentation(WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(g_get_prgname()), "CacheStorage"));
+    return cacheDirectoryFileSystemRepresentation(FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(g_get_prgname()), "CacheStorage"));
 }
 
 WTF::String WebsiteDataStore::defaultIndexedDBDatabaseDirectory()
@@ -91,19 +91,19 @@ WTF::String WebsiteDataStore::defaultResourceLoadStatisticsDirectory()
 
 WTF::String WebsiteDataStore::cacheDirectoryFileSystemRepresentation(const WTF::String& directoryName)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(g_get_user_cache_dir()), directoryName);
+    return FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(g_get_user_cache_dir()), directoryName);
 }
 
 WTF::String WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation(const WTF::String& directoryName)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(g_get_user_data_dir()), directoryName);
+    return FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(g_get_user_data_dir()), directoryName);
 }
 
 WTF::String WebsiteDataStore::legacyDefaultApplicationCacheDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> cacheDirectory(g_build_filename(g_get_user_cache_dir(), "wpe", "appcache", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(cacheDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(cacheDirectory.get());
 #endif
     return defaultApplicationCacheDirectory();
 }
@@ -112,7 +112,7 @@ WTF::String WebsiteDataStore::legacyDefaultNetworkCacheDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<char> diskCacheDirectory(g_build_filename(g_get_user_cache_dir(), "wpe", "cache", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(diskCacheDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(diskCacheDirectory.get());
 #endif
     return defaultNetworkCacheDirectory();
 }
@@ -121,7 +121,7 @@ WTF::String WebsiteDataStore::legacyDefaultWebSQLDatabaseDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> databaseDirectory(g_build_filename(g_get_user_data_dir(), "wpe", "databases", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(databaseDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(databaseDirectory.get());
 #endif
     return defaultWebSQLDatabaseDirectory();
 }
@@ -130,7 +130,7 @@ WTF::String WebsiteDataStore::legacyDefaultIndexedDBDatabaseDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> indexedDBDatabaseDirectory(g_build_filename(g_get_user_data_dir(), "wpe", "databases", "indexeddb", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(indexedDBDatabaseDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(indexedDBDatabaseDirectory.get());
 #endif
     return defaultIndexedDBDatabaseDirectory();
 }
@@ -139,7 +139,7 @@ WTF::String WebsiteDataStore::legacyDefaultLocalStorageDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> storageDirectory(g_build_filename(g_get_user_data_dir(), "wpe", "localstorage", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(storageDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(storageDirectory.get());
 #endif
     return defaultLocalStorageDirectory();
 }
@@ -148,7 +148,7 @@ WTF::String WebsiteDataStore::legacyDefaultMediaCacheDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> cacheDirectory(g_build_filename(g_get_user_cache_dir(), "wpe", "mediacache", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(cacheDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(cacheDirectory.get());
 #endif
     return defaultMediaCacheDirectory();
 }
@@ -157,7 +157,7 @@ WTF::String WebsiteDataStore::legacyDefaultMediaKeysStorageDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> mediaKeysStorageDirectory(g_build_filename(g_get_user_data_dir(), "wpe", "mediakeys", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(mediaKeysStorageDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(mediaKeysStorageDirectory.get());
 #endif
     return defaultMediaKeysStorageDirectory();
 }
@@ -166,7 +166,7 @@ String WebsiteDataStore::legacyDefaultDeviceIdHashSaltsStorageDirectory()
 {
 #if PLATFORM(WPE)
     GUniquePtr<gchar> deviceIdHashSaltsStorageDirectory(g_build_filename(g_get_user_data_dir(), "wpe", "deviceidhashsalts", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(deviceIdHashSaltsStorageDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(deviceIdHashSaltsStorageDirectory.get());
 #endif
     return defaultDeviceIdHashSaltsStorageDirectory();
 }
@@ -174,7 +174,7 @@ String WebsiteDataStore::legacyDefaultDeviceIdHashSaltsStorageDirectory()
 WTF::String WebsiteDataStore::legacyDefaultJavaScriptConfigurationDirectory()
 {
     GUniquePtr<gchar> javaScriptCoreConfigDirectory(g_build_filename(g_get_user_data_dir(), BASE_DIRECTORY, "JavaScriptCoreDebug", nullptr));
-    return WebCore::FileSystem::stringFromFileSystemRepresentation(javaScriptCoreConfigDirectory.get());
+    return FileSystem::stringFromFileSystemRepresentation(javaScriptCoreConfigDirectory.get());
 }
 
 Ref<WebKit::WebsiteDataStoreConfiguration> WebsiteDataStore::defaultDataStoreConfiguration()
index 674a5db..b0466e9 100644 (file)
 
 #include "Logging.h"
 #include <WebCore/BitmapImage.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/Image.h>
 #include <WebCore/SQLiteStatement.h>
 #include <WebCore/SQLiteTransaction.h>
 #include <WebCore/SharedBuffer.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/NeverDestroyed.h>
 #include <wtf/StdLibExtras.h>
index 9be7253..e016486 100644 (file)
 #include "IconDatabase.h"
 #include "WebKitFaviconDatabasePrivate.h"
 #include "WebPreferences.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/Image.h>
 #include <WebCore/IntSize.h>
 #include <WebCore/RefPtrCairo.h>
 #include <WebCore/SharedBuffer.h>
 #include <glib/gi18n-lib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 #include <wtf/SetForScope.h>
 #include <wtf/glib/GRefPtr.h>
@@ -273,7 +273,7 @@ void webkitFaviconDatabaseOpen(WebKitFaviconDatabase* database, const String& pa
     priv->iconDatabase->setEnabled(true);
     priv->iconDatabase->setPrivateBrowsingEnabled(WebPreferences::anyPagesAreUsingPrivateBrowsing());
 
-    if (!priv->iconDatabase->open(WebCore::FileSystem::directoryName(path), WebCore::FileSystem::pathGetFileName(path))) {
+    if (!priv->iconDatabase->open(FileSystem::directoryName(path), FileSystem::pathGetFileName(path))) {
         priv->iconDatabase = nullptr;
         IconDatabase::allowDatabaseCleanup();
     }
index 37e6cca..09980aa 100644 (file)
@@ -25,9 +25,9 @@
 #include "APIString.h"
 #include "WebKitFileChooserRequestPrivate.h"
 #include "WebOpenPanelResultListenerProxy.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/TextEncoding.h>
 #include <glib/gi18n-lib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/URL.h>
 #include <wtf/glib/GRefPtr.h>
 #include <wtf/glib/GUniquePtr.h>
index 9bc7f67..f1e18dd 100644 (file)
 #include "WebNotificationManagerProxy.h"
 #include "WebsiteDataType.h"
 #include <JavaScriptCore/RemoteInspector.h>
-#include <WebCore/FileSystem.h>
 #include <glib/gi18n-lib.h>
 #include <libintl.h>
 #include <memory>
+#include <wtf/FileSystem.h>
 #include <wtf/HashMap.h>
 #include <wtf/Language.h>
 #include <wtf/NeverDestroyed.h>
@@ -333,19 +333,19 @@ static void webkitWebContextConstructed(GObject* object)
     GUniquePtr<char> bundleFilename(g_build_filename(injectedBundleDirectory(), INJECTED_BUNDLE_FILENAME, nullptr));
 
     API::ProcessPoolConfiguration configuration;
-    configuration.setInjectedBundlePath(WebCore::FileSystem::stringFromFileSystemRepresentation(bundleFilename.get()));
+    configuration.setInjectedBundlePath(FileSystem::stringFromFileSystemRepresentation(bundleFilename.get()));
     configuration.setDiskCacheSpeculativeValidationEnabled(true);
 
     WebKitWebContext* webContext = WEBKIT_WEB_CONTEXT(object);
     WebKitWebContextPrivate* priv = webContext->priv;
     if (priv->websiteDataManager && !webkit_website_data_manager_is_ephemeral(priv->websiteDataManager.get())) {
-        configuration.setLocalStorageDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_local_storage_directory(priv->websiteDataManager.get())));
-        configuration.setDiskCacheDirectory(WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_disk_cache_directory(priv->websiteDataManager.get())), networkCacheSubdirectory));
-        configuration.setApplicationCacheDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_offline_application_cache_directory(priv->websiteDataManager.get())));
-        configuration.setIndexedDBDatabaseDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_indexeddb_directory(priv->websiteDataManager.get())));
-        configuration.setWebSQLDatabaseDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_websql_directory(priv->websiteDataManager.get())));
+        configuration.setLocalStorageDirectory(FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_local_storage_directory(priv->websiteDataManager.get())));
+        configuration.setDiskCacheDirectory(FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_disk_cache_directory(priv->websiteDataManager.get())), networkCacheSubdirectory));
+        configuration.setApplicationCacheDirectory(FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_offline_application_cache_directory(priv->websiteDataManager.get())));
+        configuration.setIndexedDBDatabaseDirectory(FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_indexeddb_directory(priv->websiteDataManager.get())));
+        configuration.setWebSQLDatabaseDirectory(FileSystem::stringFromFileSystemRepresentation(webkit_website_data_manager_get_websql_directory(priv->websiteDataManager.get())));
     } else if (!priv->localStorageDirectory.isNull())
-        configuration.setLocalStorageDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(priv->localStorageDirectory.data()));
+        configuration.setLocalStorageDirectory(FileSystem::stringFromFileSystemRepresentation(priv->localStorageDirectory.data()));
 
     priv->processPool = WebProcessPool::create(configuration);
 
@@ -923,7 +923,7 @@ void webkit_web_context_set_favicon_database_directory(WebKitWebContext* context
     WebKitWebContextPrivate* priv = context->priv;
     ensureFaviconDatabase(context);
 
-    String directoryPath = WebCore::FileSystem::stringFromFileSystemRepresentation(path);
+    String directoryPath = FileSystem::stringFromFileSystemRepresentation(path);
     // Use default if nullptr is passed as parameter.
     if (directoryPath.isEmpty()) {
 #if PLATFORM(GTK)
@@ -932,7 +932,7 @@ void webkit_web_context_set_favicon_database_directory(WebKitWebContext* context
         const char* portDirectory = "wpe";
 #endif
         GUniquePtr<gchar> databaseDirectory(g_build_filename(g_get_user_cache_dir(), portDirectory, "icondatabase", nullptr));
-        directoryPath = WebCore::FileSystem::stringFromFileSystemRepresentation(databaseDirectory.get());
+        directoryPath = FileSystem::stringFromFileSystemRepresentation(databaseDirectory.get());
     }
     priv->faviconDatabaseDirectory = directoryPath.utf8();
 
@@ -941,7 +941,7 @@ void webkit_web_context_set_favicon_database_directory(WebKitWebContext* context
         "WebpageIcons.db", nullptr));
 
     // Setting the path will cause the icon database to be opened.
-    webkitFaviconDatabaseOpen(priv->faviconDatabase.get(), WebCore::FileSystem::stringFromFileSystemRepresentation(faviconDatabasePath.get()));
+    webkitFaviconDatabaseOpen(priv->faviconDatabase.get(), FileSystem::stringFromFileSystemRepresentation(faviconDatabasePath.get()));
 
     if (webkit_web_context_is_ephemeral(context))
         webkitFaviconDatabaseSetPrivateBrowsingEnabled(priv->faviconDatabase.get(), true);
@@ -1025,7 +1025,7 @@ void webkit_web_context_set_additional_plugins_directory(WebKitWebContext* conte
     g_return_if_fail(directory);
 
 #if ENABLE(NETSCAPE_PLUGIN_API)
-    context->priv->processPool->setAdditionalPluginsDirectory(WebCore::FileSystem::stringFromFileSystemRepresentation(directory));
+    context->priv->processPool->setAdditionalPluginsDirectory(FileSystem::stringFromFileSystemRepresentation(directory));
 #endif
 }
 
@@ -1417,7 +1417,7 @@ void webkit_web_context_set_disk_cache_directory(WebKitWebContext* context, cons
     g_return_if_fail(WEBKIT_IS_WEB_CONTEXT(context));
     g_return_if_fail(directory);
 
-    context->priv->processPool->configuration().setDiskCacheDirectory(WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(directory), networkCacheSubdirectory));
+    context->priv->processPool->configuration().setDiskCacheDirectory(FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(directory), networkCacheSubdirectory));
 }
 #endif
 
index 7e1d14b..1cc0654 100644 (file)
@@ -26,8 +26,8 @@
 #include "WebKitWebsiteDataManagerPrivate.h"
 #include "WebKitWebsiteDataPrivate.h"
 #include "WebsiteDataFetchOption.h"
-#include <WebCore/FileSystem.h>
 #include <glib/gi18n-lib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GUniquePtr.h>
 #include <wtf/glib/WTFGType.h>
 
@@ -363,13 +363,13 @@ API::WebsiteDataStore& webkitWebsiteDataManagerGetDataStore(WebKitWebsiteDataMan
     if (!priv->websiteDataStore) {
         auto configuration = WebsiteDataStoreConfiguration::create();
         configuration->setLocalStorageDirectory(!priv->localStorageDirectory ?
-            API::WebsiteDataStore::defaultLocalStorageDirectory() : WebCore::FileSystem::stringFromFileSystemRepresentation(priv->localStorageDirectory.get()));
+            API::WebsiteDataStore::defaultLocalStorageDirectory() : FileSystem::stringFromFileSystemRepresentation(priv->localStorageDirectory.get()));
         configuration->setNetworkCacheDirectory(!priv->diskCacheDirectory ?
-            API::WebsiteDataStore::defaultNetworkCacheDirectory() : WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::stringFromFileSystemRepresentation(priv->diskCacheDirectory.get()), networkCacheSubdirectory));
+            API::WebsiteDataStore::defaultNetworkCacheDirectory() : FileSystem::pathByAppendingComponent(FileSystem::stringFromFileSystemRepresentation(priv->diskCacheDirectory.get()), networkCacheSubdirectory));
         configuration->setApplicationCacheDirectory(!priv->applicationCacheDirectory ?
-            API::WebsiteDataStore::defaultApplicationCacheDirectory() : WebCore::FileSystem::stringFromFileSystemRepresentation(priv->applicationCacheDirectory.get()));
+            API::WebsiteDataStore::defaultApplicationCacheDirectory() : FileSystem::stringFromFileSystemRepresentation(priv->applicationCacheDirectory.get()));
         configuration->setWebSQLDatabaseDirectory(!priv->webSQLDirectory ?
-            API::WebsiteDataStore::defaultWebSQLDatabaseDirectory() : WebCore::FileSystem::stringFromFileSystemRepresentation(priv->webSQLDirectory.get()));
+            API::WebsiteDataStore::defaultWebSQLDatabaseDirectory() : FileSystem::stringFromFileSystemRepresentation(priv->webSQLDirectory.get()));
         configuration->setMediaKeysStorageDirectory(API::WebsiteDataStore::defaultMediaKeysStorageDirectory());
         priv->websiteDataStore = API::WebsiteDataStore::createLegacy(WTFMove(configuration));
     }
@@ -532,7 +532,7 @@ const gchar* webkit_website_data_manager_get_disk_cache_directory(WebKitWebsiteD
 
     if (!priv->diskCacheDirectory) {
         // The default directory already has the subdirectory.
-        priv->diskCacheDirectory.reset(g_strdup(WebCore::FileSystem::directoryName(API::WebsiteDataStore::defaultNetworkCacheDirectory()).utf8().data()));
+        priv->diskCacheDirectory.reset(g_strdup(FileSystem::directoryName(API::WebsiteDataStore::defaultNetworkCacheDirectory()).utf8().data()));
     }
     return priv->diskCacheDirectory.get();
 }
index 19be288..3225b92 100644 (file)
 #include "config.h"
 #include "APIWebsiteDataStore.h"
 
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 namespace API {
 
 String WebsiteDataStore::defaultApplicationCacheDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "ApplicationCache");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "ApplicationCache");
 }
 
 String WebsiteDataStore::defaultCacheStorageDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "CacheStorage");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "CacheStorage");
 }
 
 String WebsiteDataStore::defaultNetworkCacheDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "NetworkCache");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "NetworkCache");
 }
 
 String WebsiteDataStore::defaultIndexedDBDatabaseDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "IndexedDB");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "IndexedDB");
 }
 
 String WebsiteDataStore::defaultServiceWorkerRegistrationDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "ServiceWorkers");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "ServiceWorkers");
 }
 
 String WebsiteDataStore::defaultLocalStorageDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "LocalStorage");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "LocalStorage");
 }
 
 String WebsiteDataStore::defaultMediaKeysStorageDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "MediaKeyStorage");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "MediaKeyStorage");
 }
 
 String WebsiteDataStore::defaultDeviceIdHashSaltsStorageDirectory()
@@ -73,57 +73,57 @@ String WebsiteDataStore::defaultDeviceIdHashSaltsStorageDirectory()
 
 String WebsiteDataStore::defaultWebSQLDatabaseDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "WebSQL");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "WebSQL");
 }
 
 String WebsiteDataStore::defaultResourceLoadStatisticsDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "ResourceLoadStatistics");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "ResourceLoadStatistics");
 }
 
 String WebsiteDataStore::cacheDirectoryFileSystemRepresentation(const String& directoryName)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), directoryName);
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), directoryName);
 }
 
 String WebsiteDataStore::websiteDataDirectoryFileSystemRepresentation(const String& directoryName)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), directoryName);
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), directoryName);
 }
 
 String WebsiteDataStore::legacyDefaultApplicationCacheDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "ApplicationCache");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "ApplicationCache");
 }
 
 String WebsiteDataStore::legacyDefaultNetworkCacheDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "NetworkCache");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "NetworkCache");
 }
 
 String WebsiteDataStore::legacyDefaultWebSQLDatabaseDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "WebSQL");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "WebSQL");
 }
 
 String WebsiteDataStore::legacyDefaultIndexedDBDatabaseDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "IndexedDB");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "IndexedDB");
 }
 
 String WebsiteDataStore::legacyDefaultLocalStorageDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "LocalStorage");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "LocalStorage");
 }
 
 String WebsiteDataStore::legacyDefaultMediaCacheDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "MediaCache");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "MediaCache");
 }
 
 String WebsiteDataStore::legacyDefaultMediaKeysStorageDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "MediaKeyStorage");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "MediaKeyStorage");
 }
 
 String WebsiteDataStore::legacyDefaultDeviceIdHashSaltsStorageDirectory()
@@ -134,7 +134,7 @@ String WebsiteDataStore::legacyDefaultDeviceIdHashSaltsStorageDirectory()
 
 String WebsiteDataStore::legacyDefaultJavaScriptConfigurationDirectory()
 {
-    return WebCore::FileSystem::pathByAppendingComponent(WebCore::FileSystem::localUserSpecificStorageDirectory(), "JavaScriptCoreDebug");
+    return FileSystem::pathByAppendingComponent(FileSystem::localUserSpecificStorageDirectory(), "JavaScriptCoreDebug");
 }
 
 Ref<WebKit::WebsiteDataStoreConfiguration> WebsiteDataStore::defaultDataStoreConfiguration()
index 80547e6..f8844af 100644 (file)
@@ -806,7 +806,7 @@ void WebAutomationSession::willClosePage(const WebPageProxy& page)
 
 static bool fileCanBeAcceptedForUpload(const String& filename, const HashSet<String>& allowedMIMETypes, const HashSet<String>& allowedFileExtensions)
 {
-    if (!WebCore::FileSystem::fileExists(filename))
+    if (!FileSystem::fileExists(filename))
         return false;
 
     if (allowedMIMETypes.isEmpty() && allowedFileExtensions.isEmpty())
index 3b49628..c727bd2 100644 (file)
 #import "WebProcessProxy.h"
 #import "_WKDownloadDelegate.h"
 #import "_WKDownloadInternal.h"
-#import <WebCore/FileSystem.h>
 #import <WebCore/ResourceError.h>
 #import <WebCore/ResourceResponse.h>
 #import <wtf/BlockPtr.h>
+#import <wtf/FileSystem.h>
 
 namespace WebKit {
 
@@ -181,7 +181,7 @@ void DownloadClient::decideDestinationWithSuggestedFilename(WebProcessPool&, Dow
 {
 #if USE(SYSTEM_PREVIEW)
     if (downloadProxy.isSystemPreviewDownload()) {
-        NSString *temporaryDirectory = WebCore::FileSystem::createTemporaryDirectory(@"SystemPreviews");
+        NSString *temporaryDirectory = FileSystem::createTemporaryDirectory(@"SystemPreviews");
         NSString *destination = [temporaryDirectory stringByAppendingPathComponent:filename];
         completionHandler(AllowOverwrite::Yes, destination);
         return;
index 56cf0fd..2daf755 100644 (file)
@@ -43,7 +43,6 @@
 #import "WebProcessMessages.h"
 #import "WindowServerConnection.h"
 #import <WebCore/Color.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/NetworkStorageSession.h>
 #import <WebCore/NotImplemented.h>
 #import <WebCore/PlatformPasteboard.h>
@@ -52,6 +51,7 @@
 #import <pal/spi/cf/CFNetworkSPI.h>
 #import <pal/spi/cocoa/NSKeyedArchiverSPI.h>
 #import <sys/param.h>
+#import <wtf/FileSystem.h>
 #import <wtf/ProcessPrivilege.h>
 #import <wtf/cocoa/Entitlements.h>
 #import <wtf/spi/darwin/dyldSPI.h>
index d8fcc8c..463d3b1 100644 (file)
@@ -84,7 +84,6 @@
 #import <WebCore/DragData.h>
 #import <WebCore/DragItem.h>
 #import <WebCore/Editor.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/FontAttributeChanges.h>
 #import <WebCore/FontAttributes.h>
 #import <WebCore/KeypressCommand.h>
 #import <pal/spi/mac/NSViewSPI.h>
 #import <pal/spi/mac/NSWindowSPI.h>
 #import <sys/stat.h>
+#import <wtf/FileSystem.h>
 #import <wtf/NeverDestroyed.h>
 #import <wtf/ProcessPrivilege.h>
 #import <wtf/SetForScope.h>
@@ -3969,7 +3969,7 @@ bool WebViewImpl::performDragOperation(id <NSDraggingInfo> draggingInfo)
             return false;
         }
 
-        NSString *dropDestinationPath = WebCore::FileSystem::createTemporaryDirectory(@"WebKitDropDestination");
+        NSString *dropDestinationPath = FileSystem::createTemporaryDirectory(@"WebKitDropDestination");
         if (!dropDestinationPath) {
             delete dragData;
             return false;
@@ -4291,7 +4291,7 @@ NSArray *WebViewImpl::namesOfPromisedFilesDroppedAtDestination(NSURL *dropDestin
         LOG_ERROR("Failed to create image file via -[NSFileWrapper writeToURL:options:originalContentsURL:error:]");
 
     if (!m_promisedURL.isEmpty())
-        WebCore::FileSystem::setMetadataURL(String(path), m_promisedURL);
+        FileSystem::setMetadataURL(String(path), m_promisedURL);
     
     return [NSArray arrayWithObject:[path lastPathComponent]];
 }
index e60ee3f..19a7a12 100644 (file)
@@ -28,9 +28,9 @@
 
 #include "PersistencyUtils.h"
 
-#include <WebCore/FileSystem.h>
 #include <WebCore/SharedBuffer.h>
 #include <wtf/CryptographicallyRandomNumber.h>
+#include <wtf/FileSystem.h>
 #include <wtf/HexNumber.h>
 #include <wtf/RunLoop.h>
 #include <wtf/text/StringBuilder.h>
index 75102ee..e09254b 100644 (file)
@@ -36,8 +36,8 @@
 #include "WebProcessMessages.h"
 #include "WebProcessPool.h"
 #include "WebProtectionSpace.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/MIMETypeRegistry.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/WTFString.h>
 
index e434e03..16723df 100644 (file)
 
 #if ENABLE(BUBBLEWRAP_SANDBOX)
 
-#include <WebCore/FileSystem.h>
 #include <WebCore/PlatformDisplay.h>
 #include <fcntl.h>
 #include <glib.h>
 #include <seccomp.h>
 #include <sys/ioctl.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GLibUtilities.h>
 #include <wtf/glib/GRefPtr.h>
 #include <wtf/glib/GUniquePtr.h>
index c566187..0c39073 100644 (file)
 #include "Connection.h"
 #include "FlatpakLauncher.h"
 #include "ProcessExecutablePath.h"
-#include <WebCore/FileSystem.h>
 #include <errno.h>
 #include <fcntl.h>
 #include <glib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RunLoop.h>
 #include <wtf/UniStdExtras.h>
 #include <wtf/glib/GLibUtilities.h>
@@ -47,7 +47,6 @@
 #endif
 
 namespace WebKit {
-using namespace WebCore;
 
 static void childSetupFunction(gpointer userData)
 {
index 80647eb..a28a00a 100644 (file)
@@ -29,8 +29,8 @@
 #if ENABLE(NETSCAPE_PLUGIN_API)
 
 #include "NetscapePluginModule.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/PlatformDisplay.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 
 namespace WebKit {
@@ -66,10 +66,10 @@ PluginInfoCache::PluginInfoCache()
     m_saveToFileIdle.setPriority(G_PRIORITY_DEFAULT_IDLE);
 
     GUniquePtr<char> cacheDirectory(g_build_filename(g_get_user_cache_dir(), "webkitgtk", nullptr));
-    if (WebCore::FileSystem::makeAllDirectories(cacheDirectory.get())) {
+    if (FileSystem::makeAllDirectories(cacheDirectory.get())) {
         // Delete old cache file.
         GUniquePtr<char> oldCachePath(g_build_filename(cacheDirectory.get(), "plugins", nullptr));
-        WebCore::FileSystem::deleteFile(WebCore::FileSystem::stringFromFileSystemRepresentation(oldCachePath.get()));
+        FileSystem::deleteFile(FileSystem::stringFromFileSystemRepresentation(oldCachePath.get()));
 
         m_cachePath.reset(g_build_filename(cacheDirectory.get(), cacheFilenameForCurrentDisplay(), nullptr));
         g_key_file_load_from_file(m_cacheFile.get(), m_cachePath.get(), G_KEY_FILE_NONE, nullptr);
@@ -112,7 +112,7 @@ bool PluginInfoCache::getPluginInfo(const String& pluginPath, PluginModuleInfo&
     if (!g_key_file_has_group(m_cacheFile.get(), pluginGroup.data()))
         return false;
 
-    auto lastModifiedTime = WebCore::FileSystem::getFileModificationTime(pluginPath);
+    auto lastModifiedTime = FileSystem::getFileModificationTime(pluginPath);
     if (!lastModifiedTime)
         return false;
     time_t cachedLastModified = static_cast<time_t>(g_key_file_get_uint64(m_cacheFile.get(), pluginGroup.data(), "mtime", nullptr));
@@ -120,7 +120,7 @@ bool PluginInfoCache::getPluginInfo(const String& pluginPath, PluginModuleInfo&
         return false;
 
     plugin.path = pluginPath;
-    plugin.info.file = WebCore::FileSystem::pathGetFileName(pluginPath);
+    plugin.info.file = FileSystem::pathGetFileName(pluginPath);
 
     GUniquePtr<char> stringValue(g_key_file_get_string(m_cacheFile.get(), pluginGroup.data(), "name", nullptr));
     plugin.info.name = String::fromUTF8(stringValue.get());
@@ -140,7 +140,7 @@ bool PluginInfoCache::getPluginInfo(const String& pluginPath, PluginModuleInfo&
 
 void PluginInfoCache::updatePluginInfo(const String& pluginPath, const PluginModuleInfo& plugin)
 {
-    auto lastModifiedTime = WebCore::FileSystem::getFileModificationTime(pluginPath);
+    auto lastModifiedTime = FileSystem::getFileModificationTime(pluginPath);
     if (!lastModifiedTime)
         return;
 
index 89fab5e..3633c2a 100644 (file)
 #import "PluginProcessMessages.h"
 #import "SandboxUtilities.h"
 #import <QuartzCore/CARemoteLayerServer.h>
-#import <WebCore/FileSystem.h>
 #import <crt_externs.h>
 #import <mach-o/dyld.h>
 #import <pal/spi/cf/CFNetworkSPI.h>
 #import <spawn.h>
+#import <wtf/FileSystem.h>
 #import <wtf/ProcessPrivilege.h>
 #import <wtf/URL.h>
 #import <wtf/text/CString.h>
@@ -57,8 +57,6 @@
 @end
 
 namespace WebKit {
-using namespace WebCore;
-
     
 void PluginProcessProxy::platformGetLaunchOptionsWithAttributes(ProcessLauncher::LaunchOptions& launchOptions, const PluginProcessAttributes& pluginProcessAttributes)
 {
index 1dfd807..aa09473 100644 (file)
 #include "NetscapePluginModule.h"
 #include "PluginSearchPath.h"
 #include "ProcessExecutablePath.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/PlatformDisplay.h>
 #include <limits.h>
 #include <stdlib.h>
+#include <wtf/FileSystem.h>
 
 #if PLATFORM(GTK)
 #include "PluginInfoCache.h"
index f896121..c500c0f 100644 (file)
@@ -32,9 +32,9 @@
 
 #include "PluginProcessCreationParameters.h"
 #include "ProcessExecutablePath.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/PlatformDisplay.h>
 #include <sys/wait.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/WTFString.h>
 
index 726883b..5bcda63 100644 (file)
@@ -64,7 +64,7 @@ ServiceWorkerProcessProxy::~ServiceWorkerProcessProxy()
 bool ServiceWorkerProcessProxy::hasRegisteredServiceWorkers(const String& serviceWorkerDirectory)
 {
     String registrationFile = WebCore::serviceWorkerRegistrationDatabaseFilename(serviceWorkerDirectory);
-    return WebCore::FileSystem::fileExists(registrationFile);
+    return FileSystem::fileExists(registrationFile);
 }
 
 void ServiceWorkerProcessProxy::getLaunchOptions(ProcessLauncher::LaunchOptions& launchOptions)
index 0c25d65..46fb6c7 100644 (file)
 #include "LocalStorageDatabase.h"
 
 #include "LocalStorageDatabaseTracker.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/SQLiteStatement.h>
 #include <WebCore/SQLiteTransaction.h>
 #include <WebCore/SecurityOrigin.h>
 #include <WebCore/StorageMap.h>
 #include <WebCore/SuddenTermination.h>
+#include <wtf/FileSystem.h>
 #include <wtf/RefPtr.h>
 #include <wtf/WorkQueue.h>
 #include <wtf/text/StringHash.h>
index affd7e8..c3781df 100644 (file)
 #include "LocalStorageDatabaseTracker.h"
 
 #include "Logging.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/SQLiteFileSystem.h>
 #include <WebCore/SQLiteStatement.h>
 #include <WebCore/TextEncoding.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/RunLoop.h>
 #include <wtf/WorkQueue.h>
index 427a9c8..6190050 100644 (file)
 #import "StorageManager.h"
 #import "WebResourceLoadStatisticsStore.h"
 #import "WebsiteDataStoreParameters.h"
-#import <WebCore/FileSystem.h>
 #import <WebCore/RuntimeApplicationChecks.h>
 #import <WebCore/SearchPopupMenuCocoa.h>
 #import <pal/spi/cf/CFNetworkSPI.h>
+#import <wtf/FileSystem.h>
 #import <wtf/NeverDestroyed.h>
 #import <wtf/ProcessPrivilege.h>
 
@@ -121,7 +121,7 @@ WebsiteDataStoreParameters WebsiteDataStore::parameters()
     parameters.pendingCookies = copyToVector(m_pendingCookies);
 
     if (!cookieFile.isEmpty())
-        SandboxExtension::createHandleForReadWriteDirectory(WebCore::FileSystem::directoryName(cookieFile), parameters.cookieStoragePathExtensionHandle);
+        SandboxExtension::createHandleForReadWriteDirectory(FileSystem::directoryName(cookieFile), parameters.cookieStoragePathExtensionHandle);
 
 #if ENABLE(INDEXED_DATABASE)
     parameters.indexedDatabaseDirectory = resolvedIndexedDatabaseDirectory();
index b7c8182..b25e2b5 100644 (file)
@@ -46,7 +46,6 @@
 #include "WebsiteDataStoreParameters.h"
 #include <WebCore/ApplicationCacheStorage.h>
 #include <WebCore/DatabaseTracker.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/HTMLMediaElement.h>
 #include <WebCore/OriginLock.h>
 #include <WebCore/SecurityOrigin.h>
@@ -54,6 +53,7 @@
 #include <wtf/CallbackAggregator.h>
 #include <wtf/CompletionHandler.h>
 #include <wtf/CrossThreadCopier.h>
+#include <wtf/FileSystem.h>
 #include <wtf/ProcessPrivilege.h>
 #include <wtf/RunLoop.h>
 
@@ -195,8 +195,8 @@ void WebsiteDataStore::resolveDirectoriesIfNecessary()
 
     // Resolve directories for file paths.
     if (!m_configuration->cookieStorageFile().isEmpty()) {
-        m_resolvedConfiguration->setCookieStorageFile(resolveAndCreateReadWriteDirectoryForSandboxExtension(WebCore::FileSystem::directoryName(m_configuration->cookieStorageFile())));
-        m_resolvedConfiguration->setCookieStorageFile(WebCore::FileSystem::pathByAppendingComponent(m_resolvedConfiguration->cookieStorageFile(), WebCore::FileSystem::pathGetFileName(m_configuration->cookieStorageFile())));
+        m_resolvedConfiguration->setCookieStorageFile(resolveAndCreateReadWriteDirectoryForSandboxExtension(FileSystem::directoryName(m_configuration->cookieStorageFile())));
+        m_resolvedConfiguration->setCookieStorageFile(FileSystem::pathByAppendingComponent(m_resolvedConfiguration->cookieStorageFile(), FileSystem::pathGetFileName(m_configuration->cookieStorageFile())));
     }
 }
 
@@ -2245,7 +2245,7 @@ Vector<PluginModuleInfo> WebsiteDataStore::plugins() const
 
 static String computeMediaKeyFile(const String& mediaKeyDirectory)
 {
-    return WebCore::FileSystem::pathByAppendingComponent(mediaKeyDirectory, "SecureStop.plist");
+    return FileSystem::pathByAppendingComponent(mediaKeyDirectory, "SecureStop.plist");
 }
 
 Vector<WebCore::SecurityOriginData> WebsiteDataStore::mediaKeyOrigins(const String& mediaKeysStorageDirectory)
@@ -2254,12 +2254,12 @@ Vector<WebCore::SecurityOriginData> WebsiteDataStore::mediaKeyOrigins(const Stri
 
     Vector<WebCore::SecurityOriginData> origins;
 
-    for (const auto& originPath : WebCore::FileSystem::listDirectory(mediaKeysStorageDirectory, "*")) {
+    for (const auto& originPath : FileSystem::listDirectory(mediaKeysStorageDirectory, "*")) {
         auto mediaKeyFile = computeMediaKeyFile(originPath);
-        if (!WebCore::FileSystem::fileExists(mediaKeyFile))
+        if (!FileSystem::fileExists(mediaKeyFile))
             continue;
 
-        auto mediaKeyIdentifier = WebCore::FileSystem::pathGetFileName(originPath);
+        auto mediaKeyIdentifier = FileSystem::pathGetFileName(originPath);
 
         if (auto securityOrigin = WebCore::SecurityOriginData::fromDatabaseIdentifier(mediaKeyIdentifier))
             origins.append(*securityOrigin);
@@ -2272,18 +2272,18 @@ void WebsiteDataStore::removeMediaKeys(const String& mediaKeysStorageDirectory,
 {
     ASSERT(!mediaKeysStorageDirectory.isEmpty());
 
-    for (const auto& mediaKeyDirectory : WebCore::FileSystem::listDirectory(mediaKeysStorageDirectory, "*")) {
+    for (const auto& mediaKeyDirectory : FileSystem::listDirectory(mediaKeysStorageDirectory, "*")) {
         auto mediaKeyFile = computeMediaKeyFile(mediaKeyDirectory);
 
-        auto modificationTime = WebCore::FileSystem::getFileModificationTime(mediaKeyFile);
+        auto modificationTime = FileSystem::getFileModificationTime(mediaKeyFile);
         if (!modificationTime)
             continue;
 
         if (modificationTime.value() < modifiedSince)
             continue;
 
-        WebCore::FileSystem::deleteFile(mediaKeyFile);
-        WebCore::FileSystem::deleteEmptyDirectory(mediaKeyDirectory);
+        FileSystem::deleteFile(mediaKeyFile);
+        FileSystem::deleteEmptyDirectory(mediaKeyDirectory);
     }
 }
 
@@ -2292,11 +2292,11 @@ void WebsiteDataStore::removeMediaKeys(const String& mediaKeysStorageDirectory,
     ASSERT(!mediaKeysStorageDirectory.isEmpty());
 
     for (const auto& origin : origins) {
-        auto mediaKeyDirectory = WebCore::FileSystem::pathByAppendingComponent(mediaKeysStorageDirectory, origin.databaseIdentifier());
+        auto mediaKeyDirectory = FileSystem::pathByAppendingComponent(mediaKeysStorageDirectory, origin.databaseIdentifier());
         auto mediaKeyFile = computeMediaKeyFile(mediaKeyDirectory);
 
-        WebCore::FileSystem::deleteFile(mediaKeyFile);
-        WebCore::FileSystem::deleteEmptyDirectory(mediaKeyDirectory);
+        FileSystem::deleteFile(mediaKeyFile);
+        FileSystem::deleteEmptyDirectory(mediaKeyDirectory);
     }
 }
 
index 8f5fa03..169ea20 100644 (file)
@@ -31,8 +31,8 @@
 #endif
 #include "WebProcessPool.h"
 #include "WebsiteDataStore.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/PlatformDisplay.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
 using namespace WebCore;
index ca187a6..16b02a4 100644 (file)
@@ -42,9 +42,9 @@
 #include "WebProcessPool.h"
 #include "WebProcessProxy.h"
 #include <WebCore/CertificateInfo.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/GtkUtilities.h>
 #include <WebCore/NotImplemented.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 #include <wtf/text/WTFString.h>
 
index 6240415..6b23574 100644 (file)
 #include "WebProcessCreationParameters.h"
 #include "WebProcessMessages.h"
 #include <JavaScriptCore/RemoteInspectorServer.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/GStreamerCommon.h>
 #include <WebCore/NotImplemented.h>
 #include <WebCore/SchemeRegistry.h>
+#include <wtf/FileSystem.h>
 #include <wtf/glib/GUniquePtr.h>
 #include <wtf/text/CString.h>
 
index bd1c6ba..b28f177 100644 (file)
@@ -5699,7 +5699,7 @@ static NSArray<NSItemProvider *> *extractItemProvidersFromDropSession(id <UIDrop
             return;
         }
 
-        NSString *temporaryBlobDirectory = WebCore::FileSystem::createTemporaryDirectory(@"blobs");
+        NSString *temporaryBlobDirectory = FileSystem::createTemporaryDirectory(@"blobs");
         NSURL *destinationURL = [NSURL fileURLWithPath:[temporaryBlobDirectory stringByAppendingPathComponent:[NSUUID UUID].UUIDString] isDirectory:NO];
 
         auto attachment = strongSelf->_page->attachmentForIdentifier(info.attachmentIdentifier);
index 6801646..877114f 100644 (file)
@@ -620,7 +620,7 @@ IGNORE_WARNINGS_END
     NSString * const kTemporaryDirectoryName = @"WKWebFileUpload";
 
     // Build temporary file path.
-    NSString *temporaryDirectory = WebCore::FileSystem::createTemporaryDirectory(kTemporaryDirectoryName);
+    NSString *temporaryDirectory = FileSystem::createTemporaryDirectory(kTemporaryDirectoryName);
     NSString *filePath = [temporaryDirectory stringByAppendingPathComponent:imageName];
     if (!filePath) {
         LOG_ERROR("WKFileUploadPanel: Failed to create temporary directory to save image");
index 62be410..83004d7 100644 (file)
@@ -495,7 +495,7 @@ static NSString *pathToPDFOnDisk(const String& suggestedFilename)
 
 void WebPageProxy::savePDFToTemporaryFolderAndOpenWithNativeApplicationRaw(const String& suggestedFilename, const String& originatingURLString, const uint8_t* data, unsigned long size, const String& pdfUUID)
 {
-    // FIXME: Write originatingURLString to the file's originating URL metadata (perhaps WebCore::FileSystem::setMetadataURL()?).
+    // FIXME: Write originatingURLString to the file's originating URL metadata (perhaps FileSystem::setMetadataURL()?).
     UNUSED_PARAM(originatingURLString);
 
     if (!suggestedFilename.endsWithIgnoringASCIICase(".pdf")) {
index 1015ff0..390a0c9 100644 (file)
@@ -28,8 +28,8 @@
 #include "WebProcessPool.h"
 
 #include "WebProcessCreationParameters.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/NotImplemented.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
 
index ef7919c..0f9f9d4 100644 (file)
@@ -44,7 +44,6 @@
 #include <WebCore/BitmapInfo.h>
 #include <WebCore/Cursor.h>
 #include <WebCore/Editor.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/FloatRect.h>
 #include <WebCore/HWndDC.h>
 #include <WebCore/IntRect.h>
@@ -55,6 +54,7 @@
 #include <WebCore/WindowsTouch.h>
 #include <cairo-win32.h>
 #include <cairo.h>
+#include <wtf/FileSystem.h>
 #include <wtf/SoftLinking.h>
 #include <wtf/text/StringBuffer.h>
 #include <wtf/text/StringBuilder.h>
index 6255c42..f51017a 100644 (file)
 #include "WebCookieManagerProxy.h"
 #include "WebProcessCreationParameters.h"
 #include "WebProcessMessages.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/NotImplemented.h>
 #include <WebCore/SchemeRegistry.h>
 #include <cstdlib>
+#include <wtf/FileSystem.h>
 
 #if ENABLE(REMOTE_INSPECTOR)
 #include <JavaScriptCore/RemoteInspectorServer.h>
index aac2828..4ccec62 100644 (file)
@@ -23,8 +23,8 @@
 #include "APIString.h"
 #include "InjectedBundle.h"
 #include "WebKitWebExtensionPrivate.h"
-#include <WebCore/FileSystem.h>
 #include <memory>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 
 namespace WebKit {
@@ -41,9 +41,9 @@ WebKitExtensionManager::WebKitExtensionManager()
 
 void WebKitExtensionManager::scanModules(const String& webExtensionsDirectory, Vector<String>& modules)
 {
-    Vector<String> modulePaths = WebCore::FileSystem::listDirectory(webExtensionsDirectory, String("*.so"));
+    Vector<String> modulePaths = FileSystem::listDirectory(webExtensionsDirectory, String("*.so"));
     for (size_t i = 0; i < modulePaths.size(); ++i) {
-        if (WebCore::FileSystem::fileExists(modulePaths[i]))
+        if (FileSystem::fileExists(modulePaths[i]))
             modules.append(modulePaths[i]);
     }
 }
@@ -63,7 +63,7 @@ static void parseUserData(API::Object* userData, String& webExtensionsDirectory,
     GVariant* data = nullptr;
     g_variant_get(variant.get(), "(m&smv)", &directory, &data);
 
-    webExtensionsDirectory = WebCore::FileSystem::stringFromFileSystemRepresentation(directory);
+    webExtensionsDirectory = FileSystem::stringFromFileSystemRepresentation(directory);
     initializationUserData = adoptGRef(data);
 }
 
index 0a86065..ed9658c 100644 (file)
 
 #include "WKBundleAPICast.h"
 #include "WKBundleInitialize.h"
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/CString.h>
 
 namespace WebKit {
-using namespace WebCore;
 
 bool InjectedBundle::initialize(const WebProcessCreationParameters&, API::Object* initializationUserData)
 {
index 4bf48d0..bd39824 100644 (file)
@@ -27,9 +27,9 @@
 #include "WebMediaKeyStorageManager.h"
 
 #include "WebProcessCreationParameters.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/SecurityOrigin.h>
 #include <WebCore/SecurityOriginData.h>
+#include <wtf/FileSystem.h>
 #include <wtf/URL.h>
 
 namespace WebKit {
index bb6a5b0..3edcec6 100644 (file)
@@ -27,9 +27,9 @@
 
 #if ENABLE(NETSCAPE_PLUGIN_API)
 
-#include <WebCore/FileSystem.h>
 #include <WebCore/npruntime_internal.h>
 #include <memory>
+#include <wtf/FileSystem.h>
 #include <wtf/Forward.h>
 #include <wtf/RefCounted.h>
 #include <wtf/RefPtr.h>
@@ -89,7 +89,7 @@ private:
     int32_t m_offset;
 
     String m_filePath;
-    WebCore::FileSystem::PlatformFileHandle m_fileHandle;
+    FileSystem::PlatformFileHandle m_fileHandle;
     
     // Whether NPP_NewStream has successfully been called.
     bool m_isStarted;
index 01c53f3..26d6d50 100644 (file)
 #include "WebProcess.h"
 #include "WebProcessProxyMessages.h"
 #include <JavaScriptCore/JSObject.h>
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
-using namespace WebCore;
 
 PluginProcessConnection::PluginProcessConnection(PluginProcessConnectionManager* pluginProcessConnectionManager, uint64_t pluginProcessToken, IPC::Connection::Identifier connectionIdentifier, bool supportsAsynchronousPluginInitialization)
     : m_pluginProcessConnectionManager(pluginProcessConnectionManager)
index 63c36a3..1d8166a 100644 (file)
@@ -28,9 +28,9 @@
 
 #include "SessionState.h"
 #include <WebCore/BlobData.h>
-#include <WebCore/FileSystem.h>
 #include <WebCore/FormData.h>
 #include <WebCore/HistoryItem.h>
+#include <wtf/FileSystem.h>
 
 namespace WebKit {
 using namespace WebCore;
index 89c3ba1..dbb2a91 100644 (file)
@@ -28,8 +28,8 @@
 #include "WebInspectorUI.h"
 #include "RemoteWebInspectorUI.h"
 
-#include <WebCore/FileSystem.h>
 #include <glib.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/WTFString.h>
 
 namespace WebKit {
index 6a7af3c..471114c 100644 (file)
@@ -28,8 +28,8 @@
 
 #include "RemoteWebInspectorUI.h"
 
-#include <WebCore/FileSystem.h>
 #include <WebCore/WebCoreBundleWin.h>
+#include <wtf/FileSystem.h>
 #include <wtf/text/WTFString.h>
 
 namespace WebKit {
index a44681c..35d57d5 100644 (file)
@@ -51,7 +51,6 @@
 #import <WebCore/AXObjectCache.h>
 #import <WebCore/CPUMonitor.h>
 #import <WebCore/DisplayRefreshMonitorManager.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/FontCache.h>
 #import <WebCore/FontCascade.h>
 #import <WebCore/HistoryController.h>
@@ -72,6 +71,7 @@
 #import <pal/spi/mac/NSAccessibilitySPI.h>
 #import <pal/spi/mac/NSApplicationSPI.h>
 #import <stdio.h>
+#import <wtf/FileSystem.h>
 #import <wtf/cocoa/NSURLExtras.h>
 
 #if PLATFORM(IOS_FAMILY)
index cc79e8b..a6a58c4 100644 (file)
@@ -1,3 +1,14 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * Storage/StorageAreaSync.cpp:
+        * Storage/StorageSyncManager.cpp:
+        * Storage/StorageTracker.cpp:
+
 2019-01-23  Ross Kirsling  <ross.kirsling@sony.com>
 
         [Curl] Unreviewed build fix for r240292 and friends.
index 4039960..17d4894 100644 (file)
 #include "StorageAreaImpl.h"
 #include "StorageSyncManager.h"
 #include "StorageTracker.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/SQLiteDatabaseTracker.h>
 #include <WebCore/SQLiteStatement.h>
 #include <WebCore/SQLiteTransaction.h>
 #include <WebCore/SuddenTermination.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 
 using namespace WebCore;
index 3e8ff65..369095c 100644 (file)
@@ -26,7 +26,7 @@
 #include "StorageSyncManager.h"
 
 #include "StorageThread.h"
-#include <WebCore/FileSystem.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/text/CString.h>
 
index 710140b..b934d1a 100644 (file)
 #include "StorageThread.h"
 #include "StorageTrackerClient.h"
 #include "WebStorageNamespaceProvider.h"
-#include <WebCore/FileSystem.h>
 #include <WebCore/PageGroup.h>
 #include <WebCore/SQLiteDatabaseTracker.h>
 #include <WebCore/SQLiteStatement.h>
 #include <WebCore/SecurityOrigin.h>
 #include <WebCore/SecurityOriginData.h>
 #include <WebCore/TextEncoding.h>
+#include <wtf/FileSystem.h>
 #include <wtf/MainThread.h>
 #include <wtf/StdLibExtras.h>
 #include <wtf/Vector.h>
index 76d6b5a..9896565 100644 (file)
@@ -1,3 +1,14 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * Misc/WebNSFileManagerExtras.mm:
+        * Storage/WebDatabaseProvider.mm:
+        * WebView/WebView.mm:
+
 2019-01-23  Conrad Shultz  <conrad_shultz@apple.com>
 
         Fix the Apple Internal build. See <rdar://problem/47491383>.
index 905174d..c5413e8 100644 (file)
 
 #import "WebKitNSStringExtras.h"
 #import "WebNSURLExtras.h"
-#import <WebCore/FileSystem.h>
 #import <WebCore/LoaderNSURLExtras.h>
 #import <sys/stat.h>
 #import <wtf/Assertions.h>
+#import <wtf/FileSystem.h>
 #import <wtf/ObjCRuntimeExtras.h>
 
 @implementation NSFileManager (WebNSFileManagerExtras)
@@ -44,7 +44,7 @@
 {
     ASSERT(URLString);
     ASSERT(path);
-    WebCore::FileSystem::setMetadataURL(path, URLString, referrer);
+    FileSystem::setMetadataURL(path, URLString, referrer);
 }
 
 #endif // !PLATFORM(IOS_FAMILY)
@@ -93,7 +93,7 @@ static BOOL fileExists(NSString *path)
 #if PLATFORM(IOS_FAMILY)
 - (NSString *)_webkit_createTemporaryDirectoryWithTemplatePrefix:(NSString *)prefix
 {
-    return WebCore::FileSystem::createTemporaryDirectory(prefix);
+    return FileSystem::createTemporaryDirectory(prefix);
 }
 #endif
 
index 7495b17..adc4c39 100644 (file)
 #import "WebDatabaseProvider.h"
 #import "WebDatabaseManagerPrivate.h"
 
-#import <WebCore/FileSystem.h>
+#import <wtf/FileSystem.h>
 
 String WebDatabaseProvider::indexedDatabaseDirectoryPath()
 {
     NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
     NSString *databasesDirectory = [defaults objectForKey:WebDatabaseDirectoryDefaultsKey];
     if (!databasesDirectory || ![databasesDirectory isKindOfClass:[NSString class]])
-        databasesDirectory = WebCore::FileSystem::pathByAppendingComponent("~/Library/WebKit/Databases/___IndexedDB"_s, [[NSBundle mainBundle] bundleIdentifier]);
+        databasesDirectory = FileSystem::pathByAppendingComponent("~/Library/WebKit/Databases/___IndexedDB"_s, [[NSBundle mainBundle] bundleIdentifier]);
     else
-        databasesDirectory = WebCore::FileSystem::pathByAppendingComponent(databasesDirectory, "___IndexedDB"_s);
+        databasesDirectory = FileSystem::pathByAppendingComponent(databasesDirectory, "___IndexedDB"_s);
     
     return [databasesDirectory stringByStandardizingPath];
 }
index ed0e0df..01c6005 100644 (file)
 #import <WebCore/Editor.h>
 #import <WebCore/Event.h>
 #import <WebCore/EventHandler.h>
-#import <WebCore/FileSystem.h>
 #import <WebCore/FocusController.h>
 #import <WebCore/FontAttributes.h>
 #import <WebCore/FontCache.h>
 #import <pal/spi/mac/NSSpellCheckerSPI.h>
 #import <pal/spi/mac/NSWindowSPI.h>
 #import <wtf/Assertions.h>
+#import <wtf/FileSystem.h>
 #import <wtf/HashTraits.h>
 #import <wtf/MainThread.h>
 #import <wtf/ObjCRuntimeExtras.h>
@@ -6885,7 +6885,7 @@ static NSString * const backingPropertyOldScaleFactorKey = @"NSBackingPropertyOl
             return false;
         }
 
-        NSString *dropDestinationPath = WebCore::FileSystem::createTemporaryDirectory(@"WebKitDropDestination");
+        NSString *dropDestinationPath = FileSystem::createTemporaryDirectory(@"WebKitDropDestination");
         if (!dropDestinationPath) {
             delete dragData;
             return false;
index 4a6c903..5acadf1 100644 (file)
@@ -1,3 +1,19 @@
+2019-01-24  Ross Kirsling  <ross.kirsling@sony.com>
+
+        Move FileSystem to WTF
+        https://bugs.webkit.org/show_bug.cgi?id=193602
+
+        Reviewed by Yusuke Suzuki.
+
+        * Plugins/PluginDatabase.cpp:
+        * Plugins/PluginPackage.h:
+        * Plugins/PluginStream.h:
+        * WebApplicationCache.cpp:
+        * WebDatabaseManager.cpp:
+        * WebDownloadCurl.cpp:
+        * WebPreferences.cpp:
+        * WebView.cpp:
+
 2019-01-22  Alex Christensen  <achristensen@webkit.org>
 
         Move NetworkStorageSession ownership to NetworkProcess
index bc79d89..641ac35 100644 (file)
@@ -33,7 +33,7 @@
 #include <wtf/text/CString.h>
 
 #if ENABLE(NETSCAPE_PLUGIN_METADATA_CACHE)
-#include "FileSystem.h"
+#include <wtf/FileSystem.h>
 #endif
 
 namespace WebCore {