Package ch.tocco.nice2.dms.impl.uri
Class UriConversionServiceImpl
java.lang.Object
ch.tocco.nice2.dms.impl.uri.UriConversionServiceImpl
- All Implemented Interfaces:
UriConversionService
-
Constructor Summary
ConstructorsConstructorDescriptionUriConversionServiceImpl(UriConverterRegistry uriConverterRegistry, UriFactoryRegistry uriFactoryRegistry, org.slf4j.Logger log) -
Method Summary
Modifier and TypeMethodDescriptionConvert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.convert(Set<Class<? extends NiceUri>> sourceClasses, Class<? extends NiceUri> targetClass, String html) Convert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.convertIgnoreUriConverterException(Class<? extends NiceUri> sourceClass, Class<? extends NiceUri> targetClass, String html) Convert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.convertIgnoreUriConverterException(Set<Class<? extends NiceUri>> sourceClasses, Class<? extends NiceUri> targetClass, String html) Convert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.
-
Constructor Details
-
UriConversionServiceImpl
public UriConversionServiceImpl(UriConverterRegistry uriConverterRegistry, UriFactoryRegistry uriFactoryRegistry, org.slf4j.Logger log)
-
-
Method Details
-
convert
public String convert(Class<? extends NiceUri> sourceClass, Class<? extends NiceUri> targetClass, String html) Description copied from interface:UriConversionServiceConvert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.- Specified by:
convertin interfaceUriConversionService- Parameters:
sourceClass- The class of the URIs to convert.targetClass- The class to convert the found URIs into.html- The html string that contains the URIs to convert.- Returns:
- The new html string containing the converted URIs.
- See Also:
-
convertIgnoreUriConverterException
public String convertIgnoreUriConverterException(Class<? extends NiceUri> sourceClass, Class<? extends NiceUri> targetClass, String html) Description copied from interface:UriConversionServiceConvert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string. If an URI conversion fails throwing anUriConverterExceptionit is skipped and the exception is logged.- Specified by:
convertIgnoreUriConverterExceptionin interfaceUriConversionService- Parameters:
sourceClass- The class of the URIs to convert.targetClass- The class to convert the found URIs into.html- The html string that contains the URIs to convert.- Returns:
- The new html string containing the converted URIs.
- See Also:
-
convert
public String convert(Set<Class<? extends NiceUri>> sourceClasses, Class<? extends NiceUri> targetClass, String html) Description copied from interface:UriConversionServiceConvert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string.- Specified by:
convertin interfaceUriConversionService- Parameters:
sourceClasses- The classes of the URIs to convert.targetClass- The class to convert the found URIs into.html- The html string that contains the URIs to convert.- Returns:
- The new html string containing the converted URIs.
- See Also:
-
convertIgnoreUriConverterException
public String convertIgnoreUriConverterException(Set<Class<? extends NiceUri>> sourceClasses, Class<? extends NiceUri> targetClass, String html) Description copied from interface:UriConversionServiceConvert all URIs of typesourceClassinto URIs of typetargetClassin given html stringhtmland return the new html string. If an URI conversion fails throwing anUriConverterExceptionit is skipped and the exception is logged.- Specified by:
convertIgnoreUriConverterExceptionin interfaceUriConversionService- Parameters:
sourceClasses- The classes of the URIs to convert.targetClass- The class to convert the found URIs into.html- The html string that contains the URIs to convert.- Returns:
- The new html string containing the converted URIs.
- See Also:
-