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

The text of a Sendspin player's card: the type, the player's name (cleaned: it came from the network), the address and the state in words. More...

Collaboration diagram for de.yaacc.sendspin.SendspinRowText:
Collaboration graph

Classes

enum  State
 What the card says about the connection. More...
 
interface  Words
 The words (the app fills them from its resources). More...
 

Static Public Member Functions

static State stateOf (HubConnection.Phase phase, HubConnection.EndReason reason, boolean playing, boolean paused)
 
static boolean offersPairing (State state)
 True if a tap on the card should offer the entry of a pairing token.
 
static boolean offersTokenEntry (State state, boolean connectedWithId, boolean paired)
 True if the sheet of a player's card offers the entry of a pairing token: when the card asks for it, and also when a player is connected that accepts unpaired servers and is not paired yet, because the operator may pair it anyway (a pairing survives a change of that player's settings, and an approval by playing does not prove who the player is).
 
static State stateOf (HubConnection.Phase phase, HubConnection.EndReason reason, HubConnection.PairingFailure failure, boolean paired, boolean playing, boolean paused)
 
static State stateOfServer (de.yaacc.sendspin.client.ControllerSession.Phase phase, de.yaacc.sendspin.client.ControllerSession.EndReason reason, boolean groupPlaying)
 The state of the card of a server from its session.
 
static String ofServer (String name, String address, State state, String nowPlaying, Words words)
 The text of the card of a server: Sendspin server, name, address, state (what plays is added to the state).
 
static String nowPlaying (String title, String artist)
 artist - title, with what is missing left out; both are cleaned (they came from a server).
 
static String of (String name, String address, State state, String title, Words words)
 The text of a card: Sendspin, name, address, state (the title of what plays is added to the state).
 
static String clean (String text)
 A text of the network or of a file for the display: no control or separator characters, trimmed, at most MAX_TEXT characters.
 

Static Public Attributes

static final int MAX_TEXT = 64
 The longest name or title shown.
 

Detailed Description

The text of a Sendspin player's card: the type, the player's name (cleaned: it came from the network), the address and the state in words.

Pure; the words come from the app's string resources.

Member Function Documentation

◆ stateOf() [1/2]

static State de.yaacc.sendspin.SendspinRowText.stateOf ( HubConnection.Phase phase,
HubConnection.EndReason reason,
boolean playing,
boolean paused )
static
Parameters
phasethe phase of the connection, null if there is none
reasonwhy it ended (only for an ended connection)

Referenced by de.yaacc.sendspin.SendspinRowText.stateOf().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ stateOf() [2/2]

static State de.yaacc.sendspin.SendspinRowText.stateOf ( HubConnection.Phase phase,
HubConnection.EndReason reason,
HubConnection.PairingFailure failure,
boolean paired,
boolean playing,
boolean paused )
static
Parameters
failurewhy the last pairing did not complete
pairedtrue if the connection is under the long-term PSK of a paired player

◆ stateOfServer()

static State de.yaacc.sendspin.SendspinRowText.stateOfServer ( de.yaacc.sendspin.client.ControllerSession.Phase phase,
de.yaacc.sendspin.client.ControllerSession.EndReason reason,
boolean groupPlaying )
static

The state of the card of a server from its session.

Parameters
groupPlayingwhether the group of this client plays (from group/update)

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