Package hudson.util.jna
Interface GNUCLibrary
- All Superinterfaces:
com.sun.jna.Library
public interface GNUCLibrary
extends com.sun.jna.Library
GNU C library.
Not available on all platforms (such as Linux/PPC, IBM mainframe, etc.), so the caller should recover gracefully
in case of LinkageError
. See JENKINS-4820.
- Author:
- Kohsuke Kawaguchi
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.sun.jna.Library
com.sun.jna.Library.Handler
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final GNUCLibrary
Fields inherited from interface com.sun.jna.Library
OPTION_ALLOW_OBJECTS, OPTION_CALLING_CONVENTION, OPTION_CLASSLOADER, OPTION_FUNCTION_MAPPER, OPTION_INVOCATION_MAPPER, OPTION_OPEN_FLAGS, OPTION_STRING_ENCODING, OPTION_STRUCTURE_ALIGNMENT, OPTION_SYMBOL_PROVIDER, OPTION_TYPE_MAPPER
-
Method Summary
Modifier and TypeMethodDescriptionint
int
int
int
close
(int fd) int
dup
(int old) int
dup2
(int old, int _new) int
int
int
fcntl
(int fd, int command) int
int
fork()
int
int
getegid()
int
geteuid()
int
getpid()
int
getppid()
int
kill
(int pid, int signum) int
void
long
pread
(int fd, com.sun.jna.Memory buffer, com.sun.jna.NativeLong size, com.sun.jna.NativeLong offset) int
Read a symlink.int
int
int
setsid()
strerror
(int errno) int
Creates a symlink.int
sysctl
(int[] mib, int nameLen, com.sun.jna.Pointer oldp, com.sun.jna.ptr.IntByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.ptr.IntByReference newlen) Deprecated.int
sysctl
(int[] name, int namelen, com.sun.jna.Pointer oldp, com.sun.jna.ptr.NativeLongByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.NativeLong newlen) int
sysctlbyname
(String name, com.sun.jna.Pointer oldp, com.sun.jna.ptr.IntByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.ptr.IntByReference newlen) Deprecated.int
sysctlbyname
(String name, com.sun.jna.Pointer oldp, com.sun.jna.ptr.NativeLongByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.NativeLong newlen) int
sysctlnametomib
(String name, com.sun.jna.Pointer mibp, com.sun.jna.ptr.IntByReference size) Deprecated.int
sysctlnametomib
(String name, com.sun.jna.Pointer mibp, com.sun.jna.ptr.NativeLongByReference sizep) int
umask
(int mask) int
-
Field Details
-
F_GETFD
static final int F_GETFD- See Also:
-
F_SETFD
static final int F_SETFD- See Also:
-
FD_CLOEXEC
static final int FD_CLOEXEC- See Also:
-
LIBC
-
-
Method Details
-
fork
int fork() -
kill
int kill(int pid, int signum) -
setsid
int setsid() -
umask
int umask(int mask) -
getpid
int getpid() -
geteuid
int geteuid() -
getegid
int getegid() -
getppid
int getppid() -
chdir
-
getdtablesize
int getdtablesize() -
execv
-
execvp
-
setenv
-
unsetenv
-
perror
-
strerror
-
fcntl
int fcntl(int fd, int command) -
fcntl
-
chown
-
chmod
-
open
- Throws:
com.sun.jna.LastErrorException
-
dup
int dup(int old) -
dup2
int dup2(int old, int _new) -
pread
long pread(int fd, com.sun.jna.Memory buffer, com.sun.jna.NativeLong size, com.sun.jna.NativeLong offset) throws com.sun.jna.LastErrorException - Throws:
com.sun.jna.LastErrorException
-
close
int close(int fd) -
rename
-
sysctlbyname
@Deprecated int sysctlbyname(String name, com.sun.jna.Pointer oldp, com.sun.jna.ptr.IntByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.ptr.IntByReference newlen) Deprecated. -
sysctlbyname
int sysctlbyname(String name, com.sun.jna.Pointer oldp, com.sun.jna.ptr.NativeLongByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.NativeLong newlen) -
sysctl
@Deprecated int sysctl(int[] mib, int nameLen, com.sun.jna.Pointer oldp, com.sun.jna.ptr.IntByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.ptr.IntByReference newlen) Deprecated. -
sysctl
int sysctl(int[] name, int namelen, com.sun.jna.Pointer oldp, com.sun.jna.ptr.NativeLongByReference oldlenp, com.sun.jna.Pointer newp, com.sun.jna.NativeLong newlen) -
sysctlnametomib
@Deprecated int sysctlnametomib(String name, com.sun.jna.Pointer mibp, com.sun.jna.ptr.IntByReference size) Deprecated. -
sysctlnametomib
int sysctlnametomib(String name, com.sun.jna.Pointer mibp, com.sun.jna.ptr.NativeLongByReference sizep) -
symlink
Creates a symlink. See symlink(3) -
readlink
Read a symlink. The name will be copied into the specified memory, and returns the number of bytes copied. The string is not null-terminated.- Returns:
- if the return value equals size, the caller needs to retry with a bigger buffer. If -1, error.
-