B4J Question error: lambda expressions are not supported in -source 1.7

I have tried with jdk 11 and the lambda problem disappears but some important libraries are affected for me, is it possible to revert this lambda to traditional code?
B4X: Copy
    public static void main(int intport) 
    {
        VpnServer myVPN = new VpnServer(intport);
        myVPN.listen();
    }
    ------
    ------
        public void listen()
    {
        new Thread(() -> {
            while(running.get() && (serverSocket != null) && serverSocket.isBound())
            {
                try { serviceThreads.add(new RequestHandler(serverSocket.accept())); }
                catch(SocketTimeoutException e1) { /* Nothing to do here */ }
                catch (IOException e2) { e2.printStackTrace(); }
            }
        }).start();
    }
 
Upvote 0
Back
Top