Interface PosixCLibrary

All Superinterfaces:
NativeLibrary

public non-sealed interface PosixCLibrary extends NativeLibrary
Provides access to methods in libc.so available on POSIX systems.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    corresponds to struct rlimit
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Return the error number from the last failed C library call.
    int
    Gets the effective userid of the current process.
    int
    getrlimit(int resource, PosixCLibrary.RLimit rlimit)
    Retrieve the current rlimit values for the given resource.
    int
    mlockall(int flags)
    Lock all the current process's virtual address space into RAM.
    Create a new RLimit struct for use by getrlimit.
    strerror(int errno)
    Return a string description for an error.
  • Method Details

    • geteuid

      int geteuid()
      Gets the effective userid of the current process.
      Returns:
      the effective user id
      See Also:
    • newRLimit

      Create a new RLimit struct for use by getrlimit.
    • getrlimit

      int getrlimit(int resource, PosixCLibrary.RLimit rlimit)
      Retrieve the current rlimit values for the given resource.
      Returns:
      0 on success, -1 on failure with errno set
      See Also:
    • mlockall

      int mlockall(int flags)
      Lock all the current process's virtual address space into RAM.
      Parameters:
      flags - flags determining how memory will be locked
      Returns:
      0 on success, -1 on failure with errno set
      See Also:
    • strerror

      String strerror(int errno)
      Return a string description for an error.
      Parameters:
      errno - The error number
      Returns:
      a String description for the error
      See Also:
    • errno

      int errno()
      Return the error number from the last failed C library call.
      See Also: