Beispiel #1
0
        /// <summary>Gets the size of a file.</summary>
        public void GetFileSize(string relativePath, GetFileSizeCallback callback)
        {
            Debug.Assert(!string.IsNullOrEmpty(relativePath));
            Debug.Assert(callback != null);

            string path     = IOUtilities.CombinePath(this.userDir, relativePath);
            int    fileSize = Steamworks.SteamRemoteStorage.FileSize(path);

            callback.Invoke(relativePath, (Int64)fileSize);
        }
Beispiel #2
0
        /// <summary>Gets the size of a file.</summary>
        public void GetFileSize(string relativePath, GetFileSizeCallback callback)
        {
            Debug.Assert(!string.IsNullOrEmpty(relativePath));
            Debug.Assert(callback != null);

            string path      = IOUtilities.CombinePath(this.userDir, relativePath);
            Int64  byteCount = this.GetFileSize(path);

            callback.Invoke(relativePath, byteCount);
        }
        public System.IAsyncResult BeginGetFileSize(String fileName, System.AsyncCallback callback)
        {
            GetFileSizeCallback ftpCallback = new GetFileSizeCallback(this.GetFileSize);

            return(ftpCallback.BeginInvoke(fileName, callback, null));
        }
Beispiel #4
0
 public System.IAsyncResult BeginGetFileSize( String fileName, System.AsyncCallback callback )
 {
     GetFileSizeCallback ftpCallback = new GetFileSizeCallback(this.GetFileSize);
     return ftpCallback.BeginInvoke(fileName, callback, null);
 }
Beispiel #5
0
        /// <summary>
        /// Begins the size of the get file.
        /// </summary>
        /// <param name="fileName">Name of the file.</param>
        /// <param name="callback">The callback.</param>
        /// <returns></returns>
        public IAsyncResult BeginGetFileSize(String fileName, AsyncCallback callback)
        {
            GetFileSizeCallback ftpCallback = GetFileSize;

            return(ftpCallback.BeginInvoke(fileName, callback, null));
        }
Beispiel #6
0
 /// <summary>Gets the size of a file.</summary>
 public static void GetFileSize(string pathRelative, GetFileSizeCallback callback)
 {
     UserDataStorage.PLATFORM_IO.GetFileSize(pathRelative, callback);
 }