com.jscape.inet.mime

## Class MimeHeaderAttr

- java.lang.Object
- - com.jscape.inet.mime.MimeHeaderAttr

- All Implemented Interfaces:
    java.io.Serializable

      public class MimeHeaderAttr
      extends java.lang.Object
      implements java.io.Serializable

  Implements methods for managing the attributes of a `MimeHeader`.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `MimeHeaderAttr()` Constructs a new `MimeHeaderAttr` instance.
    `MimeHeaderAttr(byte[] attr)` Constructs a new `MimeHeaderAttr` instance.
    `MimeHeaderAttr(java.lang.String attr)` Constructs a new `MimeHeaderAttr` instance.
    `MimeHeaderAttr(java.lang.String name, java.lang.String value)` Constructs a new `MimeHeaderAttr` instance.
    `MimeHeaderAttr(java.lang.String name, java.lang.String value, java.lang.String characterEncoding)` Constructs a new `MimeHeaderAttr` instance.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getName()` Gets name of attribute.
    `java.lang.String` | `getValue()` Gets value of attribute.
    `java.lang.String` | `getValueString()` Gets value of attribute.
    `void` | `setName(java.lang.String name)` Sets name of attribute.
    `void` | `setValue(java.lang.String value)` Sets value of attribute.
    `java.lang.String` | `toString()` Gets String representation of this `MimeHeaderAttr`.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### MimeHeaderAttr

          public MimeHeaderAttr()

      Constructs a new `MimeHeaderAttr` instance.

    - #### MimeHeaderAttr

          public MimeHeaderAttr(java.lang.String attr)
                         throws MimeException

      Constructs a new `MimeHeaderAttr` instance.
      Parameters:
        `attr` - the unparsed MIME header attribute data
      Throws:
        `MimeException` - if a MIME related parsing error occurs

    - #### MimeHeaderAttr

          public MimeHeaderAttr(byte[] attr)
                         throws MimeException

      Constructs a new `MimeHeaderAttr` instance.
      Parameters:
        `attr` - the unparsed MIME header attribute data
      Throws:
        `MimeException` - if a MIME related parsing error occurs

    - #### MimeHeaderAttr

          public MimeHeaderAttr(java.lang.String name,
                                java.lang.String value)
                         throws MimeException

      Constructs a new `MimeHeaderAttr` instance.
      Parameters:
        `name` - the name of attribute
        `value` - the value of attribute
      Throws:
        `MimeException` - if a MIME related parsing error occurs

    - #### MimeHeaderAttr

          public MimeHeaderAttr(java.lang.String name,
                                java.lang.String value,
                                java.lang.String characterEncoding)
                         throws MimeException

      Constructs a new `MimeHeaderAttr` instance.
      Parameters:
        `name` - the name of attribute
        `value` - the value of attribute
        `characterEncoding` - the character encoding to use for the attribute value
      Throws:
        `MimeException` - if a MIME related parsing error occurs

  - ### Method Detail

    - #### getName

          public java.lang.String getName()

      Gets name of attribute.
      Returns:
        name

    - #### setName

          public void setName(java.lang.String name)

      Sets name of attribute.
      Parameters:
        `name` - the name of attribute

    - #### getValue

          public java.lang.String getValue()
                                    throws MimeException

      Gets value of attribute. Removes quotes if found.
      Returns:
        value
      Throws:
        `MimeException` - if a MIME related parsing error occurs

    - #### getValueString

          public java.lang.String getValueString()

      Gets value of attribute. Leaves quotes if found.
      Returns:
        value
      Throws:
        `MimeException` - if a MIME related parsing error occurs

    - #### setValue

          public void setValue(java.lang.String value)

      Sets value of attribute.
      Parameters:
        `value` - the attribute value

    - #### toString

          public java.lang.String toString()

      Gets String representation of this `MimeHeaderAttr`.
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:
        String

Copyright © JSCAPE LLC. 1999-2021. All Rights Reserved