Class SassImportHelper
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.core.ui.resources.css.sass.SassImportHelper
- All Implemented Interfaces:
LogEnabled
,Component
,Serviceable
Helper component for sass contents
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Informations about sass import, such as real URI and real last modified -
Field Summary
Modifier and TypeFieldDescriptionprotected JSASSResourceURIExtensionPoint
JsassResourceURIExtensionPointprotected SourceResolver
The source resolverstatic final String
The avalon ROLE -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfindExistingImportSource
(List<String> uriMatching) Find the first existing import source from a list of URIs to trygetDependenciesList
(Source inputSource) Get the list of direct dependencies of a sass sourcegetImportSource
(String currentUri) Get the Sass source from the current Urivoid
service
(ServiceManager manager) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
ROLE
The avalon ROLE -
_resolver
The source resolver -
_jsassResourceURIExtensionPoint
JsassResourceURIExtensionPoint
-
-
Constructor Details
-
SassImportHelper
public SassImportHelper()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
getDependenciesList
Get the list of direct dependencies of a sass source- Parameters:
inputSource
- The sass source- Returns:
- The list of dependencies, mapped by URI
-
getImportSource
Get the Sass source from the current Uri- Parameters:
currentUri
- The URI- Returns:
- The real URI, the Sass source and its last modified
-
findExistingImportSource
Find the first existing import source from a list of URIs to try- Parameters:
uriMatching
- The list of URIs to try- Returns:
- the first matching source, or null if no source matches
-