zoukankan      html  css  js  c++  java
  • Usage of API documented as @since 1.8+ less... (Ctrl+F1) Inspection info: This inspection finds all usages of methods that have @since tag in their documentation.

    1.不知道小伙伴们在日常开发过程中使用stream流的时候,有没有遇到这样的情况, 发现stream()方法是红色的 , 这是编译工具提醒的, 估计是出现了什么问题, 如下图所示:

    2.当我们把鼠标移到报红地方的时候 ,编译工具会给我们提示如下信息. 一长串的英文字符, 所以我们看可以先来看看这个提示信息大概是什么意思?

    3.Usage of API documented as @since 1.8+ less... (Ctrl+F1) 

    Inspection info: This inspection finds all usages of methods that have @since tag in their documentation. 

    This may be useful when development is performed under newer SDK version as the target platform for production. 

    这段提示信息大概的意思是:

    api文档从1.8版本开始使用

    检查信息:这次检查发现了所有使用的方法在它的文档中都有标签

    当以较新的SDK版本作为生产的目标平台进行开发时,这可能很有用。

    4.解决方式:如下图操作进入到项目的结构配置当中去

    选择对应的module, 设置source对应的Language level 为报红提示对应的版本, 信息提示的是需要api支持1.8及其以上的版本, 因此,可以设置为8 -Lambdas, type annotations etc. 然后点击应用, 确定.

    5.这时候再使用stream的时候,没有报红了,已经恢复正常了.

  • 相关阅读:
    Mycat适合场景及不适合场景
    solr与Elasticsearch对比
    分布式搜索之搭建Solrcloud(Solr集群)
    Mysql索引最左匹配原则
    CAS实现单点登录SSO执行原理及部署
    Spring Cloud,Dubbo及HSF对比
    Dubbo支持的协议的详解
    Dubbo架构设计详解
    几种分布式锁的实现方式
    深入分析volatile的实现原理
  • 原文地址:https://www.cnblogs.com/lu97/p/14784608.html
Copyright © 2011-2022 走看看