美文网首页
API(三)~ 其他常用类

API(三)~ 其他常用类

作者: Anwfly | 来源:发表于2020-08-02 11:12 被阅读0次

一、包装类概述

1. 包装类概述

Java语言是一个面向对象的语言,但是Java中的基本数据类型却是不面向对象的,这在实际使用时存在很多的不便,为了解决这个不足,在设计类时为每个基本数据类型设计了一个对应的类进行代表,这样八个和基本数据类型对应的类统称为包装类(Wrapper Class),有些地方也翻译为外覆类或数据类型类。

基本数据类型 包装类型
byte Byte
short Short
int Integer
long Long
float Float
double Double
char Character
boolean Boolean

在这八个类名中,除了Integer和Character类以后,其它六个类的类名和基本数据类型一直,只是类名的第一个字母大写即可。

对于包装类说,这些类的用途主要包含两种:

    1. 作为和基本数据类型对应的类类型存在,方便涉及到对象的操作。
    1. 包含每种基本数据类型的相关属性如最大值、最小值等,以及相关的操作方法。

二、包装类Integer

实际上Integer对象就是一个整形数据,不过在这里我们把它封装成了一个对象,并提供了对这个对象的一些操作方法。

1. Integer构造方法

// 传入int类型创建Integer类型
public Integer(int value)
// 传入String类型创建Integer类型
public Integer(String s) 

案例:

public static void main(String[] args) {
    // 方式1
    int i = 100;
    Integer ii = new Integer(i);
    System.out.printl n("ii:" + ii);
    // 方式2  
    String s = "100";       //这个字符串必须是由数字字符组成
    // NumberFormatException
    // String s = "abc";
    Integer iii = new Integer(s);
    System.out.println("iii:" + iii);
}     

2. Integer成员方法

以下常用的连个方法在后面字符串与整形数据转化中有示例代码

 //以 int 类型返回该 Integer 的值
public int intValue()

//将字符串参数作为有符号的十进制整数进行解析
public static int parseInt(String s)

//返回一个表示该 Integer 值的 String 对象
public static String toString(int i)

//返回一个表示指定的 int 值的 Integer 实例
public static Integer valueOf(int i)

//返回保存指定的 String 的值的 Integer 对象
public static Integer valueOf(String s)

//返回一个表示指定整数的 String 对象 
static String toString(int i)
// 以二进制(基数 2)无符号整数形式返回一个整数参数的字符串表示形式。  
static String toBinaryString(int i)

//以十六进制(基数 16)无符号整数形式返回一个整数参数的字符串表示形式。 
static String toHexString(int i)

// 以八进制(基数 8)无符号整数形式返回一个整数参数的字符串表示形式。 
static String toOctalString(int i)

三、String和int类型相互转换

1. String--int 几种方式

public static void main(String[] args) {
    // int -- String
    int number = 100;
    // 方式1
    String s1 = "" + number;
    System.out.println("s1:" + s1);
    // 方式2
    String s2 = String.valueOf(number);
    System.out.println("s2:" + s2);
    // 方式3
    // int -- Integer -- String
    Integer i = new Integer(number);
    String s3 = i.toString();
    System.out.println("s3:" + s3);
    // 方式4
    // public static String toString(int i)
    String s4 = Integer.toString(number);
    System.out.println("s4:" + s4); 
}       

2. int ---String 几种方式

public static void main(String[] args) {
        // String -- int
        String s = "100";
        // 方式1
        // String -- Integer -- int
        Integer ii = new Integer(s);
        // public int intValue()
        int x = ii.intValue();
        System.out.println("x:" + x);
        //方式2
        //public static int parseInt(String s)
        int y = Integer.parseInt(s);
        System.out.println("y:"+y);
}                     

四、 JDK5新特性-自动装箱、自动拆箱

1. JDK5新特性-自动装箱、自动拆箱

JDK5的新特性
自动装箱:把基本类型转换为包装类类型
自动拆箱:把包装类类型转换为基本类型
注意:
在使用时,Integer x = null;代码就会出现NullPointerException。建议先判断是否为null,然后再使用。

 public static void main(String[] args) {
        // 定义了一个int类型的包装类类型变量i
        // Integer i = new Integer(100);
        Integer ii = 100;
        ii += 200;
        System.out.println("ii:" + ii);
        // 通过反编译后的代码
        // Integer ii = Integer.valueOf(100); //自动装箱
        // ii = Integer.valueOf(ii.intValue() + 200); //自动拆箱,再自动装箱
        // System.out.println((new StringBuilder("ii:")).append(ii).toString());
        Integer iii = null;
        // NullPointerException
        if (iii != null) {
            iii += 1000;
            System.out.println(iii);
        }
}                                            

