com.alibaba.dubbo.common.beanutil.JavaBeanDescriptor Maven / Gradle / Ivy
/*
* Copyright 1999-2012 Alibaba Group.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* 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.
*/
package com.alibaba.dubbo.common.beanutil;
import java.io.Serializable;
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.Map;
/**
* @author kimi
*/
public final class JavaBeanDescriptor implements Serializable, Iterable> {
private static final long serialVersionUID = -8505586483570518029L;
public static final int TYPE_CLASS = 1;
public static final int TYPE_ENUM = 2;
public static final int TYPE_COLLECTION = 3;
public static final int TYPE_MAP = 4;
public static final int TYPE_ARRAY = 5;
/** @see com.alibaba.dubbo.common.utils.ReflectUtils#isPrimitive(Class) */
public static final int TYPE_PRIMITIVE = 6;
public static final int TYPE_BEAN = 7;
private static final String ENUM_PROPERTY_NAME = "name";
private static final String CLASS_PROPERTY_NAME = "name";
private static final String PRIMITIVE_PROPERTY_VALUE = "value";
/**
* Used to define a type is valid.
* @see #isValidType(int)
*/
private static final int TYPE_MAX = TYPE_BEAN;
/**
* Used to define a type is valid.
* @see #isValidType(int)
*/
private static final int TYPE_MIN = TYPE_CLASS;
private String className;
private int type;
private Map
© 2015 - 2025 Weber Informatics LLC | Privacy Policy