Skip to content

Commit 18f933d

Browse files
authored
Merge pull request #46 from dai0304/feature/make-ChunkImpl-list-immutable
make Chunkimpl#content immutable
2 parents 73ac07b + fa33c9e commit 18f933d

File tree

1 file changed

+6
-6
lines changed
  • spar-wings-spring-data-chunk/src/main/java/jp/xet/sparwings/spring/data/chunk

1 file changed

+6
-6
lines changed

spar-wings-spring-data-chunk/src/main/java/jp/xet/sparwings/spring/data/chunk/ChunkImpl.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -204,12 +204,12 @@ public <T1> T1[] toArray(T1[] a) {
204204

205205
@Override
206206
public boolean add(T t) {
207-
return content.add(t);
207+
throw new UnsupportedOperationException();
208208
}
209209

210210
@Override
211211
public boolean remove(Object o) {
212-
return content.remove(o);
212+
throw new UnsupportedOperationException();
213213
}
214214

215215
@Override
@@ -219,22 +219,22 @@ public boolean containsAll(Collection<?> c) {
219219

220220
@Override
221221
public boolean addAll(Collection<? extends T> c) {
222-
return content.addAll(c);
222+
throw new UnsupportedOperationException();
223223
}
224224

225225
@Override
226226
public boolean removeAll(Collection<?> c) {
227-
return content.removeAll(c);
227+
throw new UnsupportedOperationException();
228228
}
229229

230230
@Override
231231
public boolean retainAll(Collection<?> c) {
232-
return c.retainAll(c);
232+
throw new UnsupportedOperationException();
233233
}
234234

235235
@Override
236236
public void clear() {
237-
content.clear();
237+
throw new UnsupportedOperationException();
238238
}
239239

240240
@Override

0 commit comments

Comments
 (0)