@@ 113-128 (lines=16) @@ | ||
110 | var list = this; |
|
111 | return list != null && list[list.length - 1] == value; |
|
112 | }, |
|
113 | count: function(value, not = false){ |
|
114 | var list = this; |
|
115 | var total = 0; |
|
116 | for (var a = 0, al = list.length;a<al;a++){ |
|
117 | if (not) { |
|
118 | if (list[a] != value) { |
|
119 | total++; |
|
120 | } |
|
121 | }else { |
|
122 | if (list[a] == value) { |
|
123 | total++; |
|
124 | } |
|
125 | } |
|
126 | } |
|
127 | return total; |
|
128 | }, |
|
129 | or: function(list2){ |
|
130 | var list = this; |
|
131 | if (Exists(list)) { |
|
@@ 65-76 (lines=12) @@ | ||
62 | } |
|
63 | return -1; |
|
64 | }, |
|
65 | lastIndexOf: function(value){ |
|
66 | var list = this; |
|
67 | if (list.length === 0) { |
|
68 | return -1; |
|
69 | } |
|
70 | for (var a = list.length-1;a>=0;a--){ |
|
71 | if (list[a] == value){ |
|
72 | return a; |
|
73 | } |
|
74 | } |
|
75 | return -1; |
|
76 | }, |
|
77 | isEqual: function(list2){ |
|
78 | var list = this; |
|
79 | if (list == null || list2 == null) { |