spray.http.HttpData

NonEmpty

sealed abstract class NonEmpty extends HttpData

Linear Supertypes
HttpData, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. NonEmpty
  2. HttpData
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new NonEmpty()

Abstract Value Members

  1. abstract def copyToArray(xs: Array[Byte], sourceOffset: Long = 0, targetOffset: Int = 0, span: Int = length.toInt): Unit

    Extracts span bytes from this instance starting at sourceOffset and copies them to the xs starting at targetOffset.

    Extracts span bytes from this instance starting at sourceOffset and copies them to the xs starting at targetOffset. If span is larger than the number of bytes available in this instance after the sourceOffset or if xs has less space available after targetOffset the number of bytes copied is decreased accordingly (i.e. it is not an error to specify a span that is too large).

    Definition Classes
    HttpData
  2. abstract def length: Long

    Returns the number of bytes contained in this instance.

    Returns the number of bytes contained in this instance.

    Definition Classes
    HttpData
  3. abstract def slice(offset: Long = 0, span: Long = length): HttpData

    Returns a slice of this instance as an HttpData.

    Returns a slice of this instance as an HttpData.

    Definition Classes
    HttpData
  4. abstract def toByteString: ByteString

    Same as toByteArray but returning a ByteString instead.

    Same as toByteArray but returning a ByteString instead. More efficient if this instance is a Bytes instance since no data will have to be copied and the ByteString will not have to be newly created.

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!). If this instance is a FileBytes instance containing more than 2GB of data the method will throw an IllegalArgumentException.

    Definition Classes
    HttpData

Concrete Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. def +:(other: HttpData): NonEmpty

    Efficiently prepends this instance with another HttpData instance to possibly form a compound instance.

    Efficiently prepends this instance with another HttpData instance to possibly form a compound instance. No data need to be copied around to do this.

    Definition Classes
    NonEmptyHttpData
  5. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  6. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def asString(charset: Charset): String

    Returns the contents of this instance as a string.

    Returns the contents of this instance as a string.

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!). If this instance is a FileBytes instance containing more than 2GB of data the method will throw an IllegalArgumentException.

    Definition Classes
    HttpData
  9. def asString(charset: HttpCharset): String

    Returns the contents of this instance as a string.

    Returns the contents of this instance as a string.

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!). If this instance is a FileBytes instance containing more than 2GB of data the method will throw an IllegalArgumentException.

    Definition Classes
    HttpData
  10. def asString: String

    Returns the contents of this instance as a string (using UTF-8 encoding).

    Returns the contents of this instance as a string (using UTF-8 encoding).

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!). If this instance is a FileBytes instance containing more than 2GB of data the method will throw an IllegalArgumentException.

    Definition Classes
    HttpData
  11. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  16. def hasFileBytes: Boolean

    Determines whether this instance is or contains data that are not already present in the JVM heap (i.

    Determines whether this instance is or contains data that are not already present in the JVM heap (i.e. instance of HttpData.FileBytes).

    Definition Classes
    HttpData
  17. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  18. def isEmpty: Boolean

    Determines whether this instance is identical to HttpData.

    Determines whether this instance is identical to HttpData.Empty.

    Definition Classes
    HttpData
  19. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  20. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  21. def nonEmpty: Boolean

    Determines whether this instance is different from HttpData.

    Determines whether this instance is different from HttpData.Empty.

    Definition Classes
    HttpData
  22. final def notify(): Unit

    Definition Classes
    AnyRef
  23. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  24. def sliceBytes(offset: Long, span: Int): ByteString

    Returns a slice of this instance's content as a ByteString.

    Returns a slice of this instance's content as a ByteString.

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!).

    Definition Classes
    NonEmptyHttpData
  25. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  26. def toByteArray: Array[Byte]

    Copies the contents of this instance into a new byte array.

    Copies the contents of this instance into a new byte array.

    CAUTION: Since this instance might point to bytes contained in an off-memory file this method might cause the loading of a large amount of data into the JVM heap (up to 2 GB!). If this instance is a FileBytes instance containing more than 2GB of data the method will throw an IllegalArgumentException.

    Definition Classes
    NonEmptyHttpData
  27. def toChunkStream(maxChunkSize: Long): Stream[HttpData]

    Returns the contents of this instance as a Stream[HttpData] with each chunk not being larger than the given maxChunkSize.

    Returns the contents of this instance as a Stream[HttpData] with each chunk not being larger than the given maxChunkSize.

    Definition Classes
    NonEmptyHttpData
  28. def toString(): String

    Definition Classes
    AnyRef → Any
  29. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  30. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  31. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from HttpData

Inherited from AnyRef

Inherited from Any

Ungrouped