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

namespace OSGeo.GDAL {

using System;
using System.Runtime.InteropServices;

public class RasterIOExtraArg : IDisposable {
  private HandleRef swigCPtr;
  protected bool swigCMemOwn;
  protected object swigParentRef;

  protected static object ThisOwn_true() { return null; }
  protected object ThisOwn_false() { return this; }

  public RasterIOExtraArg(IntPtr cPtr, bool cMemoryOwn, object parent) {
    swigCMemOwn = cMemoryOwn;
    swigParentRef = parent;
    swigCPtr = new HandleRef(this, cPtr);
  }

  public static HandleRef getCPtr(RasterIOExtraArg obj) {
    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
  }
  public static HandleRef getCPtrAndDisown(RasterIOExtraArg obj, object parent) {
    if (obj != null)
    {
      obj.swigCMemOwn = false;
      obj.swigParentRef = parent;
      return obj.swigCPtr;
    }
    else
    {
      return new HandleRef(null, IntPtr.Zero);
    }
  }
  public static HandleRef getCPtrAndSetReference(RasterIOExtraArg obj, object parent) {
    if (obj != null)
    {
      obj.swigParentRef = parent;
      return obj.swigCPtr;
    }
    else
    {
      return new HandleRef(null, IntPtr.Zero);
    }
  }

  ~RasterIOExtraArg() {
    Dispose();
  }

  public virtual void Dispose() {
  lock(this) {
      if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
        swigCMemOwn = false;
        GdalPINVOKE.delete_RasterIOExtraArg(swigCPtr);
      }
      swigCPtr = new HandleRef(null, IntPtr.Zero);
      swigParentRef = null;
      GC.SuppressFinalize(this);
    }
  }

  public int nVersion {
    set {
      GdalPINVOKE.RasterIOExtraArg_nVersion_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      int ret = GdalPINVOKE.RasterIOExtraArg_nVersion_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public RIOResampleAlg eResampleAlg {
    set {
      GdalPINVOKE.RasterIOExtraArg_eResampleAlg_set(swigCPtr, (int)value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      RIOResampleAlg ret = (RIOResampleAlg)GdalPINVOKE.RasterIOExtraArg_eResampleAlg_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public Gdal.GDALProgressFuncDelegate pfnProgress {
    set {
      GdalPINVOKE.RasterIOExtraArg_pfnProgress_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      Gdal.GDALProgressFuncDelegate ret = GdalPINVOKE.RasterIOExtraArg_pfnProgress_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public IntPtr pProgressData {
    set {
      GdalPINVOKE.RasterIOExtraArg_pProgressData_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      IntPtr ret = GdalPINVOKE.RasterIOExtraArg_pProgressData_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public int bFloatingPointWindowValidity {
    set {
      GdalPINVOKE.RasterIOExtraArg_bFloatingPointWindowValidity_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      int ret = GdalPINVOKE.RasterIOExtraArg_bFloatingPointWindowValidity_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public double dfXOff {
    set {
      GdalPINVOKE.RasterIOExtraArg_dfXOff_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      double ret = GdalPINVOKE.RasterIOExtraArg_dfXOff_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public double dfYOff {
    set {
      GdalPINVOKE.RasterIOExtraArg_dfYOff_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      double ret = GdalPINVOKE.RasterIOExtraArg_dfYOff_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public double dfXSize {
    set {
      GdalPINVOKE.RasterIOExtraArg_dfXSize_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      double ret = GdalPINVOKE.RasterIOExtraArg_dfXSize_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public double dfYSize {
    set {
      GdalPINVOKE.RasterIOExtraArg_dfYSize_set(swigCPtr, value);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
    } 
    get {
      double ret = GdalPINVOKE.RasterIOExtraArg_dfYSize_get(swigCPtr);
      if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
      return ret;
    } 
  }

  public RasterIOExtraArg() : this(GdalPINVOKE.new_RasterIOExtraArg(), true, null) {
    if (GdalPINVOKE.SWIGPendingException.Pending) throw GdalPINVOKE.SWIGPendingException.Retrieve();
  }

}

}
