Package cn.com.annotations

Examples of cn.com.annotations.Element


     */
    private Group getDefaultGroup() throws AppException {
        final List<Element> elements = new ArrayList<Element>(20);
        final List<Grid> grids = new ArrayList<Grid>(3);
        final List<Field> fields = TypeContentRefecter.getAllFields(this.clazz);
        Element element = null;
        Grid grid = null;
        Object value = null;
        for (Field field : fields) {
            element = field.getAnnotation(Element.class);
            grid = field.getAnnotation(Grid.class);
View Full Code Here


    /**
     * 设定元素的默认值
     */
    public void settingDefaultValue() throws AppException {
        final List<Field> fields = TypeContentRefecter.getAllFields(this.clazz);
        Element element = null;
        for (Field field : fields) {
            element = field.getAnnotation(Element.class);
            if (element != null && !StringUtil.isEmpty(element.defaultValue())) {
                _VALIDATOR.validate(element);
                // 保存元素内容
                elementValue.put(field.getName(), _FORMATTER.converObject(element.format(), element.defaultValue()));

            }
        }
    }
View Full Code Here

TOP

Related Classes of cn.com.annotations.Element

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.