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

package org.opalvoip;

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

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

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

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if(swigCPtr != 0 && swigCMemOwn) {
      swigCMemOwn = false;
      exampleJNI.delete_OpalStatusRegistration(swigCPtr);
    }
    swigCPtr = 0;
  }

  public void setM_protocol(String value) {
    exampleJNI.OpalStatusRegistration_m_protocol_set(swigCPtr, this, value);
  }

  public String getM_protocol() {
    return exampleJNI.OpalStatusRegistration_m_protocol_get(swigCPtr, this);
  }

  public void setM_serverName(String value) {
    exampleJNI.OpalStatusRegistration_m_serverName_set(swigCPtr, this, value);
  }

  public String getM_serverName() {
    return exampleJNI.OpalStatusRegistration_m_serverName_get(swigCPtr, this);
  }

  public void setM_error(String value) {
    exampleJNI.OpalStatusRegistration_m_error_set(swigCPtr, this, value);
  }

  public String getM_error() {
    return exampleJNI.OpalStatusRegistration_m_error_get(swigCPtr, this);
  }

  public void setM_status(OpalRegistrationStates value) {
    exampleJNI.OpalStatusRegistration_m_status_set(swigCPtr, this, value.swigValue());
  }

  public OpalRegistrationStates getM_status() {
    return OpalRegistrationStates.swigToEnum(exampleJNI.OpalStatusRegistration_m_status_get(swigCPtr, this));
  }

  public void setM_product(OpalProductDescription value) {
    exampleJNI.OpalStatusRegistration_m_product_set(swigCPtr, this, OpalProductDescription.getCPtr(value), value);
  }

  public OpalProductDescription getM_product() {
    long cPtr = exampleJNI.OpalStatusRegistration_m_product_get(swigCPtr, this);
    return (cPtr == 0) ? null : new OpalProductDescription(cPtr, false);
  }

  public OpalStatusRegistration() {
    this(exampleJNI.new_OpalStatusRegistration(), true);
  }

}
