java source code, what's the meaning of swap(List<?> list, int i, int j) {final List l = list;…} [on hold]

54
January 11, 2019, at 10:40 AM

I am new to java. It is the first time I see java source codes. Wonderful. But I don't know what's the meaning of "final List l = list". IF directly use "list", there will be compile error. could you give me instructions? thanks!!

private static void swap(List<?> list, int i, int j) {
    final List l = list;
    l.set(i, l.get(j));
    l.set(i, l.set(j, l.get(i)));
}
READ ALSO
BCrypt updating the library and interations - would it break my login?

BCrypt updating the library and interations - would it break my login?

I’ve an old legacy application using Spring Security (31

71
How would you insert one node into another at the treepath?

How would you insert one node into another at the treepath?

I have two nodes and one TreePath in Java SwingOne node contains the 'root' node (let's call this nodeA), it contains everything under it

62
How to lazy fetch only parts of the children entity from the parent entity?

How to lazy fetch only parts of the children entity from the parent entity?

I have a class Department that has a child entity Student(Many to one relationship as a Department can have many students List<Student>

41