面试题:
Integer的数据直接赋值,如果在-128到127之间,会直接从缓冲池里获取数据
看程序写结果,并分析原因:

public static void main(String[] args) {
        Integer i1 = new Integer(127);
        Integer i2 = new Integer(127);
        System.out.println(i1 == i2);
        System.out.println(i1.equals(i2));
        System.out.println("-----------");
        Integer i3 = new Integer(128);
        Integer i4 = new Integer(128);
        System.out.println(i3 == i4);
        System.out.println(i3.equals(i4));
        System.out.println("-----------");
        Integer i5 = 128;
        Integer i6 = 128;
        System.out.println(i5 == i6);
        System.out.println(i5.equals(i6));
        System.out.println("-----------");
        Integer i7 = 127;
        Integer i8 = 127;
        System.out.println(i7 == i8);
        System.out.println(i7.equals(i8));
        // 通过查看源码,我们就知道了,针对-128到127之间的数据,做了一个数据缓冲池,如果数据是该范围内的,每次并不创建新的空间
        // Integer ii = Integer.valueOf(127);
    }

五、包装类Character概述

Character 类在对象中包装一个基本类型 char 的值,此外,该类提供了几种方法,以确定字符的类别(小写字母,数字,等等),并将字符从大写转换成小写,反之亦然 。

1.Character构造方法

//有参构造方法(字符)
Character(char value)   
        
public static void main(String[] args) {
    // 创建对象
    // Character ch = new Character((char) 97);
    Character ch = new Character('a');
    System.out.println("ch:" + ch);
}           

2. Character成员方法

//判断给定的字符是否是大写字符
public static boolean isUpperCase(char ch)
//判断给定的字符是否是小写字符
public static boolean isLowerCase(char ch)
//判断给定的字符是否是数字字符
public static boolean isDigit(char ch)
//把给定的字符转换为大写字符
public static char toUpperCase(char ch)
//把给定的字符转换为小写字符
public static char toLowerCase(char ch)

3. 案例-大小写转换

public static void main(String[] args) {
        // public static boolean isUpperCase(char ch):判断给定的字符是否是大写字符
        System.out.println("isUpperCase:" + Character.isUpperCase('A'));
        System.out.println("isUpperCase:" + Character.isUpperCase('a'));
        System.out.println("isUpperCase:" + Character.isUpperCase('0'));
        System.out.println("-----------------------------------------");
        // public static boolean isLowerCase(char ch):判断给定的字符是否是小写字符
        System.out.println("isLowerCase:" + Character.isLowerCase('A'));
        System.out.println("isLowerCase:" + Character.isLowerCase('a'));
        System.out.println("isLowerCase:" + Character.isLowerCase('0'));
        System.out.println("-----------------------------------------");
        // public static boolean isDigit(char ch):判断给定的字符是否是数字字符
        System.out.println("isDigit:" + Character.isDigit('A'));
        System.out.println("isDigit:" + Character.isDigit('a'));
        System.out.println("isDigit:" + Character.isDigit('0'));
        System.out.println("-----------------------------------------");
        // public static char toUpperCase(char ch):把给定的字符转换为大写字符
        System.out.println("toUpperCase:" + Character.toUpperCase('A'));
        System.out.println("toUpperCase:" + Character.toUpperCase('a'));
        System.out.println("-----------------------------------------");
        // public static char toLowerCase(char ch):把给定的字符转换为小写字符
        System.out.println("toLowerCase:" + Character.toLowerCase('A'));
        System.out.println("toLowerCase:" + Character.toLowerCase('a'));
    }

4. 案例-统计大小写数字个数

统计一个字符串中大写字母字符,小写字母字符,数字字符出现的次数。(不考虑其他字符)
分析:

        A:定义三个统计变量。
            int bigCont=0;
            int smalCount=0;
            int numberCount=0;
        B:键盘录入一个字符串。
        C:把字符串转换为字符数组。
        D:遍历字符数组获取到每一个字符
        E:判断该字符是
            大写  bigCount++;
            小写  smalCount++;
            数字  numberCount++;
        F:输出结果即可
