Darano

Untitled

Oct 14th, 2018
175
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.27 KB | None | 0 0
  1.     //what you do
  2.    
  3.     small.addActionListener(new ActionListener() {
  4.         @Override
  5.         public void actionPerformed(ActionEvent e) {
  6.             System.out.println("hello");
  7.         }
  8.     });
  9.    
  10.     //with lambda
  11.     small.addActionListener((ActionListener -> System.out.println("Hello")));
Advertisement
Add Comment
Please, Sign In to add comment