| 程序包 | 说明 |
|---|---|
| com.github.jarvisframework.tool.core.bean | |
| com.github.jarvisframework.tool.core.lang |
| 限定符和类型 | 方法和说明 |
|---|---|
BeanDesc |
BeanDescCache.getBeanDesc(Class<?> beanClass,
Func0<BeanDesc> supplier)
获得属性名和
BeanDescMap映射 |
Map<String,PropertyDescriptor> |
BeanInfoCache.getPropertyDescriptorMap(Class<?> beanClass,
boolean ignoreCase,
Func0<Map<String,PropertyDescriptor>> supplier)
获得属性名和
PropertyDescriptorMap映射 |
| 限定符和类型 | 方法和说明 |
|---|---|
V |
SimpleCache.get(K key,
Func0<V> supplier)
从缓存中获得对象,当对象不在缓存中或已经过期返回Func0回调产生的对象
|
static <T> T |
Singleton.get(String key,
Func0<T> supplier)
获得指定类的单例对象
对象存在于池中返回,否则创建,每次调用此方法获得的对象为同一个对象 注意:单例针对的是类和参数,也就是说只有类、参数一致才会返回同一个对象 |
static <X extends Throwable> |
Assert.isTrue(boolean expression,
Func0<? extends X> supplier)
断言是否为真,如果为
false 抛出给定的异常Assert.isTrue(i > 0, IllegalArgumentException::new); |
Copyright © 2020. All rights reserved.