public static void main(String[] args) {
        // 定义三个统计变量。
        int bigCount = 0;
        int smallCount = 0;
        int numberCount = 0;

        // 键盘录入一个字符串。
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入一个字符串:");
        String line = sc.nextLine();

        // 把字符串转换为字符数组。
        char[] chs = line.toCharArray();

        // 历字符数组获取到每一个字符
        for (int x = 0; x < chs.length; x++) {
            char ch = chs[x];

            // 判断该字符
            if (Character.isUpperCase(ch)) {
                bigCount++;
            } else if (Character.isLowerCase(ch)) {
                smallCount++;
            } else if (Character.isDigit(ch)) {
                numberCount++;
            }
        }

        // 输出结果即可
        System.out.println("大写字母:" + bigCount + "个");
        System.out.println("小写字母:" + smallCount + "个");
        System.out.println("数字字符:" + numberCount + "个");
    }

六、 Arrays工具类的使用**

1.Arrays排序方法

Arrays:针对数组进行操作的工具类。比如说排序和查找。

    // 把数组转成字符串 (int类型数组)
    public static String toString(int[] a)
    // 对数组进行排序(int类型数组)
    public static void sort(int[] a)
    //二分查找(int类型数组,关键字)
    public static int binarySearch(int[] a,int key) 

2.Arrays转换String方法

public static void main(String[] args) {
        // 定义一个数组
    int[] arr = { 24, 69, 80, 57, 13 };

    // public static String toString(int[] a) 把数组转成字符串
    System.out.println("排序前:" + Arrays.toString(arr));
    
    // public static void sort(int[] a) 对数组进行排序
    Arrays.sort(arr);
    System.out.println("排序后:" + Arrays.toString(arr));
    
    // [13, 24, 57, 69, 80]
    // public static int binarySearch(int[] a,int key) 二分查找
    System.out.println("binarySearch:" + Arrays.binarySearch(arr, 57));
    System.out.println("binarySearch:" + Arrays.binarySearch(arr, 577));
}

七、Math类概述

Math 类包含用于执行基本数学运算的方法,如初等指数、对数、平方根和三角函数。
构造方法使用private修饰,不能创建对象,但是所提供的所有方法均使用static修饰,可以直接使用类名.方法名调用,提供两个字段,使用final修饰。

1.Math类中字段说明

//比任何其他值都更接近 e(即自然对数的底数)的 double 值。 
public static final double E
//比任何其他值都更接近 pi(即圆的周长与直径之比)的 double 值。
public static final double PI    

2. Math类中常用方法介绍

    //绝对值
    public static int abs(int a)

    //最大值 (min自学)
    public static int max(int a, int b)

    //四舍五入(参数为double的自学)
    public static int round(float a)

    //a的b次幂
    public static double pow(double a, double b)

    //随机数 [0.0,1.0)
    public static double random()

    //向上取整
    public static double ceil(double a)

    //向下取整
    public static double floor(double a)

    //正平方根
    public static double sqrt(double a)

代码演示

public static void main(String[] args) {
    System.out.println("E:"+Math.E);//E:2.718281828459045
    System.out.println("PI:"+Math.PI);//PI:3.141592653589793
    int abs = Math.abs(-56);        //abs=56 正好是-56的绝对值
    int max = Math.max(10, 20); //max=20, 这个方法返回的是两个值之间最大的那个
    long round = Math.round(2.5);//round=3,四舍五入,2.5≈3
    long round1 = Math.round(2.2);//round1=2,四舍五入,2.4≈2
    double pow = Math.pow(3, 4);//pow=81, 3的4次幂 3X3X3X3=81
    double ceil = Math.ceil(2.1);//ceil=3,ceil天花板,就是比你输入的数大的最小整数
    double floor = Math.floor(2.1);//floor=2,floor地板,就是比你输入的整数小的最大整数
    double sqrt = Math.sqrt(9);//sqrt=3.0 9的平方根正好是3 
    double random = Math.random();//得到一个0-1之间的浮点类型的数,可以是0,但不会有1.
}

请同学们自行添加输出方法,打印以上结果,查看结果是否与注释结果相同。

思考题:
1.如何判断三个数中最大的数,请用Math类中的max()方法实现
2.如何得到一个10-20之间的随机数,怎么利用random()方法获取

3. 随机数案例

案例一:获取区间随机数

int min=5;// 最小值
int max=10;//最大值
    
