KeyUsage.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 final class KeyUsage {
00012   public final static KeyUsage DigitalSignature = new KeyUsage("DigitalSignature", pkif_moduleJNI.DigitalSignature_get());
00013   public final static KeyUsage NonRepudiation = new KeyUsage("NonRepudiation", pkif_moduleJNI.NonRepudiation_get());
00014   public final static KeyUsage KeyEncipherment = new KeyUsage("KeyEncipherment", pkif_moduleJNI.KeyEncipherment_get());
00015   public final static KeyUsage DataEncipherment = new KeyUsage("DataEncipherment", pkif_moduleJNI.DataEncipherment_get());
00016   public final static KeyUsage KeyAgreement = new KeyUsage("KeyAgreement", pkif_moduleJNI.KeyAgreement_get());
00017   public final static KeyUsage KeyCertSign = new KeyUsage("KeyCertSign", pkif_moduleJNI.KeyCertSign_get());
00018   public final static KeyUsage CRLSign = new KeyUsage("CRLSign", pkif_moduleJNI.CRLSign_get());
00019   public final static KeyUsage EncipherOnly = new KeyUsage("EncipherOnly", pkif_moduleJNI.EncipherOnly_get());
00020   public final static KeyUsage DecipherOnly = new KeyUsage("DecipherOnly", pkif_moduleJNI.DecipherOnly_get());
00021 
00022   public final int swigValue() {
00023     return swigValue;
00024   }
00025 
00026   public String toString() {
00027     return swigName;
00028   }
00029 
00030   public static KeyUsage swigToEnum(int swigValue) {
00031     if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
00032       return swigValues[swigValue];
00033     for (int i = 0; i < swigValues.length; i++)
00034       if (swigValues[i].swigValue == swigValue)
00035         return swigValues[i];
00036     throw new IllegalArgumentException("No enum " + KeyUsage.class + " with value " + swigValue);
00037   }
00038 
00039   private KeyUsage(String swigName) {
00040     this.swigName = swigName;
00041     this.swigValue = swigNext++;
00042   }
00043 
00044   private KeyUsage(String swigName, int swigValue) {
00045     this.swigName = swigName;
00046     this.swigValue = swigValue;
00047     swigNext = swigValue+1;
00048   }
00049 
00050   private KeyUsage(String swigName, KeyUsage swigEnum) {
00051     this.swigName = swigName;
00052     this.swigValue = swigEnum.swigValue;
00053     swigNext = this.swigValue+1;
00054   }
00055 
00056   private static KeyUsage[] swigValues = { DigitalSignature, NonRepudiation, KeyEncipherment, DataEncipherment, KeyAgreement, KeyCertSign, CRLSign, EncipherOnly, DecipherOnly };
00057   private static int swigNext = 0;
00058   private final int swigValue;
00059   private final String swigName;
00060 }
00061 

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