Created
March 20, 2023 00:52
-
-
Save TheFo2sh/db1df95f83a54309e679338676b0fcdf to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class PdfGenerator | |
{ | |
public async Task GeneratePdfAsync(string htmlContent) | |
{ | |
// generate PDF from HTML content | |
} | |
} | |
public class MyClass | |
{ | |
private readonly PdfGenerator _pdfGenerator; | |
public MyClass(PdfGenerator pdfGenerator) | |
{ | |
_pdfGenerator = pdfGenerator; | |
} | |
public async Task GeneratePdf(string htmlContent) | |
{ | |
await _pdfGenerator.GeneratePdfAsync(htmlContent); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment