C# 클래스 OneNoteConversionTool.FormatConversion.GenericFormatConverter

Handles the generic file format conversion into OneNote
상속: IFormatConverter
파일 보기 프로젝트 열기: OneNoteDev/OneNoteConversionTool 1 사용 예제들

공개 메소드들

메소드 설명
ConvertEpubToOneNote ( string inputFile, string outputDir ) : bool

Converts the ePub document input file into OneNote

ConvertInDesignToOneNote ( string inputFile, string outputDir ) : bool

Converts the InDesign document input file into OneNote

ConvertPdfToOneNote ( string inputFile, string outputDir ) : bool

Converts PDF file to OneNote by including an image for each page in the document

ConvertPowerPointToOneNote ( string inputFile, string outputDir ) : bool

Converts PowerPoint presentation into OneNote section

ConvertWordToOneNote ( string inputFile, string outputDir ) : bool

Converts the Word document input file into OneNote

GetSupportedInputFormat ( ) : string

Returns the name of the input format that this IFormatConverter supports

보호된 메소드들

메소드 설명
ConvertHtmlToOneNote ( string inputFile, string originalPicFolder, string auxPicFolder, OneNoteGenerator onGenerator, string sectionId ) : bool

Converts Html file into OneNote Section of Pages

ConvertPowerPointToImages ( string inputFile, string outputDir ) : string

Converts PowerPoint presentation to images where is slide is given by one image

ConvertPowerPointToOneNote ( PowerPointOpenXml pptOpenXml, string imgsPath, OneNoteGenerator note, string sectionName ) : void

Converts PowerPoint presentan to OneNote while converting the sections in power point to main pages, and slides to sub pages

CreateErrorPage ( OneNoteGenerator onGenerator, string sectionId, string>.IEnumerable errorList ) : void

Create the error page for the section, which contains all the errors occurred during the conversion

GeneratePageContent ( HtmlNode htmlBox, IEnumerable page, string originalPicFolderPath, string auxPicFolderPath, string>.IDictionary errorInfo ) : string

Generate Html page content from List of HtmlNode

GetInDesignTitle ( HtmlAgilityPack.HtmlDocument htmlDoc ) : string

Get the title and remove its elements from the document

GetPageTitle ( IEnumerable pageNodes ) : string

Grabs the page node to be used as title and remove it from the pageNodes

InsertPowerPointSlideInOneNote ( int slideNumber, PowerPointOpenXml pptOpenXml, string imgsPath, OneNoteGenerator note, string sectionId, bool showComments = true, string commentsStr = "Comments", bool showNotes = true, string notesStr = "Notes", bool hiddenSlideNotIncluded = true ) : string

Inserts a power point slide into a given section in OneNote as a page

ModifyInDesignHtmlLinks ( HtmlAgilityPack.HtmlDocument htmlDoc, string htmlDir ) : void

change the links to have the full path

SeparatePages ( HtmlNode content ) : IEnumerable>

Splits HtmlNodes into List of HtmlNodes based on page breaks

SetInDesignHtmlExportOptions ( InDesign.Document doc ) : void

Sets the export options of the indesign document to HTML

비공개 메소드들

메소드 설명
GetErrorImagePath ( string picFolderPath ) : string

a big error image to indicate user where had failed to import an image

ReplaceEpubLinksFromHtmlToOneNote ( List pagesHtml, List pagePaths, List pageLinks ) : void

Replace the url links in the epub Html pages to links for the OneNote Pages

메소드 상세

ConvertEpubToOneNote() 공개 메소드

Converts the ePub document input file into OneNote
public ConvertEpubToOneNote ( string inputFile, string outputDir ) : bool
inputFile string
outputDir string
리턴 bool

ConvertHtmlToOneNote() 보호된 메소드

Converts Html file into OneNote Section of Pages
protected ConvertHtmlToOneNote ( string inputFile, string originalPicFolder, string auxPicFolder, OneNoteGenerator onGenerator, string sectionId ) : bool
inputFile string
originalPicFolder string
auxPicFolder string
onGenerator OneNoteConversionTool.OutputGenerator.OneNoteGenerator
sectionId string
리턴 bool

ConvertInDesignToOneNote() 공개 메소드

Converts the InDesign document input file into OneNote
public ConvertInDesignToOneNote ( string inputFile, string outputDir ) : bool
inputFile string
outputDir string
리턴 bool

ConvertPdfToOneNote() 공개 메소드

