Provides an interface to the database servers running on Pioneer players.
ConnectionManager knows how to locate the database servers running
on the players, and once started, can establish and share connections to them using the
ConnectionManager.invokeWithClientSession(int, org.deepsymmetry.beatlink.dbserver.ConnectionManager.ClientTask, java.lang.String)
Requests and responses to and from the database servers are structured as messages, encapsulated by the
Message class, and these are made up of fields, encapsulated by
Field. The known message types are found in
- James Elliott
Interface Summary Interface Description ConnectionManager.ClientTask<T>An interface for all the kinds of activities that need a connection to the dbserver, so we can keep track of how many sessions are in effect, clean up after them, and know when the client is idle and can be closed.
Class Summary Class Description BinaryFieldA binary field holds an arbitrary sequence of bytes whose length is determined by the 4-byte big-endian integer that follows the type tag. ClientManages a connection to the dbserver port on a particular player, allowing queries to be sent, and their responses to be interpreted. ConnectionManagerManges connections to dbserver ports on the players, offering sessions that can be used to perform transactions, and allowing the connections to close when there are no active sessions. FieldAll dbserver messages are made up of lists of fields, which are type-tagged values. Message NumberFieldA number field represents an integer, and can take up 1, 2, or 4 bytes, depending on the tag which introduces it. StringFieldA string field holds a UTF8-BE encoded string whose length is determined by the 4-byte big-endian integer that follows the type tag.
Enum Summary Enum Description Message.KnownTypeDefines all the message types we know about, with any information we know about their arguments. Message.MenuIdentifierFor many types of query messages, the first argument of the message is a 4-byte integer which we currently refer to as r:m:s:t, because the first byte is the player number of the player making the request, the second byte identifies the menu or destination for which information is being loaded, the third byte identifies the media slot (USB or SD) being asked about (as described in
CdjStatus.TrackSourceSlot), and the fourth byte identifies the type of track being worked with (for most requests this is 1, meaning rekordbox).
Message.MenuItemTypeDefines all the known types of entries that an be returned for a menu request.