int num = min + (int)(Math.random() * (max-min+1));//获取区间随机数
System.out.println(num);//打印结果

案例二:获取随机整数

public static void main(String[] args) {      
    int num=(int)(Math.random()*10);//生成[0,9]之间的随机整数。
    System.out.println(num);//打印结果
}

八、Random类概述

此类的实例用于生成伪随机数流。为什么说是伪随机数流呢?因为如果用相同的种子创建两个 Random 实例,则对每个实例进行相同的方法调用序列,它们将生成并返回相同的数字序列。这个类产生的随机数是根据你给他的种子数据根据特定算法计算出来的随机数,如果创建了两个这个类的对象,而给定的种子数是相同的,则产生相同的随机数。

Random类的构造方法介绍

    // 使用单个 long 种子创建一个新的随机数生成器.seed即为我们给定的种子,随机数就是根据这个种子使用特定算法计算出来一个随机数。
    Random(long seed) 

    //创建一个新的随机数生成器。没有给种子,用的是默认种子,是当前时间的毫秒值 
    Random() 

1.Random成员方法

//返回下一个伪随机数,它是取自此随机数生成器序列的均匀分布的 boolean 值。
boolean nextBoolean ()

//返回下一个伪随机数,它是取自此随机数生成器序列的、在 0.0 和 1.0 之间均匀分布的 double 值。
double nextDouble ()

//返回下一个伪随机数,它是取自此随机数生成器序列的、在 0.0 和 1.0 之间均匀分布的 float 值。
float nextFloat ()

//返回下一个伪随机数,它是此随机数生成器的序列中均匀分布的 int 值。
int nextInt ()

//返回一个伪随机数,它是取自此随机数生成器序列的、在 0(包括)和指定值(不包括)之间均匀分布的 int 值。
int nextInt ( int n)

//返回下一个伪随机数,它是取自此随机数生成器序列的均匀分布的 long 值。
long nextLong ()

//使用单个 long 种子设置此随机数生成器的种子。
void setSeed ( long seed)

Random类代码演示

1.两个随机数生成器多次生成随机数比较

public static void main(String[] args) {
    //创建两个随机数对象
    Random random1 = new Random(100);
    Random random2 = new Random(100);
    for (int i = 0; i < 5; i++) {
        System.out.println("random1:"+i+" :"+random1.nextInt());
        System.out.println("random2:"+i+" :"+random2.nextInt());
    }
}

运行结果:

random1:0 :-1193959466
random2:0 :-1193959466
random1:1 :-1139614796
random2:1 :-1139614796
random1:2 :837415749
random2:2 :837415749
random1:3 :-1220615319
random2:3 :-1220615319
random1:4 :-1429538713
random2:4 :-1429538713

因为两个随机数生成器使用了同一个种子,按照同样的计算方式计算的随机数就是相同的,所以叫做伪随机数。同学们自行把种子修改实验查看结果是否相同。

2. 两个随机数生成器多次生成随机数比较

public static void main(String[] args) {
    Random random1 = new Random();
    Random random2 = new Random();
    for (int i = 0; i < 5; i++) {
        System.out.println("random1:"+i+" :"+random1.nextInt());
        System.out.println("random2:"+i+" :"+random2.nextInt());
    }
}

运行结果为:

random1:0 :-1541184818
random2:0 :-1541492704
random1:1 :585806671
random2:1 :2056165446
random1:2 :-285449137
random2:2 :-1677767374
random1:3 :-804836475
random2:3 :1244502336
random1:4 :-263685769
random2:4 :1863823215

因为两个随机数生成器创建时间不一样,种子自然不同,所以产生的随机数自然不同。
Random类中常用方法演示

public static void main(String[] args) {
        Random random = new Random(100);
        for (int i = 0; i < 5; i++) {
            boolean nextBoolean = random.nextBoolean();
            System.out.println("nextBoolean:"+nextBoolean);
        }
        for (int i = 0; i < 5; i++) {
            double nextDouble = random.nextDouble();
            System.out.println("nextDouble:"+nextDouble);
        }
        for (int i = 0; i < 5; i++) {
            int nextInt = random.nextInt();
            System.out.println("nextInt"+nextInt);
        }
        for (int i = 0; i < 5; i++) {
            int nextInt = random.nextInt(10);
            System.out.println("nextInt(10)"+nextInt);
        }
}

2.案例-双色球

ssq.png

分析:

