public class ClassUtils extends Object
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
| Modifier and Type | Class and Description |
|---|---|
static class |
ClassUtils.ContentPropertyKey |
static class |
ClassUtils.FieldCacheKey |
| Modifier and Type | Field and Description |
|---|---|
static ConcurrentHashMap<Class<?>,Map<String,ExcelContentProperty>> |
CLASS_CONTENT_CACHE
The cache configuration information for each of the class
|
static ConcurrentHashMap<ClassUtils.ContentPropertyKey,ExcelContentProperty> |
CONTENT_CACHE
The cache configuration information for each of the class
|
static Map<ClassUtils.FieldCacheKey,FieldCache> |
FIELD_CACHE
memory cache
|
| Constructor and Description |
|---|
ClassUtils() |
| Modifier and Type | Method and Description |
|---|---|
static void |
combineExcelContentProperty(ExcelContentProperty combineExcelContentProperty,
ExcelContentProperty excelContentProperty) |
static ExcelContentProperty |
declaredExcelContentProperty(Map<?,?> dataMap,
Class<?> headClazz,
String fieldName,
ConfigurationHolder configurationHolder)
Calculate the configuration information for the class
|
static FieldCache |
declaredFields(Class<?> clazz,
ConfigurationHolder configurationHolder)
Parsing field in the class
|
static List<Class<?>> |
getAllInterfaces(Class<?> cls)
Gets a
List of all interfaces implemented by the given
class and its superclasses. |
static void |
removeThreadLocalCache() |
public static final Map<ClassUtils.FieldCacheKey,FieldCache> FIELD_CACHE
public static final ConcurrentHashMap<Class<?>,Map<String,ExcelContentProperty>> CLASS_CONTENT_CACHE
public static final ConcurrentHashMap<ClassUtils.ContentPropertyKey,ExcelContentProperty> CONTENT_CACHE
public static ExcelContentProperty declaredExcelContentProperty(Map<?,?> dataMap, Class<?> headClazz, String fieldName, ConfigurationHolder configurationHolder)
dataMap - headClazz - fieldName - public static void combineExcelContentProperty(ExcelContentProperty combineExcelContentProperty, ExcelContentProperty excelContentProperty)
public static FieldCache declaredFields(Class<?> clazz, ConfigurationHolder configurationHolder)
clazz - Need to parse the classconfigurationHolder - configurationpublic static List<Class<?>> getAllInterfaces(Class<?> cls)
Gets a List of all interfaces implemented by the given
class and its superclasses.
The order is determined by looking through each interface in turn as declared in the source file and following its hierarchy up. Then each superclass is considered in the same way. Later duplicates are ignored, so the order is maintained.
cls - the class to look up, may be nullList of interfaces in order,
null if null inputpublic static void removeThreadLocalCache()
Copyright © 2018–2023 Alibaba Group. All rights reserved.