Exploring System

The java.lang.System utility class declares class methods that provide access to the current time (in milliseconds), system property values, environment variable values, and other kinds of system information. Furthermore, it declares class methods that support the system tasks of copying one array to another array, requesting garbage collection, and so on.

Table 7-7 describes some of System’s methods.

Table 7-7. System Methods

Method

Description

void arraycopy(Object src, int srcPos, Object dest, int destPos, int length)

Copies the number of elements specified by length from the src array starting at zero-based offset srcPos into the dest array starting at zero-based offset destPos. This method throws NullPointerException ...

Get Learn Java for Android Development, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.