From 15e0fd573a87488c66cb3a6f0da01f3ab5f2f6ed Mon Sep 17 00:00:00 2001 From: Richard Jones Date: Fri, 8 May 2009 15:20:36 +0100 Subject: Generated code to support last 3 commits. --- java/com/redhat/et/libguestfs/GuestFS.java | 21 +++++++++++++++++++++ java/com_redhat_et_libguestfs_GuestFS.c | 14 ++++++++++++++ 2 files changed, 35 insertions(+) (limited to 'java') diff --git a/java/com/redhat/et/libguestfs/GuestFS.java b/java/com/redhat/et/libguestfs/GuestFS.java index 0d9ae9df..26f1aaa6 100644 --- a/java/com/redhat/et/libguestfs/GuestFS.java +++ b/java/com/redhat/et/libguestfs/GuestFS.java @@ -534,6 +534,27 @@ public class GuestFS { private native void _set_ready (long g) throws LibGuestFSException; + /** + * leave the busy state + * + * This sets the state to "READY", or if in "CONFIG" then + * it leaves the state as is. This is only used when + * implementing actions using the low-level API. + * + * For more information on states, see guestfs(3). + * + * @throws LibGuestFSException + */ + public void end_busy () + throws LibGuestFSException + { + if (g == 0) + throw new LibGuestFSException ("end_busy: handle is closed"); + _end_busy (g); + } + private native void _end_busy (long g) + throws LibGuestFSException; + /** * mount a guest disk at a position in the filesystem * diff --git a/java/com_redhat_et_libguestfs_GuestFS.c b/java/com_redhat_et_libguestfs_GuestFS.c index 48cd60ff..2ad4c6ab 100644 --- a/java/com_redhat_et_libguestfs_GuestFS.c +++ b/java/com_redhat_et_libguestfs_GuestFS.c @@ -386,6 +386,20 @@ Java_com_redhat_et_libguestfs_GuestFS__1set_1ready } } +JNIEXPORT void JNICALL +Java_com_redhat_et_libguestfs_GuestFS__1end_1busy + (JNIEnv *env, jobject obj, jlong jg) +{ + guestfs_h *g = (guestfs_h *) (long) jg; + int r; + + r = guestfs_end_busy (g); + if (r == -1) { + throw_exception (env, guestfs_last_error (g)); + return ; + } +} + JNIEXPORT void JNICALL Java_com_redhat_et_libguestfs_GuestFS__1mount (JNIEnv *env, jobject obj, jlong jg, jstring jdevice, jstring jmountpoint) -- cgit