1 /* ----------------------------------------------------------------------------
2  * This file was automatically generated by SWIG (http://www.swig.org).
3  * Version 3.0.13
4  *
5  * Do not make changes to this file unless you know what you are doing--modify
6  * the SWIG interface file instead.
7  * ----------------------------------------------------------------------------- */
8 
9 package org.xapian;
10 
11 public class PL2Weight extends Weight {
12   private transient long swigCPtr;
13 
PL2Weight(long cPtr, boolean cMemoryOwn)14   protected PL2Weight(long cPtr, boolean cMemoryOwn) {
15     super(XapianJNI.PL2Weight_SWIGUpcast(cPtr), cMemoryOwn);
16     swigCPtr = cPtr;
17   }
18 
getCPtr(PL2Weight obj)19   protected static long getCPtr(PL2Weight obj) {
20     return (obj == null) ? 0 : obj.swigCPtr;
21   }
22 
finalize()23   protected void finalize() {
24     delete();
25   }
26 
delete()27   public synchronized void delete() {
28     if (swigCPtr != 0) {
29       if (swigCMemOwn) {
30         swigCMemOwn = false;
31         XapianJNI.delete_PL2Weight(swigCPtr);
32       }
33       swigCPtr = 0;
34     }
35     super.delete();
36   }
37 
PL2Weight(double c)38   public PL2Weight(double c) {
39     this(XapianJNI.new_PL2Weight__SWIG_0(c), true);
40   }
41 
PL2Weight()42   public PL2Weight() {
43     this(XapianJNI.new_PL2Weight__SWIG_1(), true);
44   }
45 
name()46   public String name() {
47     return XapianJNI.PL2Weight_name(swigCPtr, this);
48   }
49 
getSumPart(long wdf, long doclen, long uniqterms)50   public double getSumPart(long wdf, long doclen, long uniqterms) {
51     return XapianJNI.PL2Weight_getSumPart(swigCPtr, this, wdf, doclen, uniqterms);
52   }
53 
getMaxPart()54   public double getMaxPart() {
55     return XapianJNI.PL2Weight_getMaxPart(swigCPtr, this);
56   }
57 
getSumExtra(long doclen, long uniqterms)58   public double getSumExtra(long doclen, long uniqterms) {
59     return XapianJNI.PL2Weight_getSumExtra(swigCPtr, this, doclen, uniqterms);
60   }
61 
getMaxExtra()62   public double getMaxExtra() {
63     return XapianJNI.PL2Weight_getMaxExtra(swigCPtr, this);
64   }
65 
66 }
67