zoukankan      html  css  js  c++  java
  • Java 8 函数式接口

    (1) BiConsumer<T,U>

    代表了一个接受两个输入参数的操作,并且不返回任何结果


    (2)BiFunction<T,U,R>

    代表了一个接受两个输入参数的方法,并且返回一个结果


    (3)BinaryOperator<T>

    代表了一个作用于于两个同类型操作符的操作,并且返回了操作符同类型的结果


    (4)BiPredicate<T,U>

    代表了一个两个参数的boolean值方法


    (5)BooleanSupplier

    代表了boolean值结果的提供方


    (6)Consumer<T>

    代表了接受一个输入参数并且无返回的操作


    (7)DoubleBinaryOperator

    代表了作用于两个double值操作符的操作,并且返回了一个double值的结果。


    (8)DoubleConsumer

    代表一个接受double值参数的操作,并且不返回结果。


    (9)DoubleFunction<R>

    代表接受一个double值参数的方法,并且返回结果


    (10)DoublePredicate

    代表一个拥有double值参数的boolean值方法


    (11)DoubleSupplier

    代表一个double值结构的提供方


    (12)DoubleToIntFunction

    接受一个double类型输入,返回一个int类型结果。


    (13)DoubleToLongFunction

    接受一个double类型输入,返回一个long类型结果


    (14)DoubleUnaryOperator

    接受一个参数同为类型double,返回值类型也为double 。


    (15)Function<T,R>

    接受一个输入参数,返回一个结果。


    (16)IntBinaryOperator

    接受两个参数同为类型int,返回值类型也为int 。


    (17)IntConsumer

    接受一个int类型的输入参数,无返回值 。


    (18)IntFunction<R>

    接受一个int类型输入参数,返回一个结果 。


    (19)IntPredicate

    :接受一个int输入参数,返回一个布尔值的结果。


    (20)IntSupplier

    无参数,返回一个int类型结果。


    (21)IntToDoubleFunction

    接受一个int类型输入,返回一个double类型结果 。


    (22)IntToLongFunction

    接受一个int类型输入,返回一个long类型结果。


    (23)IntUnaryOperator

    接受一个参数同为类型int,返回值类型也为int 。


    (24)LongBinaryOperator

    接受两个参数同为类型long,返回值类型也为long。


    (25)LongConsumer

    接受一个long类型的输入参数,无返回值。


    (26)LongFunction<R>

    接受一个long类型输入参数,返回一个结果。


    (27)LongPredicate

    R接受一个long输入参数,返回一个布尔值类型结果。


    (28)LongSupplier

    无参数,返回一个结果long类型的值。


    (29)LongToDoubleFunction

    接受一个long类型输入,返回一个double类型结果。


    (30)LongToIntFunction

    接受一个long类型输入,返回一个int类型结果。


    (31)LongUnaryOperator

    接受一个参数同为类型long,返回值类型也为long。


    (32)ObjDoubleConsumer<T>

    接受一个object类型和一个double类型的输入参数,无返回值。


    (33)ObjIntConsumer<T>

    接受一个object类型和一个int类型的输入参数,无返回值。


    (34)ObjLongConsumer<T>

    接受一个object类型和一个long类型的输入参数,无返回值。


    (35)Predicate<T>

    接受一个输入参数,返回一个布尔值结果。


    (36)Supplier<T>

    无参数,返回一个结果。


    (37)ToDoubleBiFunction<T,U>

    接受两个输入参数,返回一个double类型结果


    (38)ToDoubleFunction<T>

    接受一个输入参数,返回一个double类型结果


    (39)ToIntBiFunction<T,U>

    接受两个输入参数,返回一个int类型结果。


    (40)ToIntFunction<T>

    接受一个输入参数,返回一个int类型结果。


    (41)ToLongBiFunction<T,U>

    接受两个输入参数,返回一个long类型结果。


    (42)ToLongFunction<T>

    接受一个输入参数,返回一个long类型结果。


    (43)UnaryOperator<T>

    接受一个参数为类型T,返回值类型也为T。





    转载网址:Java 8 函数式接口



    d32d4bd3eda57fa6738ed240ab87bae6283a4f4519dc28ffc75b7d7fcf039640



  • 相关阅读:
    Node.js github开源代码
    Node.js Base64 Encoding和Decoding
    图论500题
    gvim中的gvimrc和vimrc
    ubuntu 命令行卸载并清理软件
    vim复制到系统剪贴板
    Electron 主进程与渲染进程之间的通 信(同步通信、异步通信)
    Android 使用系统录制视频功能
    Electron 自定义软件顶部菜单、右键菜单以及绑定快捷键
    Electron remote 模块、通过 BrowserWindow 打开新窗口
  • 原文地址:https://www.cnblogs.com/betterwgo/p/11527125.html
Copyright © 2011-2022 走看看