1.从33位红色球中取出一位数
2.判断是否重复取出相同红色,如重复,再次重新获取。
3.红色球只取出6个
4.从16个蓝色球取出1个
5.打印出来

/**
 * 红33 蓝16  取红6 蓝1
 * 双色球获得6个红球时不能重复
 */
public class ShuanSeQiu {
    public void demo(){
        //定义随机生成双色球数组
        int[] arr=new int[7];
        arr=this.getRedBall(arr);
        System.out.println(Arrays.toString(arr));
    }
    //获得红球
    public int[] getRedBall(int[] arr){
        Random random = new Random();
        for(int i=0;i<=6;i++){//获的6个红球
           int num= random.nextInt(33-1+1)+1;
            boolean flag = this.val(num, arr);//是否已存在
            if(!flag){
                arr[i]=num;
            }else{
                i--;//控制下标
            }
        }
        //获得篮球
        arr[5]=random.nextInt(16-1+1)+1;
        return arr;
    }
    //判断是否数组中存在当前双色球
    public boolean val(int redBall,int[] arr){
        for (int i = 0; i <arr.length ; i++) {//遍历数组
            if(redBall==arr[i]){//存在
                return true;
            }
        }
        return false;
    }

    public static void main(String[] args) {
        new ShuanSeQiu().demo();
    }
}

九、System类概述

System 类包含一些有用的类字段和方法。它不能被实例化。 在 System 类提供的设施中,有标准输入、标准输出和错误输出流;对外部定义的属性和环境变量的访问;加载文件和库的方法;还有快速复制数组的一部分的实用方法。

System类中的字段

System类内部包含in、out和err三个成员变量,分别代表标准输入流(键盘输入),标准输出流(显示器)和标准错误输出流(显示器)。

例如:
输出信息:

System.out.println(“Test”);

键盘录入:

Scanner scanner = new Scanner(System.in);
String nextLine = scanner.nextLine();

其中的System.in 其中的变量in关联到了我们的键盘上,所以我们在键盘上敲的字符可以被我们的成粗所捕获。当然我们也可以更改我们的in到一个文本文件当中,然后就是读取一个本地电脑的文件。

1.System类成员方法

System类中提供了一些系统级的操作方法,这些方法实现的功能分别如下:

    //复制数组对象
    public static void arraycopy(Object src, int srcPos, Object dest, int destPos, int length)
    //获取当前时间
    public static long currentTimeMillis()
    //退出
    public static void exit(int status)
    //回收对象
    public static void gc()
    //获取当前属性名称
    public static String getProperty(String key)

该方法的作用是获得系统中属性名为key的属性对应的值。系统中常见的属性名以及属性的作用如下表所示。

属性名 属性说明
java.version Java 运行时环境版本
java.home Java 安装目录
os.name 操作系统的名称
os.version 操作系统的版本
user.name 用户的账户名称
user.home 用户的主目录
user.dir 用户的当前工作目录

例如:

    String osName = System.getProperty(“os.name”);
    String user = System.getProperty(“user.name”);
    System.out.println(“当前操作系统是:” + osName);
    System.out.println(“当前用户是:” + user);

使用该方法可以获得很多系统级的参数以及对应的值,学生请自己运行结果,查看效果。

十、Date概述

1. 构造方法

    //这个无参构造方法可以获取系统本地时间。格式为:Tue Aug 22 09:30:53 CST 2017   这个时间是在我电脑上运行时的运行结果
    public Date()   

    //这个date指自从1970年1月1日开始,以毫秒值计算的一个时间值。
    public Date(long date)

2. 成员方法

    //这个方法获取到的就是自从1970年1月1日0时开始计算的你电脑系统的时间的毫秒值。
    public long getTime()

    //这个方法是用来设定时间的毫秒值,比如我们使用了无参构造方法,但是想得到某一值的具体日期,则可以使用这个方法设定。
    public void setTime(long time)

十一、 DateFromat类

1. SimpleDateFormat类概述

使用以上Date类时,输出日期格式跟我们平时所熟悉的日期格式2017年08月08日 。DateFormat 是日期/时间格式化子类的抽象类,它以与语言无关的方式格式化并解析日期或时间。

SimpleDateFormat类以及类构造方法

SimpleDateFormat 是一个以与语言环境有关的方式来格式化和解析日期的具体类。它允许进行格式化(日期 -> 文本)、解析(文本 -> 日期)和规范化。

