# See the License for the specific language governing permissions and
# limitations under the License.
-# Client for a MPD server
+# Music Player Daemon client library
module mpd
import socket
class MPDConnection
# Socket connection to server.
- var socket: nullable Socket = null
+ var socket: nullable TCPStream = null
# Server hostname.
var host: String
# Connect to the MPD server
fun connect
do
- var p: nullable Socket = null
+ var p: nullable TCPStream = null
- p = new Socket.client(host, port)
+ p = new TCPStream.connect(host, port)
+ assert p.connected
sys.nanosleep(0,5000)