Eclipse giving me a warning saying

Code:

    p.addActionListener(new ActionListener(){public void actionPerformed(ActionEvent e)
    {

        System.out.println("Welcome to Guess the number Game");
        System.out.println("You have 3 chances to guess a number between 0 and 10 excluding 10");

        ne.remove(p);

        //ne.removeAll();
        ne.revalidate();
        ne.repaint();}
       public void cam()
       {

        gamer2 game=new gamer2();
        game.generatenum();
       }
    }

    ); 

p is a JButton.

Eclipse is giving me a warning saying:"The method cam() from the type new ActionListener(){} is never used locally.

Why is it giving that warning?


Click here view more answers http://ift.tt/1QXlgDf