GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Overview
  • Use
  • Tree
  • Deprecated
  • Index
  • Search
  • Help
  • io.netty.handler.codec.http.websocketx
  • WebSocketFrame

This view

  • Original page
  • New address

GeezerVison is showing netty.io — WebSocketFrame (Netty API Reference (4.1.141.Final))

Class WebSocketFrame

java.lang.Object
io.netty.buffer.DefaultByteBufHolder
io.netty.handler.codec.http.websocketx.WebSocketFrame
All Implemented Interfaces:
ByteBufHolder, ReferenceCounted
Direct Known Subclasses:
BinaryWebSocketFrame, CloseWebSocketFrame, ContinuationWebSocketFrame, PingWebSocketFrame, PongWebSocketFrame, TextWebSocketFrame

public abstract class WebSocketFrame extends DefaultByteBufHolder
Base class for web socket frames.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    WebSocketFrame(boolean finalFragment, int rsv, ByteBuf binaryData)
     
    protected
    WebSocketFrame(ByteBuf binaryData)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    WebSocketFrame
    copy()
    Creates a deep copy of this ByteBufHolder.
    WebSocketFrame
    duplicate()
    Duplicates this ByteBufHolder.
    boolean
    isFinalFragment()
    Flag to indicate if this frame is the final fragment in a message.
    abstract WebSocketFrame
    replace(ByteBuf content)
    Returns a new ByteBufHolder which contains the specified content.
    WebSocketFrame
    retain()
    Increases the reference count by 1.
    WebSocketFrame
    retain(int increment)
    Increases the reference count by the specified increment.
    WebSocketFrame
    retainedDuplicate()
    Duplicates this ByteBufHolder.
    int
    rsv()
    Bits used for extensions to the standard.
    String
    toString()
     
    WebSocketFrame
    touch()
    Records the current access location of this object for debugging purposes.
    WebSocketFrame
    touch(Object hint)
    Records the current access location of this object with an additional arbitrary information for debugging purposes.

    Methods inherited from class DefaultByteBufHolder

    content, contentToString, equals, hashCode, refCnt, release, release
    Modifier and Type
    Method
    Description
    ByteBuf
    content()
    Return the data which is held by this ByteBufHolder.
    protected final String
    contentToString()
    Return ByteBuf.toString() without checking the reference count first.
    boolean
    equals(Object o)
    This implementation of the equals operation is restricted to work only with instances of the same class.
    int
    hashCode()
     
    int
    refCnt()
    Returns the reference count of this object.
    boolean
    release()
    Decreases the reference count by 1 and deallocates this object if the reference count reaches at 0.
    boolean
    release(int decrement)
    Decreases the reference count by the specified decrement and deallocates this object if the reference count reaches at 0.

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • WebSocketFrame

      protected WebSocketFrame(ByteBuf binaryData)
    • WebSocketFrame

      protected WebSocketFrame(boolean finalFragment, int rsv, ByteBuf binaryData)
  • Method Details

    • isFinalFragment

      public boolean isFinalFragment()
      Flag to indicate if this frame is the final fragment in a message. The first fragment (frame) may also be the final fragment.
    • rsv

      public int rsv()
      Bits used for extensions to the standard.
    • copy

      public WebSocketFrame copy()
      Description copied from class: DefaultByteBufHolder
      Creates a deep copy of this ByteBufHolder.

      This method calls replace(content().copy()) by default.

      Specified by:
      copy in interface ByteBufHolder
      Overrides:
      copy in class DefaultByteBufHolder
    • duplicate

      public WebSocketFrame duplicate()
      Description copied from class: DefaultByteBufHolder
      Duplicates this ByteBufHolder. Be aware that this will not automatically call ByteBufHolder.retain().

      This method calls replace(content().duplicate()) by default.

      Specified by:
      duplicate in interface ByteBufHolder
      Overrides:
      duplicate in class DefaultByteBufHolder
    • retainedDuplicate

      public WebSocketFrame retainedDuplicate()
      Description copied from class: DefaultByteBufHolder
      Duplicates this ByteBufHolder. This method returns a retained duplicate unlike ByteBufHolder.duplicate().

      This method calls replace(content().retainedDuplicate()) by default.

      Specified by:
      retainedDuplicate in interface ByteBufHolder
      Overrides:
      retainedDuplicate in class DefaultByteBufHolder
      See Also:
      • ByteBuf.retainedDuplicate()
    • replace

      public abstract WebSocketFrame replace(ByteBuf content)
      Description copied from class: DefaultByteBufHolder
      Returns a new ByteBufHolder which contains the specified content.

      Override this method to return a new instance of this object whose content is set to the specified content. The default implementation of DefaultByteBufHolder.copy(), DefaultByteBufHolder.duplicate() and DefaultByteBufHolder.retainedDuplicate() invokes this method to create a copy.

      Specified by:
      replace in interface ByteBufHolder
      Overrides:
      replace in class DefaultByteBufHolder
    • toString

      public String toString()
      Overrides:
      toString in class DefaultByteBufHolder
    • retain

      public WebSocketFrame retain()
      Description copied from interface: ReferenceCounted
      Increases the reference count by 1.
      Specified by:
      retain in interface ByteBufHolder
      Specified by:
      retain in interface ReferenceCounted
      Overrides:
      retain in class DefaultByteBufHolder
    • retain

      public WebSocketFrame retain(int increment)
      Description copied from interface: ReferenceCounted
      Increases the reference count by the specified increment.
      Specified by:
      retain in interface ByteBufHolder
      Specified by:
      retain in interface ReferenceCounted
      Overrides:
      retain in class DefaultByteBufHolder
    • touch

      public WebSocketFrame touch()
      Description copied from interface: ReferenceCounted
      Records the current access location of this object for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you via ResourceLeakDetector. This method is a shortcut to touch(null).
      Specified by:
      touch in interface ByteBufHolder
      Specified by:
      touch in interface ReferenceCounted
      Overrides:
      touch in class DefaultByteBufHolder
    • touch

      public WebSocketFrame touch(Object hint)
      Description copied from interface: ReferenceCounted
      Records the current access location of this object with an additional arbitrary information for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you via ResourceLeakDetector.
      Specified by:
      touch in interface ByteBufHolder
      Specified by:
      touch in interface ReferenceCounted
      Overrides:
      touch in class DefaultByteBufHolder
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.