class R4CodeFhirToDhisTransformerUtils extends AbstractCodeFhirToDhisTransformerUtils {

    @Override
    public boolean containsMappingCode( @Nullable ICompositeType codeableConcept, @Nullable Object mappingCodes )
    {
        if ( mappingCodes == null )
        {
            throw new IllegalArgumentException( "Codes must be specified." );
        }

        if ( (codeableConcept == null) || codeableConcept.isEmpty() )
        {
            return false;
        }
        final List<String> convertedCodes = ScriptArgUtils.extractStringArray( mappingCodes );
        if ( CollectionUtils.isEmpty( convertedCodes ) )
        {
            return false;
        }

        final Set<String> checkedCodes = new HashSet<>();
        final Collection<SystemCode> systemCodes = getSystemCodeRepository().findAllByCodes( convertedCodes );
        for ( final SystemCode systemCode : systemCodes )
        {
            if ( containsCode( codeableConcept, systemCode.getSystem().getSystemUri(), systemCode.getSystemCode() ) )
            {
                return true;
            }
            checkedCodes.add( systemCode.getCode().getCode() );
        }
        if ( logger.isDebugEnabled() && (checkedCodes.size() < convertedCodes.size()) )
        {
            logger.info( "Codes have not been defined: " + Sets.difference( new HashSet<>( convertedCodes ), checkedCodes ) );
        }
        return false;
    }

    public  R4CodeFhirToDhisTransformerUtils( @Nonnull ScriptExecutionContext scriptExecutionContext,
        @Nonnull CodeRepository codeRepository,
        @Nonnull SystemCodeRepository systemCodeRepository );

}