• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

alibaba / jetcache / #405

16 Apr 2024 05:58AM UTC coverage: 0.0% (-88.9%) from 88.866%
#405

push

areyouok
add encoding to fix coverage report

0 of 5353 relevant lines covered (0.0%)

0.0 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/jetcache-core/src/main/java/com/alicp/jetcache/MultiLevelCacheBuilder.java
1
package com.alicp.jetcache;
2

3
import java.util.List;
4
import java.util.concurrent.TimeUnit;
5
import java.util.function.Function;
6

7
/**
8
 * Created on 2017/5/24.
9
 *
10
 * @author huangli
11
 */
12
public class MultiLevelCacheBuilder<T extends MultiLevelCacheBuilder<T>> extends AbstractCacheBuilder<T> {
13
    public static class MultiLevelCacheBuilderImpl extends MultiLevelCacheBuilder<MultiLevelCacheBuilderImpl> {
×
14
    }
15

16
    public static MultiLevelCacheBuilderImpl createMultiLevelCacheBuilder() {
17
        return new MultiLevelCacheBuilderImpl();
×
18
    }
19

20
    protected MultiLevelCacheBuilder() {
×
21
        buildFunc(config -> new MultiLevelCache((MultiLevelCacheConfig) config));
×
22
    }
×
23

24
    @Override
25
    public MultiLevelCacheConfig getConfig() {
26
        if (config == null) {
×
27
            config = new MultiLevelCacheConfig();
×
28
        }
29
        return (MultiLevelCacheConfig) config;
×
30
    }
31

32
    public T addCache(Cache... caches) {
33
        for (Cache c : caches) {
×
34
            getConfig().getCaches().add(c);
×
35
        }
36
        return self();
×
37
    }
38

39
    public void setCaches(List<Cache> caches) {
40
        getConfig().setCaches(caches);
×
41
    }
×
42

43
    public T useExpireOfSubCache(boolean useExpireOfSubCache) {
44
        getConfig().setUseExpireOfSubCache(useExpireOfSubCache);
×
45
        return self();
×
46
    }
47

48
    public void setUseExpireOfSubCache(boolean useExpireOfSubCache) {
49
        getConfig().setUseExpireOfSubCache(useExpireOfSubCache);
×
50
    }
×
51

52
    @Override
53
    public T keyConvertor(Function<Object, Object> keyConvertor) {
54
        throw new UnsupportedOperationException("MultiLevelCache do not need a key convertor");
×
55
    }
56

57
    @Override
58
    public void setKeyConvertor(Function<Object, Object> keyConvertor) {
59
        throw new UnsupportedOperationException("MultiLevelCache do not need a key convertor");
×
60
    }
61

62
    @Override
63
    public T expireAfterAccess(long defaultExpire, TimeUnit timeUnit) {
64
        throw new UnsupportedOperationException("MultiLevelCache do not support expireAfterAccess");
×
65
    }
66

67
    @Override
68
    public void setExpireAfterAccessInMillis(long expireAfterAccessInMillis) {
69
        throw new UnsupportedOperationException("MultiLevelCache do not support expireAfterAccess");
×
70
    }
71

72
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc