@@ -105,6 +105,100 @@ public DefaultRedisZSet(BoundZSetOperations<String, E> boundOps, double defaultS
105105 this .defaultScore = defaultScore ;
106106 }
107107
108+ /*
109+ * (non-Javadoc)
110+ * @see org.springframework.data.redis.support.collections.RedisZSet#difference(org.springframework.data.redis.support.collections.RedisZSet)
111+ */
112+ @ Override
113+ public Set <E > difference (RedisZSet <?> set ) {
114+ return boundZSetOps .difference (set .getKey ());
115+ }
116+
117+ /*
118+ * (non-Javadoc)
119+ * @see org.springframework.data.redis.support.collections.RedisZSet#difference(java.util.Collection)
120+ */
121+ @ Override
122+ public Set <E > difference (Collection <? extends RedisZSet <?>> sets ) {
123+ return boundZSetOps .difference (CollectionUtils .extractKeys (sets ));
124+ }
125+
126+ /*
127+ * (non-Javadoc)
128+ * @see org.springframework.data.redis.support.collections.RedisZSet#differenceWithScores(org.springframework.data.redis.support.collections.RedisZSet)
129+ */
130+ @ Override
131+ public Set <TypedTuple <E >> differenceWithScores (RedisZSet <?> set ) {
132+ return boundZSetOps .differenceWithScores (set .getKey ());
133+ }
134+
135+ /*
136+ * (non-Javadoc)
137+ * @see org.springframework.data.redis.support.collections.RedisZSet#differenceWithScores(java.util.Collection)
138+ */
139+ @ Override
140+ public Set <TypedTuple <E >> differenceWithScores (Collection <? extends RedisZSet <?>> sets ) {
141+ return boundZSetOps .differenceWithScores (CollectionUtils .extractKeys (sets ));
142+ }
143+
144+ /*
145+ * (non-Javadoc)
146+ * @see org.springframework.data.redis.support.collections.RedisZSet#differenceAndStore(org.springframework.data.redis.support.collections.RedisZSet, java.lang.String)
147+ */
148+ @ Override
149+ public RedisZSet <E > differenceAndStore (RedisZSet <?> set , String destKey ) {
150+
151+ boundZSetOps .differenceAndStore (set .getKey (), destKey );
152+ return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
153+ }
154+
155+ /*
156+ * (non-Javadoc)
157+ * @see org.springframework.data.redis.support.collections.RedisZSet#differenceAndStore(java.util.Collection, java.lang.String)
158+ */
159+ @ Override
160+ public RedisZSet <E > differenceAndStore (Collection <? extends RedisZSet <?>> sets , String destKey ) {
161+
162+ boundZSetOps .differenceAndStore (CollectionUtils .extractKeys (sets ), destKey );
163+ return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
164+ }
165+
166+ /*
167+ * (non-Javadoc)
168+ * @see org.springframework.data.redis.support.collections.RedisZSet#intersect(org.springframework.data.redis.support.collections.RedisZSet)
169+ */
170+ @ Override
171+ public Set <E > intersect (RedisZSet <?> set ) {
172+ return boundZSetOps .intersect (set .getKey ());
173+ }
174+
175+ /*
176+ * (non-Javadoc)
177+ * @see org.springframework.data.redis.support.collections.RedisZSet#intersect(java.util.Collection)
178+ */
179+ @ Override
180+ public Set <E > intersect (Collection <? extends RedisZSet <?>> sets ) {
181+ return boundZSetOps .intersect (CollectionUtils .extractKeys (sets ));
182+ }
183+
184+ /*
185+ * (non-Javadoc)
186+ * @see org.springframework.data.redis.support.collections.RedisZSet#intersectWithScores(org.springframework.data.redis.support.collections.RedisZSet)
187+ */
188+ @ Override
189+ public Set <TypedTuple <E >> intersectWithScores (RedisZSet <?> set ) {
190+ return boundZSetOps .intersectWithScores (set .getKey ());
191+ }
192+
193+ /*
194+ * (non-Javadoc)
195+ * @see org.springframework.data.redis.support.collections.RedisZSet#intersectWithScores(java.util.Collection)
196+ */
197+ @ Override
198+ public Set <TypedTuple <E >> intersectWithScores (Collection <? extends RedisZSet <?>> sets ) {
199+ return boundZSetOps .intersectWithScores (CollectionUtils .extractKeys (sets ));
200+ }
201+
108202 /*
109203 * (non-Javadoc)
110204 * @see org.springframework.data.redis.support.collections.RedisZSet#intersectAndStore(org.springframework.data.redis.support.collections.RedisZSet, java.lang.String)
@@ -127,6 +221,62 @@ public RedisZSet<E> intersectAndStore(Collection<? extends RedisZSet<?>> sets, S
127221 return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
128222 }
129223
224+ /*
225+ * (non-Javadoc)
226+ * @see org.springframework.data.redis.support.collections.RedisZSet#union(org.springframework.data.redis.support.collections.RedisZSet)
227+ */
228+ @ Override
229+ public Set <E > union (RedisZSet <?> set ) {
230+ return boundZSetOps .union (set .getKey ());
231+ }
232+
233+ /*
234+ * (non-Javadoc)
235+ * @see org.springframework.data.redis.support.collections.RedisZSet#union(java.util.Collection)
236+ */
237+ @ Override
238+ public Set <E > union (Collection <? extends RedisZSet <?>> sets ) {
239+ return boundZSetOps .union (CollectionUtils .extractKeys (sets ));
240+ }
241+
242+ /*
243+ * (non-Javadoc)
244+ * @see org.springframework.data.redis.support.collections.RedisZSet#unionWithScores(org.springframework.data.redis.support.collections.RedisZSet)
245+ */
246+ @ Override
247+ public Set <TypedTuple <E >> unionWithScores (RedisZSet <?> set ) {
248+ return boundZSetOps .unionWithScores (set .getKey ());
249+ }
250+
251+ /*
252+ * (non-Javadoc)
253+ * @see org.springframework.data.redis.support.collections.RedisZSet#unionWithScores(java.util.Collection)
254+ */
255+ @ Override
256+ public Set <TypedTuple <E >> unionWithScores (Collection <? extends RedisZSet <?>> sets ) {
257+ return boundZSetOps .unionWithScores (CollectionUtils .extractKeys (sets ));
258+ }
259+
260+ /*
261+ * (non-Javadoc)
262+ * @see org.springframework.data.redis.support.collections.RedisZSet#unionAndStore(org.springframework.data.redis.support.collections.RedisZSet, java.lang.String)
263+ */
264+ @ Override
265+ public RedisZSet <E > unionAndStore (RedisZSet <?> set , String destKey ) {
266+ boundZSetOps .unionAndStore (set .getKey (), destKey );
267+ return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
268+ }
269+
270+ /*
271+ * (non-Javadoc)
272+ * @see org.springframework.data.redis.support.collections.RedisZSet#unionAndStore(java.util.Collection, java.lang.String)
273+ */
274+ @ Override
275+ public RedisZSet <E > unionAndStore (Collection <? extends RedisZSet <?>> sets , String destKey ) {
276+ boundZSetOps .unionAndStore (CollectionUtils .extractKeys (sets ), destKey );
277+ return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
278+ }
279+
130280 /*
131281 * (non-Javadoc)
132282 * @see org.springframework.data.redis.support.collections.RedisZSet#range(long, long)
@@ -247,26 +397,6 @@ public RedisZSet<E> removeByScore(double min, double max) {
247397 return this ;
248398 }
249399
250- /*
251- * (non-Javadoc)
252- * @see org.springframework.data.redis.support.collections.RedisZSet#unionAndStore(org.springframework.data.redis.support.collections.RedisZSet, java.lang.String)
253- */
254- @ Override
255- public RedisZSet <E > unionAndStore (RedisZSet <?> set , String destKey ) {
256- boundZSetOps .unionAndStore (set .getKey (), destKey );
257- return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
258- }
259-
260- /*
261- * (non-Javadoc)
262- * @see org.springframework.data.redis.support.collections.RedisZSet#unionAndStore(java.util.Collection, java.lang.String)
263- */
264- @ Override
265- public RedisZSet <E > unionAndStore (Collection <? extends RedisZSet <?>> sets , String destKey ) {
266- boundZSetOps .unionAndStore (CollectionUtils .extractKeys (sets ), destKey );
267- return new DefaultRedisZSet <>(boundZSetOps .getOperations ().boundZSetOps (destKey ), getDefaultScore ());
268- }
269-
270400 /*
271401 * (non-Javadoc)
272402 * @see java.util.AbstractCollection#add(java.lang.Object)
0 commit comments