Record Class StreamOptions
java.lang.Object
java.lang.Record
org.j7m.middleware.examples.streaming.StreamOptions
- Record Components:
maxItemBytes- maximum UTF-8 item length accepted by the examplequeueLimit- maximum buffered server-side items
Stream-session options for the application-level streaming example.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StreamOptionsdefaults()Returns conservative defaults for demos and tests.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of themaxItemBytesrecord component.intReturns the value of thequeueLimitrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
StreamOptions
public StreamOptions(int maxItemBytes, int queueLimit) Creates stream options.- Parameters:
maxItemBytes- maximum item sizequeueLimit- queue limit
-
-
Method Details
-
defaults
Returns conservative defaults for demos and tests.- Returns:
- default stream options
-
toString
-
hashCode
-
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. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
maxItemBytes
public int maxItemBytes()Returns the value of themaxItemBytesrecord component.- Returns:
- the value of the
maxItemBytesrecord component
-
queueLimit
public int queueLimit()Returns the value of thequeueLimitrecord component.- Returns:
- the value of the
queueLimitrecord component
-