public class WonMessageUtils
extends java.lang.Object
| Constructor and Description |
|---|
WonMessageUtils() |
| Modifier and Type | Method and Description |
|---|---|
static java.util.Optional<java.net.URI> |
getHintTargetAtomURI(WonMessage wonMessage)
Get the targetAtom of a hint (even if it is a SocketHint).
|
static java.net.URI |
getHintTargetAtomURIRequired(WonMessage wonMessage)
Get the targetAtom of a hint (even if it is a SocketHint).
|
static java.util.Optional<java.net.URI> |
getParentAtomUri(WonMessage message,
WonMessageDirection direction)
Returns the atom that this message belongs to.
|
static java.util.Optional<java.net.URI> |
getRecipientAtomURI(WonMessage msg) |
static java.net.URI |
getRecipientAtomURIFromRecipientSocketURI(WonMessage msg) |
static java.net.URI |
getRecipientAtomURIRequired(WonMessage msg) |
static java.util.Optional<java.net.URI> |
getSenderAtomURI(WonMessage msg) |
static java.net.URI |
getSenderAtomURIFromSenderSocketURI(WonMessage msg,
java.net.URI atomUri) |
static java.net.URI |
getSenderAtomURIRequired(WonMessage msg) |
static boolean |
isValidMessageUri(java.net.URI messageURI) |
static java.net.URI |
stripAtomSuffix(java.net.URI atomURI)
Strip the atom suffix, return the WoN node URI.
|
static java.net.URI |
stripConnectionSuffix(java.net.URI connectionURI)
Strip the connection suffix, return the atom URI.
|
static java.net.URI |
stripFragment(java.net.URI uriWithFragment) |
public static java.util.Optional<java.net.URI> getSenderAtomURI(WonMessage msg)
public static java.net.URI getSenderAtomURIFromSenderSocketURI(WonMessage msg, java.net.URI atomUri)
public static java.net.URI getSenderAtomURIRequired(WonMessage msg)
public static java.util.Optional<java.net.URI> getRecipientAtomURI(WonMessage msg)
public static java.net.URI getRecipientAtomURIFromRecipientSocketURI(WonMessage msg)
public static java.net.URI getRecipientAtomURIRequired(WonMessage msg)
public static java.util.Optional<java.net.URI> getParentAtomUri(WonMessage message, WonMessageDirection direction)
message - public static java.net.URI stripFragment(java.net.URI uriWithFragment)
public static java.net.URI stripConnectionSuffix(java.net.URI connectionURI)
connectionURI - public static java.net.URI stripAtomSuffix(java.net.URI atomURI)
atomURI - public static java.net.URI getHintTargetAtomURIRequired(WonMessage wonMessage)
wonMessage - public static java.util.Optional<java.net.URI> getHintTargetAtomURI(WonMessage wonMessage)
wonMessage - public static boolean isValidMessageUri(java.net.URI messageURI)
Copyright © 2019. All Rights Reserved.