/* ----------------------------------------------------------------------------
 * 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.
 * ----------------------------------------------------------------------------- */


public class OBRotationData extends OBGenericData {
  private long swigCPtr;

  protected OBRotationData(long cPtr, boolean cMemoryOwn) {
    super(openbabelJNI.SWIGOBRotationDataUpcast(cPtr), cMemoryOwn);
    swigCPtr = cPtr;
  }

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

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if(swigCPtr != 0 && swigCMemOwn) {
      swigCMemOwn = false;
      openbabelJNI.delete_OBRotationData(swigCPtr);
    }
    swigCPtr = 0;
    super.delete();
  }

  public OBRotationData() {
    this(openbabelJNI.new_OBRotationData(), true);
  }

  public void SetData(OBRotationData.RType RotorType, vectorDouble RotationalConstants, int SymmetryNumber) {
    openbabelJNI.OBRotationData_SetData(swigCPtr, this, RotorType.swigValue(), vectorDouble.getCPtr(RotationalConstants), RotationalConstants, SymmetryNumber);
  }

  public vectorDouble GetRotConsts() {
    return new vectorDouble(openbabelJNI.OBRotationData_GetRotConsts(swigCPtr, this), true);
  }

  public int GetSymmetryNumber() {
    return openbabelJNI.OBRotationData_GetSymmetryNumber(swigCPtr, this);
  }

  public OBRotationData.RType GetRotorType() {
    return OBRotationData.RType.swigToEnum(openbabelJNI.OBRotationData_GetRotorType(swigCPtr, this));
  }

  public final static class RType {
    public final static RType UNKNOWN = new RType("UNKNOWN");
    public final static RType ASYMMETRIC = new RType("ASYMMETRIC");
    public final static RType SYMMETRIC = new RType("SYMMETRIC");
    public final static RType LINEAR = new RType("LINEAR");

    public final int swigValue() {
      return swigValue;
    }

    public String toString() {
      return swigName;
    }

    public static RType swigToEnum(int swigValue) {
      if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
        return swigValues[swigValue];
      for (int i = 0; i < swigValues.length; i++)
        if (swigValues[i].swigValue == swigValue)
          return swigValues[i];
      throw new IllegalArgumentException("No enum " + RType.class + " with value " + swigValue);
    }

    private RType(String swigName) {
      this.swigName = swigName;
      this.swigValue = swigNext++;
    }

    private RType(String swigName, int swigValue) {
      this.swigName = swigName;
      this.swigValue = swigValue;
      swigNext = swigValue+1;
    }

    private RType(String swigName, RType swigEnum) {
      this.swigName = swigName;
      this.swigValue = swigEnum.swigValue;
      swigNext = this.swigValue+1;
    }

    private static RType[] swigValues = { UNKNOWN, ASYMMETRIC, SYMMETRIC, LINEAR };
    private static int swigNext = 0;
    private final int swigValue;
    private final String swigName;
  }

}
