class Utils {

    public static boolean meetsMinimumVersion( String version, float minimumVersion ) {

        if( "Unknown".equals( version ) || version.matches( "\\b[0-9a-f]{5,40}\\b" ) ) {

            return false;
        }

        String cleanVersion = version;
        if( cleanVersion.startsWith( "v" ) ) {
            cleanVersion = cleanVersion.substring( 1 );
        }

        if( cleanVersion.contains( "-" ) ) {

            cleanVersion = cleanVersion.substring( 0, cleanVersion.indexOf( '-' ) );

        }

        if( cleanVersion.length() > 4 ) {

            cleanVersion = cleanVersion.substring( 0, 4 );

        }

        try {

            Float.parseFloat( cleanVersion );

        } catch( NumberFormatException e ) {

            return false;
        }

        float extractedVersion = Float.parseFloat( cleanVersion );

        if( !cleanVersion.startsWith( "0" ) ) {

            extractedVersion *= 100;

        }

        return ( extractedVersion >= minimumVersion );
    }

    private  Utils();

}