示例#1
0
文件: sample8.cs 项目: zcatt/StarUML
        public void InitializeFileTab()
        {
            OptionsLoader ol     = new OptionsLoader();
            string        path   = ol.Path;
            FileLister    lister = new FileLister(path, "", false);

            lister.InitandFillListView(this.lstLibrary);
        }
示例#2
0
文件: sample8.cs 项目: zcatt/StarUML
        public void PublishFiles()
        {
            OptionsLoader ol         = new OptionsLoader();
            string        Connection = "LAN";

            Connection = ol.Connection;

            // Make sure the user wants these files published and the service is available
            if (ServiceAvailable)
            {
                this.pnlNumUsers.Text = " Publishing content list to the ShareBaby service...";
                string[,] z           = FileLister.GetFileList(this.lstLibrary);
                P2PService p = new P2PService();
                p.Url = ol.ServiceUrl;
                p.ClearEntriesForPeer(GlobalIPAddress);

                for (int i = 0; i <= z.GetUpperBound(1); i++)
                {
                    p.RegisterFile(GlobalIPAddress, z[0, i], Connection, z[1, i], z[2, i]);
                }
            }
        }
示例#3
0
 public void InitializeFileTab()
 {
     OptionsLoader ol = new OptionsLoader();
     string path = ol.Path;
     FileLister lister = new FileLister(path, "",false);
     lister.InitandFillListView(this.lstLibrary);
 }