Converts PDF file to OneNote by including an image for each page in the document
public ConvertPdfToOneNote ( string inputFile, string outputDir ) : bool
inputFile string PDF document path
outputDir string Directory of the output OneNote Notebook
리턴 bool

ConvertPowerPointToImages() 보호된 메소드

Converts PowerPoint presentation to images where is slide is given by one image
protected ConvertPowerPointToImages ( string inputFile, string outputDir ) : string
inputFile string
outputDir string
리턴 string

ConvertPowerPointToOneNote() 공개 메소드

Converts PowerPoint presentation into OneNote section
public ConvertPowerPointToOneNote ( string inputFile, string outputDir ) : bool
inputFile string
outputDir string
리턴 bool

ConvertPowerPointToOneNote() 보호된 메소드

Converts PowerPoint presentan to OneNote while converting the sections in power point to main pages, and slides to sub pages
protected ConvertPowerPointToOneNote ( PowerPointOpenXml pptOpenXml, string imgsPath, OneNoteGenerator note, string sectionName ) : void
pptOpenXml OneNoteConversionTool.FormatReaders.PowerPointOpenXml
imgsPath string
note OneNoteConversionTool.OutputGenerator.OneNoteGenerator
sectionName string
리턴 void

ConvertWordToOneNote() 공개 메소드

Converts the Word document input file into OneNote
public ConvertWordToOneNote ( string inputFile, string outputDir ) : bool
inputFile string
outputDir string
리턴 bool

CreateErrorPage() 보호된 메소드

Create the error page for the section, which contains all the errors occurred during the conversion
protected CreateErrorPage ( OneNoteGenerator onGenerator, string sectionId, string>.IEnumerable errorList ) : void
onGenerator OneNoteConversionTool.OutputGenerator.OneNoteGenerator
sectionId string
errorList string>.IEnumerable
리턴 void

GeneratePageContent() 보호된 메소드

Generate Html page content from List of HtmlNode
protected GeneratePageContent ( HtmlNode htmlBox, IEnumerable page, string originalPicFolderPath, string auxPicFolderPath, string>.IDictionary errorInfo ) : string
htmlBox HtmlAgilityPack.HtmlNode
page IEnumerable
originalPicFolderPath string
auxPicFolderPath string
errorInfo string>.IDictionary
리턴 string

GetInDesignTitle() 보호된 메소드

Get the title and remove its elements from the document
protected GetInDesignTitle ( HtmlAgilityPack.HtmlDocument htmlDoc ) : string
htmlDoc HtmlAgilityPack.HtmlDocument
리턴 string

GetPageTitle() 보호된 메소드

Grabs the page node to be used as title and remove it from the pageNodes
protected GetPageTitle ( IEnumerable pageNodes ) : string
pageNodes IEnumerable
리턴 string

GetSupportedInputFormat() 공개 메소드

Returns the name of the input format that this IFormatConverter supports
public GetSupportedInputFormat ( ) : string
리턴 string

InsertPowerPointSlideInOneNote() 보호된 메소드

Inserts a power point slide into a given section in OneNote as a page
protected InsertPowerPointSlideInOneNote ( int slideNumber, PowerPointOpenXml pptOpenXml, string imgsPath, OneNoteGenerator note, string sectionId, bool showComments = true, string commentsStr = "Comments", bool showNotes = true, string notesStr = "Notes", bool hiddenSlideNotIncluded = true ) : string
slideNumber int
pptOpenXml OneNoteConversionTool.FormatReaders.PowerPointOpenXml
imgsPath string
note OneNoteConversionTool.OutputGenerator.OneNoteGenerator
sectionId string
showComments bool
commentsStr string
showNotes bool
notesStr string
hiddenSlideNotIncluded bool
리턴 string

ModifyInDesignHtmlLinks() 보호된 메소드

change the links to have the full path
protected ModifyInDesignHtmlLinks ( HtmlAgilityPack.HtmlDocument htmlDoc, string htmlDir ) : void
htmlDoc HtmlAgilityPack.HtmlDocument
htmlDir string
리턴 void

SeparatePages() 보호된 메소드

Splits HtmlNodes into List of HtmlNodes based on page breaks
protected SeparatePages ( HtmlNode content ) : IEnumerable>
content HtmlAgilityPack.HtmlNode
리턴 IEnumerable>

SetInDesignHtmlExportOptions() 보호된 메소드

Sets the export options of the indesign document to HTML
protected SetInDesignHtmlExportOptions ( InDesign.Document doc ) : void
doc InDesign.Document
리턴 void