Exemplo n.º 1
0
        private static void ForcarOrigemEDestinosIncompativeis()
        {
            string filePah = @"C:\Publico\clonezilla-live-2.6.2-15-amd64{0}.iso";
            var    origem  = new LocalFileEndpoint(String.Format(filePah, string.Empty));
            var    destino = new LocalDirectoryEndpoint(@"C:\ftp-server");
            var    pipe    = new TransferPipe(TransferCommand.COPY, _fromOrigin: origem, _toDestination: destino);

            pipe.Pump();
        }
Exemplo n.º 2
0
        private static void TestarTransferenciaDeArquivoLocal()
        {
            Transformation[] transformacoes = new Transformation[] {
                new DummyTransformation("transformacao1")
            };

            string filePah = @"C:\Publico\clonezilla-live-2.6.2-15-amd64{0}.iso";
            var    origem  = new LocalFileEndpoint(String.Format(filePah, string.Empty));
            var    destino = new LocalFileEndpoint(String.Format(filePah, DateTime.Now.ToString("_yyyy-MM-dd_HHmmss")));
            var    pipe    = new TransferPipe(TransferCommand.COPY, _fromOrigin: origem, _toDestination: destino, _throughTransformations: transformacoes);

            pipe.Pump();
        }