file.cs

来自「ftp客服端源代码」· CS 代码 · 共 61 行

CS
61
字号
using System;

namespace SourceFtp.FileSystem
{
	/// <summary>
	/// Summary description for File.
	/// </summary>
	public class File
	{
		private ILibrary m_Library;
		private object m_InternalTag;

		public File(ILibrary p_Library, object p_InternalTag)
		{
			m_Library = p_Library;
			m_InternalTag = p_InternalTag;
		}

		public void Download(string p_LocalDestination)
		{
			m_Library.DownloadFile(this,p_LocalDestination);
		}

		public object InternalTag
		{
			get{return m_InternalTag;}
		}

		public string Name
		{
			get{return m_Library.GetFileName(this);}
		}
		public string FullPath
		{
			get{return m_Library.GetFileFullPath(this);}
		}
		public long Size
		{
			get{return m_Library.GetFileSize(this);}
		}
		public string DateModified
		{
			get{return m_Library.GetFileDateModified(this);}
		}
		public string Permission
		{
			get{return m_Library.GetFilePermission(this);}
		}

		public void Remove()
		{
			m_Library.RemoveFile(this);
		}

		public void Rename(string p_NewName)
		{
			m_Library.RenameFile(this,p_NewName);
		}
	}
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?