Module buralotech.identifier.spring
Class IdentifierConverter
java.lang.Object
com.buralotech.oss.identifier.spring.IdentifierConverter
- All Implemented Interfaces:
org.springframework.core.convert.converter.Converter<String,Identifier>
public class IdentifierConverter
extends Object
implements org.springframework.core.convert.converter.Converter<String,Identifier>
Used to bind/inject identifiers in their text representation as identifiers objects.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionIdentifierConverter(IdentifierService identifierService) Initialise the converter. -
Method Summary
Modifier and TypeMethodDescriptionPerform the conversion by delegating to the identifier service.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.core.convert.converter.Converter
andThen
-
Field Details
-
identifierService
The identifier service.
-
-
Constructor Details
-
IdentifierConverter
Initialise the converter.- Parameters:
identifierService- The identifier service.
-
-
Method Details
-
convert
Perform the conversion by delegating to the identifier service.- Specified by:
convertin interfaceorg.springframework.core.convert.converter.Converter<String,Identifier> - Parameters:
source- The textual representation of the identifier.- Returns:
- The identifier object.
-