Пример #1
0
        static public AttemptResult Rename(this StreamSystem item, string path, string new_name, bool overwrite, long milliseconds = StreamSystem.DEFAULT_WAIT)
        {
            if (item.DoesStreamExist(path))
            {
                return(item.RenameStream(path, new_name, overwrite, milliseconds));
            }

            if (item.DoesDirectoryExist(path))
            {
                return(item.RenameDirectory(path, new_name, overwrite, milliseconds));
            }

            return(AttemptResult.Failed);
        }