/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version: 1.3.19
 *
 * Do not make changes to this file unless you know what you are doing--modify
 * the SWIG interface file instead.
 * ----------------------------------------------------------------------------- */

package com.sleepycat.dbxml;


public class XmlUpdateContext {
  private long swigCPtr;
  protected boolean swigCMemOwn;

  protected XmlUpdateContext(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  protected XmlUpdateContext() {
    this(0, false);
  }

  protected void finalize() {
    delete();
  }

  public void delete() /* no exception */ {
    if(swigCPtr != 0 && swigCMemOwn) {
      dbxml_javaJNI.delete_XmlUpdateContext(swigCPtr);
      swigCMemOwn = false;
    }
    swigCPtr = 0;
  }

  protected static long getCPtr(XmlUpdateContext obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  public XmlUpdateContext(XmlContainer container) throws XmlException {
    this(dbxml_javaJNI.new_XmlUpdateContext(XmlContainer.getCPtr(container)), true);
  }

}