2. SimpleDateFormat格式使用-日期格式化

SimpleDateFormat类的构造方法:

//先用SimpleDateFormat创建一个对象,参数为你要求的时间格式,pattern是由普通字符和一些称作格式符组成的字符序列组成的。
public SimpleDateFormat(String pattern);

SimpleDateFormat类中常用的方法:

// 将一个 Date 格式化为日期/时间字符串
String format(Date date)。 
//解析字符串的文本,生成 Date。 
Date parse(String text, ParsePosition pos) 

日期格式化format方法的使用:

public static void main(String[] args) {
    Date date = new Date();
    String pattern = "y年M月d日H时m分s秒";
    SimpleDateFormat sdf = new SimpleDateFormat(pattern);
    String format = simpleDateFormat.format(date);
    System.out.println(format);
}

3.SimpleDateFormat格式使用-字符串格式化日期

日期解析parse方法使用:比如给了我们一个字符串“2017年8月22日9时57分25秒”,我们想把这个时间的字符串转为一个Date中的long数字,则用到了第二个方法

public static void main(String[] args) throws Exception {
    String pattern = "y年M月d日H时m分s秒";
    SimpleDateFormat sdf = new SimpleDateFormat(pattern);
    String string = "2017年8月22日9时57分25秒";
    Date date = sdf.parse(string);
    System.out.println(date);
}

Pattern模式:
日期和时间格式由日期和时间模式 字符串指定。在日期和时间模式
y:替换为2位数字的年,例如:98;
M:替换为年中的月份,例如:July、July、7;
d:替换为月份中的天数,例如:26;
H:替换为一天中的小时数(0~23),例如0;
m:替换为小时中的分钟数,例如:39;
s:替换为分钟数的秒数,例如49;
z:替换为时区,例如CST。

十二、Calendar类

1. Calendar类

Calendar 类是一个抽象类,它为特定瞬间与一组诸如 YEAR、MONTH、DAY_OF_MONTH、HOUR 等 日历字段之间的转换提供了一些方法,并为操作日历字段(例如获得下星期的日期)提供了一些方法。Calendar类是一个抽象类,在实际使用时实现特定的子类的对象,创建对象的过程对程序员来说是透明的,只需要使用getInstance方法创建即可。

2. Calendar类使用-获取当前日期

 public static void main(String[] args) {
      Calendar cal=Calendar.getInstance();//使用日历类
      int year=cal.get(Calendar.YEAR);//得到年
      int month=cal.get(Calendar.MONTH)+1;//得到月,因为从0开始的,所以要加1
      int day=cal.get(Calendar.DAY_OF_MONTH);//得到天
      int hour=cal.get(Calendar.HOUR);//得到小时
      int minute=cal.get(Calendar.MINUTE);//得到分钟
      int second=cal.get(Calendar.SECOND);//得到秒
      System.out.println("结果:"+year+"-"+month+"-"+day+" "+hour+":"+minute+":"+second);
 }

相关文章

  • API(三)~ 其他常用类

    一、包装类概述 1. 包装类概述 Java语言是一个面向对象的语言,但是Java中的基本数据类型却是不面向对象的,...

  • javaAPI(二)

    XML文件 读取XML常用API汇总(通过SAXReader类读取) 从java中写入XML常用API File类...

  • runtime02-常用API

    runtime常用API runtime API01-类相关 runtime API01-类相关-事例01 run...

  • 其他常用类

    Math类 (1)abs( )、max( )和min( )方法 常见的abs()方法、max()方法和min()方...

  • java字节流分析

    InputStream 常用类继承框架 OutputStream 常用类继承框架 想活用输入 / 输出 API ,...

  • Runtime:项目应用

    动态创建类 对应的常用API 动态添加类举例 实例变量 对应的常用API 例子: 实战:修改textField的p...

  • Java基础进阶Object类、常用API

    【Object类、常用API】 主要内容 Object类 Date类 DateFormat类 Calendar类 ...

  • 【Object类、常用API】

    【Object类、常用API】 主要内容 Object类 Date类 DateFormat类 Calendar类 ...

  • kafka-python操作

    kafka-python文档 一、consumer 1. 常用api 二、producer 三、其他 3.1 js...

  • UnitTest单元测试

    unitTestBase类,其他test类集成Base类 api接口测试

网友评论

      本文标题:API(三)~ 其他常用类

      本文链接:https://www.haomeiwen.com/subject/ccqqrktx.html