00001
00002
00003
00004
00005
00006
00007
00008
00009 package com.orionsec.jpkif;
00010
00011 public class CPKIFNSSPtr {
00012 private long swigCPtr;
00013 protected boolean swigCMemOwn;
00014
00015 public CPKIFNSSPtr(long cPtr, boolean cMemoryOwn) {
00016 swigCMemOwn = cMemoryOwn;
00017 swigCPtr = cPtr;
00018 }
00019
00020 public static long getCPtr(CPKIFNSSPtr 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_CPKIFNSSPtr(swigCPtr);
00033 }
00034 swigCPtr = 0;
00035 }
00036 }
00037
00038 public void reset() {
00039 pkif_moduleJNI.CPKIFNSSPtr_reset(swigCPtr, this);
00040 }
00041
00042 public CPKIFNSS __deref__() {
00043 long cPtr = pkif_moduleJNI.CPKIFNSSPtr___deref__(swigCPtr, this);
00044 return (cPtr == 0) ? null : new CPKIFNSS(cPtr, false);
00045 }
00046
00047 public CPKIFNSS get() {
00048 long cPtr = pkif_moduleJNI.CPKIFNSSPtr_get(swigCPtr, this);
00049 return (cPtr == 0) ? null : new CPKIFNSS(cPtr, false);
00050 }
00051
00052 public boolean unique() {
00053 return pkif_moduleJNI.CPKIFNSSPtr_unique(swigCPtr, this);
00054 }
00055
00056 public int use_count() {
00057 return pkif_moduleJNI.CPKIFNSSPtr_use_count(swigCPtr, this);
00058 }
00059
00060 public void swap(CPKIFNSSPtr other) {
00061 pkif_moduleJNI.CPKIFNSSPtr_swap(swigCPtr, this, CPKIFNSSPtr.getCPtr(other), other);
00062 }
00063
00064 public SWIGTYPE_p_void _internal_get_deleter(SWIGTYPE_p_boost__detail__sp_typeinfo ti) {
00065 long cPtr = pkif_moduleJNI.CPKIFNSSPtr__internal_get_deleter(swigCPtr, this, SWIGTYPE_p_boost__detail__sp_typeinfo.getCPtr(ti));
00066 return (cPtr == 0) ? null : new SWIGTYPE_p_void(cPtr, false);
00067 }
00068
00069 public boolean _internal_equiv(CPKIFNSSPtr r) {
00070 return pkif_moduleJNI.CPKIFNSSPtr__internal_equiv(swigCPtr, this, CPKIFNSSPtr.getCPtr(r), r);
00071 }
00072
00073 public void Initialize() {
00074 pkif_moduleJNI.CPKIFNSSPtr_Initialize(swigCPtr, this);
00075 }
00076
00077 public void GetKeyList(CPKIFCredentialList v, SWIGTYPE_p_std__bitsetT_9_t arg1) {
00078 pkif_moduleJNI.CPKIFNSSPtr_GetKeyList__SWIG_0(swigCPtr, this, CPKIFCredentialList.getCPtr(v), v, SWIGTYPE_p_std__bitsetT_9_t.getCPtr(arg1));
00079 }
00080
00081 public void GetKeyList(CPKIFCredentialList v) {
00082 pkif_moduleJNI.CPKIFNSSPtr_GetKeyList__SWIG_1(swigCPtr, this, CPKIFCredentialList.getCPtr(v), v);
00083 }
00084
00085 public void GetKeyList(CPKIFCredentialList v, CPKIFKeyUsagePtr ku) {
00086 pkif_moduleJNI.CPKIFNSSPtr_GetKeyList__SWIG_2(swigCPtr, this, CPKIFCredentialList.getCPtr(v), v, CPKIFKeyUsagePtr.getCPtr(ku), ku);
00087 }
00088
00089 public boolean OwnsKey(CPKIFCredential keyID) {
00090 return pkif_moduleJNI.CPKIFNSSPtr_OwnsKey(swigCPtr, this, CPKIFCredential.getCPtr(keyID), keyID);
00091 }
00092
00093 public CPKIFCredentialPtr MakeKeyID(String asciiHexKeyID) {
00094 return new CPKIFCredentialPtr(pkif_moduleJNI.CPKIFNSSPtr_MakeKeyID(swigCPtr, this, asciiHexKeyID), true);
00095 }
00096
00097 public void Sign(CPKIFCredential key, byte[] pHashData, int nHashDataLen, byte[] pSignature, SWIGTYPE_p_int nSignatureLen, HASH_ALG hashAlg) {
00098 pkif_moduleJNI.CPKIFNSSPtr_Sign(swigCPtr, this, CPKIFCredential.getCPtr(key), key, pHashData, nHashDataLen, pSignature, SWIGTYPE_p_int.getCPtr(nSignatureLen), hashAlg.swigValue());
00099 }
00100
00101 public void Decrypt(CPKIFCredential key, byte[] pData, int nDataLen, byte[] pResult, SWIGTYPE_p_int pnResultLen) {
00102 pkif_moduleJNI.CPKIFNSSPtr_Decrypt__SWIG_0(swigCPtr, this, CPKIFCredential.getCPtr(key), key, pData, nDataLen, pResult, SWIGTYPE_p_int.getCPtr(pnResultLen));
00103 }
00104
00105 public void Decrypt(IPKIFCryptContext cryptContext, byte[] pData, int nDataLen, byte[] pResult, SWIGTYPE_p_int pnResultLen, boolean arg5) {
00106 pkif_moduleJNI.CPKIFNSSPtr_Decrypt__SWIG_1(swigCPtr, this, IPKIFCryptContext.getCPtr(cryptContext), cryptContext, pData, nDataLen, pResult, SWIGTYPE_p_int.getCPtr(pnResultLen), arg5);
00107 }
00108
00109 public void Encrypt(CPKIFCredential key, byte[] pData, int nDataLen, byte[] pResult, SWIGTYPE_p_int pnResultLen) {
00110 pkif_moduleJNI.CPKIFNSSPtr_Encrypt__SWIG_0(swigCPtr, this, CPKIFCredential.getCPtr(key), key, pData, nDataLen, pResult, SWIGTYPE_p_int.getCPtr(pnResultLen));
00111 }
00112
00113 public void Encrypt(IPKIFCryptContext cryptContext, byte[] pData, int nDataLen, byte[] pResult, SWIGTYPE_p_int pnResultLen, boolean arg5) {
00114 pkif_moduleJNI.CPKIFNSSPtr_Encrypt__SWIG_1(swigCPtr, this, IPKIFCryptContext.getCPtr(cryptContext), cryptContext, pData, nDataLen, pResult, SWIGTYPE_p_int.getCPtr(pnResultLen), arg5);
00115 }
00116
00117 public boolean Verify(CPKIFCredential key, byte[] pHashData, int nHashDataLen, byte[] pSignature, int nSignatureLen, HASH_ALG hashAlg) {
00118 return pkif_moduleJNI.CPKIFNSSPtr_Verify(swigCPtr, this, CPKIFCredential.getCPtr(key), key, pHashData, nHashDataLen, pSignature, nSignatureLen, hashAlg.swigValue());
00119 }
00120
00121 public IPKIFCryptContext CryptInit(CPKIFCredentialPtr key, boolean pad) {
00122 long cPtr = pkif_moduleJNI.CPKIFNSSPtr_CryptInit__SWIG_0(swigCPtr, this, CPKIFCredentialPtr.getCPtr(key), key, pad);
00123 return (cPtr == 0) ? null : new IPKIFCryptContext(cPtr, false);
00124 }
00125
00126 public IPKIFCryptContext CryptInit(CPKIFCredentialPtr key) {
00127 long cPtr = pkif_moduleJNI.CPKIFNSSPtr_CryptInit__SWIG_1(swigCPtr, this, CPKIFCredentialPtr.getCPtr(key), key);
00128 return (cPtr == 0) ? null : new IPKIFCryptContext(cPtr, false);
00129 }
00130
00131 public void AddParent(IPKIFColleague parent) {
00132 pkif_moduleJNI.CPKIFNSSPtr_AddParent(swigCPtr, this, IPKIFColleague.getCPtr(parent), parent);
00133 }
00134
00135 public void RemoveParent(IPKIFColleague parent) {
00136 pkif_moduleJNI.CPKIFNSSPtr_RemoveParent(swigCPtr, this, IPKIFColleague.getCPtr(parent), parent);
00137 }
00138
00139 public boolean IsParent(IPKIFColleague arg0) {
00140 return pkif_moduleJNI.CPKIFNSSPtr_IsParent(swigCPtr, this, IPKIFColleague.getCPtr(arg0), arg0);
00141 }
00142
00143 public void InitializeMediator(SWIGTYPE_p_std__vectorT_CPKIFException_p_t errorInfo) {
00144 pkif_moduleJNI.CPKIFNSSPtr_InitializeMediator__SWIG_0(swigCPtr, this, SWIGTYPE_p_std__vectorT_CPKIFException_p_t.getCPtr(errorInfo));
00145 }
00146
00147 public void InitializeMediator() {
00148 pkif_moduleJNI.CPKIFNSSPtr_InitializeMediator__SWIG_1(swigCPtr, this);
00149 }
00150
00151 public void Terminate() {
00152 pkif_moduleJNI.CPKIFNSSPtr_Terminate(swigCPtr, this);
00153 }
00154
00155 public void AddMediator(IPKIFColleaguePtr m) {
00156 pkif_moduleJNI.CPKIFNSSPtr_AddMediator(swigCPtr, this, IPKIFColleaguePtr.getCPtr(m), m);
00157 }
00158
00159 public void RemoveMediator(IPKIFColleague arg0) {
00160 pkif_moduleJNI.CPKIFNSSPtr_RemoveMediator(swigCPtr, this, IPKIFColleague.getCPtr(arg0), arg0);
00161 }
00162
00163 public void RemoveMediatorAssociations() {
00164 pkif_moduleJNI.CPKIFNSSPtr_RemoveMediatorAssociations(swigCPtr, this);
00165 }
00166
00167 public void GetMediators(IPKIFColleagueList v) {
00168 pkif_moduleJNI.CPKIFNSSPtr_GetMediators(swigCPtr, this, IPKIFColleagueList.getCPtr(v), v);
00169 }
00170
00171 }