C# Class Rosetta.Executable.FileConversionRunner

Converts a file and outputs the translation into a new file.
Inheritance: IRunner
显示文件 Open project: andry-tino/Rosetta

Protected Properties

Property Type Description
arguments ConversionArguments
conversionProvider ConversionProvider
fileManager FileManager

Public Methods

Method Description
FileConversionRunner ( ConversionProvider conversionProvider, ConversionArguments arguments ) : System

Initializes a new instance of the FileConversionRunner class.

Run ( ) : void

Protected Methods

Method Description
ConvertFile ( ) : void
EmitFiles ( ) : void
InitializeForFileConversion ( ) : void
PrepareFiles ( ) : void

Private Methods

Method Description
GetFilePath ( string userInput ) : string

Checks that the path is OK and also translates into absolute path.

GetOutputFolderForFile ( string userInput ) : string

We proceed in this order: 1. If no path specified: take the path of the input file. 2. Otherwise, a path is specified: use that.

Method Details

ConvertFile() protected method

protected ConvertFile ( ) : void
return void

EmitFiles() protected method

protected EmitFiles ( ) : void
return void

FileConversionRunner() public method

Initializes a new instance of the FileConversionRunner class.
public FileConversionRunner ( ConversionProvider conversionProvider, ConversionArguments arguments ) : System
conversionProvider ConversionProvider
arguments ConversionArguments
return System

InitializeForFileConversion() protected method

protected InitializeForFileConversion ( ) : void
return void

PrepareFiles() protected method

protected PrepareFiles ( ) : void
return void

Run() public method

public Run ( ) : void
return void

Property Details

arguments protected_oe property

protected ConversionArguments,Rosetta.Executable arguments
return ConversionArguments

conversionProvider protected_oe property

protected ConversionProvider conversionProvider
return ConversionProvider

fileManager protected_oe property

protected FileManager fileManager
return FileManager