예제 #1
0
        public List <IVirtualFile> LoadFiles()
        {
            List <IVirtualFile> res = new List <IVirtualFile>();

            foreach (OnServerFile f in InvokerExtension.InvokeR2 <List <OnServerFile>, string, int>(m_driver.Connection, m_driver.LoadFiles, m_dbname, m_folderid))
            {
                res.Add(f);
            }
            return(res);
        }
예제 #2
0
        public override void GetData(AppObject appobj, ConnectionPack connpack, out System.Data.DataTable data, out DatAdmin.Scripting.ObjectGrid grid)
        {
            ObjectPath          objpath = appobj.GetObjectPath();
            IPhysicalConnection conn    = appobj.FindPhysicalConnection(connpack);

            data = null;
            grid = null;
            if (conn != null && objpath != null)
            {
                data = InvokerExtension.InvokeR <DataTable>(conn, (Func <DataTable>) delegate()
                {
                    conn.SystemConnection.SafeChangeDatabase(objpath);
                    return(m_dbtype.LoadOverview(conn.SystemConnection, objpath));
                });
            }
        }
예제 #3
0
        //public bool IsInFolder(IVirtualFolder folder)
        //{
        //    if (folder is OnServerFolder)
        //    {
        //        OnServerFolder other = (OnServerFolder)folder;
        //        if (other.m_driver.Connection.SystemConnection.ConnectionString != m_driver.Connection.SystemConnection.ConnectionString) return false;
        //        if (m_dbname != other.m_dbname) return false;
        //        return InvokerExtension.InvokeR3<bool, string, int, int>(m_driver.Connection, m_driver.HasFile, m_dbname, other.m_folderid, m_fileid);
        //    }
        //    return false;
        //}

        public void RenameTo(string newname)
        {
            InvokerExtension.Invoke4(m_driver.Connection, m_driver.RenameFile, m_dbname, m_folderid, m_filename, newname);
        }
예제 #4
0
 public void Remove()
 {
     InvokerExtension.Invoke3(m_driver.Connection, m_driver.RemoveFile, m_dbname, m_folderid, m_filename);
 }
예제 #5
0
 public byte[] GetBinary()
 {
     return(InvokerExtension.InvokeR3 <byte[], string, int, string>(m_driver.Connection, m_driver.LoadBinaryFile, m_dbname, m_folderid, m_filename));
 }
예제 #6
0
 public string GetText()
 {
     return(InvokerExtension.InvokeR3 <string, string, int, string>(m_driver.Connection, m_driver.LoadTextFile, m_dbname, m_folderid, m_filename));
 }
예제 #7
0
 public void SaveBinary(byte[] data)
 {
     InvokerExtension.Invoke4(m_driver.Connection, m_driver.SaveBinaryFile, m_dbname, m_folderid, m_filename, data);
 }
예제 #8
0
 public void SaveText(string data)
 {
     InvokerExtension.Invoke4(m_driver.Connection, m_driver.SaveTextFile, m_dbname, m_folderid, m_filename, data);
 }
예제 #9
0
 public bool Exists()
 {
     return(InvokerExtension.InvokeR3 <bool, string, int, string>(m_driver.Connection, m_driver.ExistsFile, m_dbname, m_folderid, m_filename));
 }