Class MdPreviewHtmlPageContentProvider
- java.lang.Object
-
- com._1c.g5.v8.dt.html.ui.editor.PreviewHtmlPageContentProvider
-
- com._1c.g5.v8.dt.md.ui.editor.html.MdPreviewHtmlPageContentProvider
-
- All Implemented Interfaces:
IPreviewHtmlPageContentProvider
public class MdPreviewHtmlPageContentProvider extends PreviewHtmlPageContentProvider
Metadata extension for content provider of text of preview html pageText depend to current editing language
-
-
Field Summary
-
Fields inherited from class com._1c.g5.v8.dt.html.ui.editor.PreviewHtmlPageContentProvider
homeLocation, textEditor
-
Fields inherited from interface com._1c.g5.v8.dt.html.ui.editor.IPreviewHtmlPageContentProvider
FILE_NOT_FOUND_PAGE, FILE_NOT_FOUND_PAGE_CONTENT_PROVIDER
-
-
Constructor Summary
Constructors Constructor Description MdPreviewHtmlPageContentProvider(org.eclipse.ui.texteditor.ITextEditor textEditor, String homeLocation, org.eclipse.core.resources.IProject project, IEditingLanguageManager languageManager)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Optional<String>
getLocationPageContent(String location)
Get html page content from specified locationprotected String
getPageNotFoundContent()
Get html page not fount template text-
Methods inherited from class com._1c.g5.v8.dt.html.ui.editor.PreviewHtmlPageContentProvider
getContent, getHomePageContent, getHtmlBodyText
-
-
-
-
Constructor Detail
-
MdPreviewHtmlPageContentProvider
public MdPreviewHtmlPageContentProvider(org.eclipse.ui.texteditor.ITextEditor textEditor, String homeLocation, org.eclipse.core.resources.IProject project, IEditingLanguageManager languageManager)
- Parameters:
textEditor
- the base text editor, can benull
if no reasonhomeLocation
- the default location to provide content from text editor, can benull
if no reasonproject
- the current project, cannot benull
languageManager
- the instance ofIEditingLanguageManager
, cannot benull
-
-
Method Detail
-
getLocationPageContent
protected Optional<String> getLocationPageContent(String location) throws IOException
Description copied from class:PreviewHtmlPageContentProvider
Get html page content from specified location- Overrides:
getLocationPageContent
in classPreviewHtmlPageContentProvider
- Parameters:
location
- of html text to preview, cannot benull
- Returns:
- string text content, never
null
- Throws:
IOException
- if an I/O error occurs
-
getPageNotFoundContent
protected String getPageNotFoundContent() throws IOException
Description copied from class:PreviewHtmlPageContentProvider
Get html page not fount template text- Overrides:
getPageNotFoundContent
in classPreviewHtmlPageContentProvider
- Returns:
- string text content, never
null
- Throws:
IOException
- if an I/O error occurs
-
-