All Downloads are FREE. Search and download functionalities are using the official Maven repository.

android.system.Os Maven / Gradle / Ivy

Go to download

provide android hidden api definition ,helper for android super framework development

There is a newer version: 1.11
Show newest version
/*
 * Copyright (C) 2011 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package android.system;


import android.util.MutableInt;
import androidx.annotation.RequiresApi;
import libcore.util.NonNull;

import java.io.FileDescriptor;


/**
 * Access to low-level system functionality. Most of these are system calls. Most users will want
 * to use higher-level APIs where available, but this class provides access to the underlying
 * primitives used to implement the higher-level APIs.
 *
 * 

The corresponding constants can be found in {@link OsConstants}. */ public final class Os { private Os() { } public static int ioctlInt(FileDescriptor fd, int cmd, MutableInt arg) throws ErrnoException { throw new ErrnoException(); } /** * @hide */ //@libcore.api.CorePlatformApi @RequiresApi(27) public static int ioctlInt(FileDescriptor fd, int cmd, Int32Ref arg) throws ErrnoException { throw new IllegalStateException("STUB"); } /** * See ioctl(3). * System call manipulates the underlying device parameters of special files. In particular, * many operating characteristics of character special files. * * @param fd an open file descriptor * @param cmd encoded in it whether the argument is an "in" parameter or "out" parameter * @return returns a nonnegative value on success * @throws ErrnoException A checked exception thrown when {@link Os} methods fail. * {@see android.system.ErrnoException} * @hide */ // @SystemApi(client = MODULE_LIBRARIES) // @libcore.api.CorePlatformApi(status = libcore.api.CorePlatformApi.Status.STABLE) @RequiresApi(31) public static int ioctlInt(@NonNull FileDescriptor fd, int cmd) throws ErrnoException { throw new IllegalStateException("STUB"); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy