Class CKAValueLen

  • All Implemented Interfaces:
    java.lang.AutoCloseable

    public class CKAValueLen
    extends CKAttribute
    CKAClass is an instance of a PKCS#11 CK_ATTRIBUTE with type = CKA_CLASS.
    • Constructor Summary

      Constructors 
      Constructor Description
      CKAValueLen()
      Representation of a PKCS#11 CK_ATTRIBUTE with type CKA_VALUE_LEN and default length for the key type.
      CKAValueLen​(long length)
      Representation of a PKCS#11 CK_ATTRIBUTE with type CKA_VALUE_LEN and a specified length.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void acquireNativeResources()
      Allocate native resources, setting mPointer and mPointerSize as appropriate.
      long getLength()
      Get the length of this CKA_VALUE_LEN attribute.
      protected void releaseNativeResources()
      Called to deallocate native resources; note that mPointer.close() is called afterwards.
      void setLength​(long length)
      Set the length specified by this CKA_VALUE_LEN attribute.
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CKAValueLen

        public CKAValueLen()
        Representation of a PKCS#11 CK_ATTRIBUTE with type CKA_VALUE_LEN and default length for the key type. Note that when key type is not specified and/or that mechanism lacks a default size, the corresponding PKCS#11 call will error out.
      • CKAValueLen

        public CKAValueLen​(long length)
        Representation of a PKCS#11 CK_ATTRIBUTE with type CKA_VALUE_LEN and a specified length.
    • Method Detail

      • setLength

        public void setLength​(long length)
        Set the length specified by this CKA_VALUE_LEN attribute.
      • getLength

        public long getLength()
        Get the length of this CKA_VALUE_LEN attribute.
      • releaseNativeResources

        protected void releaseNativeResources()
        Description copied from class: NativeEnclosure
        Called to deallocate native resources; note that mPointer.close() is called afterwards. If mPointer.close() should be a no-op, extend from StaticVoidRef and do any required cleanup here.
        Specified by:
        releaseNativeResources in class NativeEnclosure