mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-22 14:50:53 +07:00
21 lines
461 B
Java
21 lines
461 B
Java
|
|
import java.util.ArrayList;
|
|
import java.util.Collection;
|
|
|
|
public class ExtractVariableSample {
|
|
|
|
public static void main(String[] args) {
|
|
Collection<String> strings = new ArrayList<>();
|
|
new Object() {
|
|
public void foo(String s) {
|
|
System.out.println( s.hashCode());
|
|
}
|
|
};
|
|
|
|
for (String s : strings) {
|
|
System.out.println(<selection>s.hashCode()</selection>);
|
|
}
|
|
}
|
|
|
|
|
|
} |