Exemplo n.º 1
0
        protected virtual int addRun(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, ClientTask.Run run)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                return(deployInfo.AddTask(run));
            }
            return(-1);
        }
Exemplo n.º 2
0
        protected virtual int addUpdateSwitchFile(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, ClientTask.UpdateSwitchFile updateSwitchFile)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                return(deployInfo.AddTask(updateSwitchFile));
            }
            return(-1);
        }
Exemplo n.º 3
0
        protected virtual int addAssemblyFiles(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, ClientTask.AssemblyFile assemblyFile)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                return(deployInfo.AddTask(assemblyFile));
            }
            return(-1);
        }
Exemplo n.º 4
0
        protected virtual int addFiles(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, int deployIndex, ClientTask.WebFile webFile)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).GetDeploy(deployIndex);

            if (deployInfo != null)
            {
                return(deployInfo.AddTask(webFile));
            }
            return(-1);
        }
Exemplo n.º 5
0
        protected virtual int addCustom(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, ClientTask.Custom custom)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                custom.Sender = sender;
                return(deployInfo.AddTask(custom));
            }
            return(-1);
        }
Exemplo n.º 6
0
        protected virtual bool setFileSource(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, byte[][] files)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                deployInfo.Files = files;
                return(true);
            }
            return(false);
        }
Exemplo n.º 7
0
        protected virtual int addWaitRunSwitch(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, int taskIndex)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo != null)
            {
                return(deployInfo.AddTask(new ClientTask.WaitRunSwitch {
                    TaskIndex = taskIndex
                }));
            }
            return(-1);
        }
Exemplo n.º 8
0
        protected virtual DeployState start(AutoCSer.Net.TcpInternalServer.ServerSocketSender sender, DateTime time)
        {
            DeployInfo deployInfo = ((ClientObject)sender.ClientObject).CurrentDeploy;

            if (deployInfo == null)
            {
                return(DeployState.StartError);
            }
            return(deployInfo.Start(time, new Timer {
                Server = this
            }));
        }