Class WebSocketSettings
java.lang.Object
org.apache.pekko.http.scaladsl.settings.WebSocketSettings
- All Implemented Interfaces:
WebSocketSettings
- Direct Known Subclasses:
WebSocketSettingsImpl
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal Supplier<org.apache.pekko.util.ByteString>The provided supplier will be invoked for each new keep-alive frame that is sent.abstract booleanabstract scala.Function0<org.apache.pekko.util.ByteString>The provided function will be invoked for each new keep-alive frame that is sent.abstract scala.concurrent.duration.Durationabstract Stringabstract scala.Function0<Random>withLogFrames(boolean shouldLog) withPeriodicKeepAliveData(scala.Function0<org.apache.pekko.util.ByteString> newValue) withPeriodicKeepAliveMaxIdle(scala.concurrent.duration.Duration newValue) withPeriodicKeepAliveMode(String newValue) withRandomFactoryFactory(Supplier<Random> newValue) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.pekko.http.javadsl.settings.WebSocketSettings
getPeriodicKeepAliveMaxIdle, withPeriodicKeepAliveData, withPeriodicKeepAliveMaxIdle
-
Constructor Details
-
WebSocketSettings
public WebSocketSettings()
-
-
Method Details
-
getPeriodicKeepAliveData
Description copied from interface:WebSocketSettingsThe provided supplier will be invoked for each new keep-alive frame that is sent. The ByteString will be included in the Ping or Pong frame sent as heartbeat, so keep in mind to keep it relatively small, in order not to make the frames too bloated.- Specified by:
getPeriodicKeepAliveDatain interfaceWebSocketSettings- Returns:
- (undocumented)
-
getRandomFactory
- Specified by:
getRandomFactoryin interfaceWebSocketSettings
-
logFrames
public abstract boolean logFrames()- Specified by:
logFramesin interfaceWebSocketSettings
-
periodicKeepAliveData
public abstract scala.Function0<org.apache.pekko.util.ByteString> periodicKeepAliveData()The provided function will be invoked for each new keep-alive frame that is sent. The ByteString will be included in the Ping or Pong frame sent as heartbeat, so keep in mind to keep it relatively small, in order not to make the frames too bloated.- Returns:
- (undocumented)
-
periodicKeepAliveMaxIdle
public abstract scala.concurrent.duration.Duration periodicKeepAliveMaxIdle()- Specified by:
periodicKeepAliveMaxIdlein interfaceWebSocketSettings
-
periodicKeepAliveMode
- Specified by:
periodicKeepAliveModein interfaceWebSocketSettings
-
randomFactory
-
withLogFrames
- Specified by:
withLogFramesin interfaceWebSocketSettings
-
withPeriodicKeepAliveData
public WebSocketSettings withPeriodicKeepAliveData(scala.Function0<org.apache.pekko.util.ByteString> newValue) -
withPeriodicKeepAliveMaxIdle
- Specified by:
withPeriodicKeepAliveMaxIdlein interfaceWebSocketSettings
-
withPeriodicKeepAliveMode
- Specified by:
withPeriodicKeepAliveModein interfaceWebSocketSettings
-
withRandomFactoryFactory
- Specified by:
withRandomFactoryFactoryin interfaceWebSocketSettings
-