Package io.github.mahmoudimus.http3
Record Class Http3Frame.PushPromise
java.lang.Object
java.lang.Record
io.github.mahmoudimus.http3.Http3Frame.PushPromise
- Record Components:
pushId- the push it promisesfieldSection- the encoded field section of the promised request, not copied
- All Implemented Interfaces:
Http3Frame
- Enclosing interface:
Http3Frame
public static record Http3Frame.PushPromise(long pushId, byte[] fieldSection)
extends Record
implements Http3Frame
PUSH_PROMISE (§7.2.5): a promised request's QPACK-encoded field section, on a request stream.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.github.mahmoudimus.http3.Http3Frame
Http3Frame.CancelPush, Http3Frame.Data, Http3Frame.GoAway, Http3Frame.Headers, Http3Frame.MaxPushId, Http3Frame.PushPromise, Http3Frame.Settings, Http3Frame.Unknown -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.byte[]Returns the value of thefieldSectionrecord component.final inthashCode()Returns a hash code value for this object.longpushId()Returns the value of thepushIdrecord component.final StringtoString()Returns a string representation of this record class.longtype()The frame type code: one of theHttp3FrameTypeconstants, or any other forHttp3Frame.Unknown.
-
Constructor Details
-
PushPromise
public PushPromise(long pushId, byte[] fieldSection) Creates PUSH_PROMISE.- Parameters:
pushId- the push it promises, 0 to 2^62-1fieldSection- the encoded field section, not copied
-
-
Method Details
-
type
public long type()Description copied from interface:Http3FrameThe frame type code: one of theHttp3FrameTypeconstants, or any other forHttp3Frame.Unknown.- Specified by:
typein interfaceHttp3Frame- Returns:
- the type code
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
pushId
public long pushId()Returns the value of thepushIdrecord component.- Returns:
- the value of the
pushIdrecord component
-
fieldSection
public byte[] fieldSection()Returns the value of thefieldSectionrecord component.- Returns:
- the value of the
fieldSectionrecord component
-