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

package org.chasen.mecab;

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

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

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

  public void delete() {
    if(swigCPtr != 0 && swigCMemOwn) {
      swigCMemOwn = false;
      throw new UnsupportedOperationException("C++ destructor does not have public access");
    }
    swigCPtr = 0;
  }

  public Node getPrev() {
    long cPtr = MeCabJNI.Node_prev_get(swigCPtr);
    return (cPtr == 0) ? null : new Node(cPtr, false);
  }

  public Node getNext() {
    long cPtr = MeCabJNI.Node_next_get(swigCPtr);
    return (cPtr == 0) ? null : new Node(cPtr, false);
  }

  public Node getEnext() {
    long cPtr = MeCabJNI.Node_enext_get(swigCPtr);
    return (cPtr == 0) ? null : new Node(cPtr, false);
  }

  public Node getBnext() {
    long cPtr = MeCabJNI.Node_bnext_get(swigCPtr);
    return (cPtr == 0) ? null : new Node(cPtr, false);
  }

  public Path getRpath() {
    long cPtr = MeCabJNI.Node_rpath_get(swigCPtr);
    return (cPtr == 0) ? null : new Path(cPtr, false);
  }

  public Path getLpath() {
    long cPtr = MeCabJNI.Node_lpath_get(swigCPtr);
    return (cPtr == 0) ? null : new Path(cPtr, false);
  }

  public String getFeature() {
    return MeCabJNI.Node_feature_get(swigCPtr);
  }

  public long getId() {
    return MeCabJNI.Node_id_get(swigCPtr);
  }

  public int getLength() {
    return MeCabJNI.Node_length_get(swigCPtr);
  }

  public int getRlength() {
    return MeCabJNI.Node_rlength_get(swigCPtr);
  }

  public int getRcAttr() {
    return MeCabJNI.Node_rcAttr_get(swigCPtr);
  }

  public int getLcAttr() {
    return MeCabJNI.Node_lcAttr_get(swigCPtr);
  }

  public int getPosid() {
    return MeCabJNI.Node_posid_get(swigCPtr);
  }

  public short getChar_type() {
    return MeCabJNI.Node_char_type_get(swigCPtr);
  }

  public short getStat() {
    return MeCabJNI.Node_stat_get(swigCPtr);
  }

  public short getIsbest() {
    return MeCabJNI.Node_isbest_get(swigCPtr);
  }

  public float getAlpha() {
    return MeCabJNI.Node_alpha_get(swigCPtr);
  }

  public float getBeta() {
    return MeCabJNI.Node_beta_get(swigCPtr);
  }

  public void setProb(float value) {
    MeCabJNI.Node_prob_set(swigCPtr, value);
  }

  public float getProb() {
    return MeCabJNI.Node_prob_get(swigCPtr);
  }

  public short getWcost() {
    return MeCabJNI.Node_wcost_get(swigCPtr);
  }

  public int getCost() {
    return MeCabJNI.Node_cost_get(swigCPtr);
  }

  public String getSurface() {
    return MeCabJNI.Node_surface_get(swigCPtr);
  }

}
