Class BodyPart<T>

java.lang.Object
kong.unirest.core.BodyPart<T>
All Implemented Interfaces:
Comparable
Direct Known Subclasses:
ByteArrayPart, FilePart, InputStreamBody, InputStreamPart, ParamPart, UnibodyString, UniByteArrayBody

public abstract class BodyPart<T> extends Object implements Comparable
  • Field Details

    • name

      private final String name
    • value

      private final T value
    • contentType

      private final String contentType
    • partType

      private final Class<?> partType
  • Constructor Details

    • BodyPart

      protected BodyPart(T value, String name, String contentType)
  • Method Details

    • getValue

      public T getValue()
    • getPartType

      public Class<?> getPartType()
    • getContentType

      public String getContentType()
    • getName

      public String getName()
    • getFileName

      public String getFileName()
    • compareTo

      public int compareTo(Object o)
      Specified by:
      compareTo in interface Comparable<T>
    • isFile

      public abstract boolean isFile()