org.springframework.web.socket.sockjs.frame

## Class SockJsFrame

- java.lang.Object
- - org.springframework.web.socket.sockjs.frame.SockJsFrame

-     public class SockJsFrame
      extends Object

  Represents a SockJS frame and provides factory methods for creating SockJS frames.
  Since:
    4.0
  Author:
    Rossen Stoyanchev

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `SockJsFrame(String content)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static SockJsFrame` | `closeFrame(int code, String reason)`
    `static SockJsFrame` | `closeFrameAnotherConnectionOpen()`
    `static SockJsFrame` | `closeFrameGoAway()`
    `boolean` | `equals(Object other)`
    `String` | `getContent()`
    `byte[]` | `getContentBytes()`
    `int` | `hashCode()`
    `static SockJsFrame` | `heartbeatFrame()`
    `static SockJsFrame` | `messageFrame(SockJsMessageCodec codec, String... messages)`
    `static SockJsFrame` | `openFrame()`
    `String` | `toString()`

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

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### SockJsFrame

          public SockJsFrame(String content)

  - ### Method Detail

    - #### openFrame

          public static SockJsFrame openFrame()

    - #### heartbeatFrame

          public static SockJsFrame heartbeatFrame()

    - #### messageFrame

          public static SockJsFrame messageFrame(SockJsMessageCodec codec,
                                                 String... messages)

    - #### closeFrameGoAway

          public static SockJsFrame closeFrameGoAway()

    - #### closeFrameAnotherConnectionOpen

          public static SockJsFrame closeFrameAnotherConnectionOpen()

    - #### closeFrame

          public static SockJsFrame closeFrame(int code,
                                               String reason)

    - #### getContent

          public String getContent()

    - #### getContentBytes

          public byte[] getContentBytes()

    - #### equals

          public boolean equals(Object other)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`