1 |
|
|
2 |
|
|
3 |
|
|
4 |
|
|
5 |
|
|
6 |
|
|
7 |
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 |
|
|
15 |
|
|
16 |
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
|
package com.xpn.xwiki.internal.objects; |
21 |
|
|
22 |
|
import java.util.ArrayList; |
23 |
|
|
24 |
|
import org.hibernate.collection.PersistentList; |
25 |
|
import org.hibernate.engine.SessionImplementor; |
26 |
|
|
27 |
|
import com.xpn.xwiki.objects.ListProperty; |
28 |
|
import com.xpn.xwiki.objects.ListProperty.NotifyList; |
29 |
|
|
30 |
|
|
31 |
|
|
32 |
|
|
33 |
|
@since |
34 |
|
@version |
35 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (12) |
Complexity: 5 |
Complexity Density: 0.83 |
|
36 |
|
public class ListPropertyPersistentList extends PersistentList |
37 |
|
{ |
38 |
|
|
39 |
|
|
40 |
|
@param@link |
41 |
|
@param |
42 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
43 |
249 |
public ListPropertyPersistentList(SessionImplementor session, NotifyList list)... |
44 |
|
{ |
45 |
249 |
super(session, list); |
46 |
|
} |
47 |
|
|
48 |
|
|
49 |
|
@param@link |
50 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
51 |
358 |
public ListPropertyPersistentList(SessionImplementor session)... |
52 |
|
{ |
53 |
358 |
super(session); |
54 |
|
} |
55 |
|
|
56 |
|
|
57 |
|
@param |
58 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (5) |
Complexity: 2 |
Complexity Density: 0.67 |
|
59 |
7103 |
@SuppressWarnings("unchecked")... |
60 |
|
public void setOwner(ListProperty owner) |
61 |
|
{ |
62 |
7101 |
if (this.list == null) { |
63 |
358 |
this.list = new NotifyList(new ArrayList<String>()); |
64 |
|
} |
65 |
7103 |
((NotifyList) this.list).setOwner(owner); |
66 |
|
} |
67 |
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
68 |
55 |
@Override... |
69 |
|
@SuppressWarnings("unchecked") |
70 |
|
public boolean isWrapper(Object collection) |
71 |
|
{ |
72 |
55 |
return collection == this.list || ((NotifyList) this.list).isWrapper(collection); |
73 |
|
} |
74 |
|
} |