BExIS.IO.FileHelper.Create C# (CSharp) 메소드

Create() 공개 정적인 메소드

public static Create ( string path ) : FileStream
path string
리턴 System.IO.FileStream
        public static FileStream Create(string path)
        {
            if (Directory.Exists(path))
            {
                // if folder not exist
                if (!Directory.Exists(path))
                {
                    Directory.CreateDirectory(path);
                }
            }

            if (!File.Exists(path))
            {
                return File.Create(path);
            }

            return null;
        }