Class DefaultMacroIconManager
java.lang.Object
com.atlassian.confluence.macro.browser.DefaultMacroIconManager
- All Implemented Interfaces:
MacroIconManager
- Since:
- 4.2.6
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultMacroIconManager
(com.atlassian.sal.api.net.RequestFactory<?> requestFactory, com.atlassian.plugin.servlet.ServletContextFactory servletContextFactory, com.atlassian.webresource.api.WebResourceUrlProvider webResourceUrlProvider, com.atlassian.plugin.webresource.PluginResourceLocator pluginResourceLocator) -
Method Summary
Modifier and TypeMethodDescriptiongetExternalSmallIconUrl
(MacroMetadata macroMetadata) Retrieve a the Url to a small icon for a macro.getIconStream
(MacroMetadata macroMetadata) Retrieve an inputStream of the macro's icon.
-
Constructor Details
-
DefaultMacroIconManager
public DefaultMacroIconManager(com.atlassian.sal.api.net.RequestFactory<?> requestFactory, com.atlassian.plugin.servlet.ServletContextFactory servletContextFactory, com.atlassian.webresource.api.WebResourceUrlProvider webResourceUrlProvider, com.atlassian.plugin.webresource.PluginResourceLocator pluginResourceLocator) - Since:
- 7.0.1
-
-
Method Details
-
getExternalSmallIconUrl
Description copied from interface:MacroIconManager
Retrieve a the Url to a small icon for a macro. This is the size used in the dropdown and the placeholders used in diffs.- Specified by:
getExternalSmallIconUrl
in interfaceMacroIconManager
- Parameters:
macroMetadata
- the metadata for the macro to retrieve the icon url for- Returns:
- an absolute url to the icon, it will be to the placeholder icon if no icon is specified and there isn't a local icon for the dropdown.
-
getIconStream
Description copied from interface:MacroIconManager
Retrieve an inputStream of the macro's icon.- Specified by:
getIconStream
in interfaceMacroIconManager
- Parameters:
macroMetadata
- the metadata for the macro- Returns:
- the input stream of the best icon for the macro. The default is the placeholder icon.
-