1. XenForo 1.5.14 中文版——支持中文搜索!现已发布!查看详情
  2. Xenforo 爱好者讨论群:215909318 XenForo专区

新闻 feilong-core 1.9.2,让开发更简便的Java开发工具包 下载

本帖由 漂亮的石头2016-10-24 发布。版面名称:软件资讯

  1. 漂亮的石头

    漂亮的石头 版主 管理成员

    注册:
    2012-02-10
    帖子:
    487,979
    赞:
    47
    feilong-core 1.9.2 发布了,feilong-core 是一个让开发更简便的Java 开发工具包。

    简介:


    1. 目标:Reduce development, Release ideas


    2. 可以帮助你的代码更简短精炼,使它易写、易读、易于维护。


    3. 提高工作效率,让你从大量重复的底层代码中脱身。
    使用feilong-core的理由:

    一图概述:


    [​IMG]

    Maven使用配置


    feilong-core jar你可以直接在 仓库 浏览

    如果你使用 maven, 您可以通过以下方式来配置 pom.xml:

    <project>

    ....
    <properties>
    <version.feilong-platform>1.9.2</version.feilong-platform>
    ....
    </properties>

    ....
    <repositories>
    <repository>
    <id>feilong-repository</id>
    <url>https://raw.github.com/venusdrogon/feilong-platform/repository</url>
    </repository>
    </repositories>

    ....
    <dependencies>
    ....
    <dependency>
    <groupId>com.feilong.platform</groupId>
    <artifactId>feilong-core</artifactId>
    <version>${version.feilong-platform}</version>
    </dependency>
    ....
    </dependencies>
    ....
    </project>

    detail see in 1.9.2 milestone

    特性


    • ConvertUtil add Map<I, J> toMap(Map<K, V> inputMap,final Transformer<K,I> keyTransformer, final Transformer<V, J> valueTransformer) fix #497


    • ConvertUtil add Map<I, J> toMap(Map<K, V> inputMap,final Class<I> keyTargetType,final Class<J> valueTargetType) fix #497


    • add SimpleClassTransformer

    示例:

    if you have a map that is Map<String, String>,want to change to Map<Integer, Integer>

    you can use:

    Map<String, String> map = toMap("1", "2");
    Map<Integer, Integer> returnMap = toMap(map, Integer.class, Integer.class); // 输出测试
    for (Map.Entry<Integer, Integer> entry : returnMap.entrySet()){
    Integer key = entry.getKey();
    Integer value = entry.getValue();
    LOGGER.debug("key:[{}],value:[{}]", key, value);
    }

    output :

    key:[1],value:[2]

    更新


    • FieldUtil T getFieldValue(Object obj,String fieldName) update to private, fix #493,fix #494


    • ClassLoaderUtil update ClassLoaderUtil.getResourceInAllClassLoader(String, Class<?>) log level, fix #476
    移除


    • ConstructorUtil remove T newInstance(String className,Object...parameterValues) fix #486


    • ClassLoaderUtil remove getRootClassPath(ClassLoader classLoader) method fix #477
    Bug 修复


    • List<Field> getAllFieldList(final Class<?> klass,String...excludeFieldNames) if klass is null, expect NPE,but IllegalArgumentException fix #495


    • update JsonUtil Map<String, T> toMap(String json,Class<T> rootClass) error javadoc fix #466


    • JsonUtil.toMap(String, Class<T>, Map<String, Class<?>>) return type change LinkedHashMapinstead of HashMap, fix #464
    下载

    feilong-core 1.9.2,让开发更简便的Java开发工具包下载地址
     
正在加载...