Class CharArrayAttribute


  • public class CharArrayAttribute
    extends Attribute
    Objects of this class represent a char-array attribute of a PKCS#11 object as specified by PKCS#11.
    Author:
    Karl Scheibelhofer (SIC), Lijun Liao (xipki)
    • Constructor Detail

      • CharArrayAttribute

        public CharArrayAttribute​(long type)
        Constructor taking the PKCS#11 type of the attribute.
        Parameters:
        type - The PKCS#11 type of this attribute; e.g. CKA_LABEL.
    • Method Detail

      • charArrayValue

        protected CharArrayAttribute charArrayValue​(char[] value)
        Set the char-array value of this attribute. Null, is also valid. A call to this method sets the present flag to true.
        Parameters:
        value - The char-array value to set. May be null.
        Returns:
        a reference to this object.
      • stringValue

        public CharArrayAttribute stringValue​(String value)
        Set the char-array value of this attribute. Null, is also valid. A call to this method sets the present flag to true.
        Parameters:
        value - The char-array value to set. May be null.
        Returns:
        a reference to this object.
      • getValue

        public String getValue()
        Get the string value of this attribute. Null, is also possible.
        Specified by:
        getValue in class Attribute
        Returns:
        The char-array value of this attribute or null.
      • getValueString

        protected String getValueString()
        Get a string representation of the value of this attribute.
        Overrides:
        getValueString in class Attribute
        Returns:
        A string representation of the value of this attribute.