YAACC - UPNP Client and Server
Loading...
Searching...
No Matches
de.yaacc.sendspin.discovery.SendspinServiceTxt Class Reference

The TXT record of a Sendspin player's announcement: path (the WebSocket endpoint; the specification makes it required, recommended /sendspin) and name (display text, optional). More...

Collaboration diagram for de.yaacc.sendspin.discovery.SendspinServiceTxt:
Collaboration graph

Public Member Functions

String yaacc ()
 The yaacc id of the phone that announced this (the key id of its player), or null: a YAACC phone puts the same id in the records of its player and of its server, which is how the two are shown as one card.
 
String path ()
 
String name ()
 The announced name, cleaned, or the empty text.
 

Static Public Member Functions

static SendspinServiceTxt parse (Map< String, byte[]> attributes)
 

Static Public Attributes

static final int MAX_PATH = 100
 

Detailed Description

The TXT record of a Sendspin player's announcement: path (the WebSocket endpoint; the specification makes it required, recommended /sendspin) and name (display text, optional).

Announcements are not authenticated, so both are hints that are checked: the path must match the path-absolute rule of RFC 3986 (the specification tells a server to connect only then; a path that does not is refused, a missing one is read as the default), the name is cleaned display text. Pure.

Member Function Documentation

◆ parse()

static SendspinServiceTxt de.yaacc.sendspin.discovery.SendspinServiceTxt.parse ( Map< String, byte[]> attributes)
static
Parameters
attributesthe TXT attributes as the platform gives them (values are bytes), may be null
Returns
the record, or null if the path is present and not acceptable (the service is not to be used)
Here is the call graph for this function:

◆ yaacc()

String de.yaacc.sendspin.discovery.SendspinServiceTxt.yaacc ( )

The yaacc id of the phone that announced this (the key id of its player), or null: a YAACC phone puts the same id in the records of its player and of its server, which is how the two are shown as one card.

Not authenticated: only used to join two announcements, never to trust anything.


The documentation for this class was generated from the following file: