zoukankan      html  css  js  c++  java
  • nvelocity的解析Bug

    nvelocity的一个解析Bug,看来源代码发现

    代码
    namespace NVelocity.App
    {
        
    using System;
        
    using System.Collections.Generic;
        
    using System.Reflection;

        
    public class FieldMethodizer
        {
     .......................

         
    private void Inspect(Type type)
            {
                FieldInfo[] fields 
    = type.GetFields();
                
    for (int i = 0; i < fields.Length; i++)
                {
                    
    if (fields[i].IsPublic && fields[i].IsStatic)
                    {
                        
    this.fieldHash[fields[i].Name] = fields[i];
                        
    this.classHash[fields[i].Name] = type;
                    }
                }
            }
        }
    }


    居然只反射 Field 忘了 Property 昏。。 代码是1.1版本的

  • 相关阅读:
    Andoird注册功能
    android注册功能
    寒假周总结六
    android登录功能
    Android登录功能
    android登录功能
    每日日报2021.1.24
    每日博客2021.1.23
    每日日报2021.1.22
    每日日报2021.1.21
  • 原文地址:https://www.cnblogs.com/chenxianbin89/p/1933641.html
Copyright © 2011-2022 走看看