CPKIFResponderID.java

Go to the documentation of this file.
00001 /* ----------------------------------------------------------------------------
00002  * This file was automatically generated by SWIG (http://www.swig.org).
00003  * Version 2.0.1
00004  *
00005  * Do not make changes to this file unless you know what you are doing--modify
00006  * the SWIG interface file instead.
00007  * ----------------------------------------------------------------------------- */
00008 
00009 package com.orionsec.jpkif;
00010 
00011 public class CPKIFResponderID {
00012   private long swigCPtr;
00013   protected boolean swigCMemOwn;
00014 
00015   public CPKIFResponderID(long cPtr, boolean cMemoryOwn) {
00016     swigCMemOwn = cMemoryOwn;
00017     swigCPtr = cPtr;
00018   }
00019 
00020   public static long getCPtr(CPKIFResponderID obj) {
00021     return (obj == null) ? 0 : obj.swigCPtr;
00022   }
00023 
00024   protected void finalize() {
00025     delete();
00026   }
00027 
00028   public synchronized void delete() {
00029     if (swigCPtr != 0) {
00030       if (swigCMemOwn) {
00031         swigCMemOwn = false;
00032         pkif_moduleJNI.delete_CPKIFResponderID(swigCPtr);
00033       }
00034       swigCPtr = 0;
00035     }
00036   }
00037 
00038   public CPKIFResponderID() {
00039     this(pkif_moduleJNI.new_CPKIFResponderID__SWIG_0(), true);
00040   }
00041 
00042   public CPKIFResponderID(CPKIFBufferPtr rid) {
00043     this(pkif_moduleJNI.new_CPKIFResponderID__SWIG_1(CPKIFBufferPtr.getCPtr(rid), rid), true);
00044   }
00045 
00046   public CPKIFResponderID.ResponderIDType GetChoice() {
00047     return CPKIFResponderID.ResponderIDType.swigToEnum(pkif_moduleJNI.CPKIFResponderID_GetChoice(swigCPtr, this));
00048   }
00049 
00050   public CPKIFNamePtr GetName() {
00051     return new CPKIFNamePtr(pkif_moduleJNI.CPKIFResponderID_GetName(swigCPtr, this), true);
00052   }
00053 
00054   public void SetName(CPKIFNamePtr name) {
00055     pkif_moduleJNI.CPKIFResponderID_SetName(swigCPtr, this, CPKIFNamePtr.getCPtr(name), name);
00056   }
00057 
00058   public CPKIFBufferPtr GetHash() {
00059     return new CPKIFBufferPtr(pkif_moduleJNI.CPKIFResponderID_GetHash(swigCPtr, this), true);
00060   }
00061 
00062   public void SetHash(CPKIFBufferPtr hash) {
00063     pkif_moduleJNI.CPKIFResponderID_SetHash(swigCPtr, this, CPKIFBufferPtr.getCPtr(hash), hash);
00064   }
00065 
00066   public final static class ResponderIDType {
00067     public final static ResponderIDType NAME = new ResponderIDType("NAME");
00068     public final static ResponderIDType KEYHASH = new ResponderIDType("KEYHASH");
00069     public final static ResponderIDType UNSET = new ResponderIDType("UNSET");
00070 
00071     public final int swigValue() {
00072       return swigValue;
00073     }
00074 
00075     public String toString() {
00076       return swigName;
00077     }
00078 
00079     public static ResponderIDType swigToEnum(int swigValue) {
00080       if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
00081         return swigValues[swigValue];
00082       for (int i = 0; i < swigValues.length; i++)
00083         if (swigValues[i].swigValue == swigValue)
00084           return swigValues[i];
00085       throw new IllegalArgumentException("No enum " + ResponderIDType.class + " with value " + swigValue);
00086     }
00087 
00088     private ResponderIDType(String swigName) {
00089       this.swigName = swigName;
00090       this.swigValue = swigNext++;
00091     }
00092 
00093     private ResponderIDType(String swigName, int swigValue) {
00094       this.swigName = swigName;
00095       this.swigValue = swigValue;
00096       swigNext = swigValue+1;
00097     }
00098 
00099     private ResponderIDType(String swigName, ResponderIDType swigEnum) {
00100       this.swigName = swigName;
00101       this.swigValue = swigEnum.swigValue;
00102       swigNext = this.swigValue+1;
00103     }
00104 
00105     private static ResponderIDType[] swigValues = { NAME, KEYHASH, UNSET };
00106     private static int swigNext = 0;
00107     private final int swigValue;
00108     private final String swigName;
00109   }
00110 
00111 }

Generated on Mon Nov 15 11:15:49 2010 for PublicKeyInfrastructureFramework(PKIF) by  doxygen 1.5.6