bosesoundtouchapi.models.sourcelist
SoundTouch device SourceList configuration object.
This class contains the attributes and sub-items that represent the sources configuration of the device.
Initializes a new instance of the class.
Arguments:
- root (Element): xmltree Element item to load arguments from.
If specified, then other passed arguments are ignored.
Returns a SourceItem
instance for the given source title value.
Arguments:
- title (str): Source title string to locate in the
SourceItems
list. Value is case-sensitive, and must match exactly.
Returns:
A
SourceItem
if the title argument value was found; otherwise, None.
Returns a title for the given source and sourceAccount values.
Arguments:
- source (str): The source of media content (e.g. "TUNEIN", "AIRPLAY", "UPNP", etc). Value is case-sensitive, and must match exactly.
- sourceAccount (str): The account associated with the Source. Value is case-sensitive, and must match exactly.
Returns:
A
SourceItem
.SourceTitle
if the title argument value was found; otherwise, None.
Returns a dictionary representation of the class.
Arguments:
- encoding (str): encode type (e.g. 'utf-8', 'unicode', etc).
Default is 'utf-8'.
Returns an xmltree Element node representation of the class.
Arguments:
- isRequestBody (bool): True if the element should only return attributes needed for a POST request body; otherwise, False to return all attributes.
Returns an array of source names (and optionally source account) strings.
Arguments:
- includeSourceAccount (bool): True to include SourceAccount property values if present; otherwise, False to only return Source property values.
If includeSourceAccount=True was specified and a SourceAccount value is present, then it will return the Source entry as "Source:sourceAccount" as well as a second entry of just the "Source" value; otherwise, just the "Source" value is returned for the source item.