Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-19935

Windows: Implement Ti.Network.Socket.TCP

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: Release 5.1.0
    • Fix Version/s: Release 6.1.0
    • Component/s: Windows
    • Labels:
    • Story Points:
      13
    • Sprint:
      2016 Sprint 16 SDK

      Description

      Implement Ti.Network.Socket.TCP for Windows.

      http://docs.appcelerator.com/platform/latest/#!/api/Titanium.Network.Socket.TCP

      NOTE: This is needed for LiveView

      Test Case

      var socket = Ti.Network.Socket.createTCP({
          host: 'pastebin.com', port: 80,
          connected: function (e) {
              Ti.API.info('socket connected');
       
              // receive callback
              Ti.Stream.pump(e.socket, function (e) {
                  alert(e.buffer.toString());
              }, 1024, true);
       
              // send GET request
              Ti.Stream.write(socket, Ti.createBuffer({
                  value: 'GET /raw/eF5dK0xU HTTP/1.1\r\nHost: pastebin.com\r\nConnection: close\r\n\r\n'
              }), function (e) {
                  Ti.API.info('socket sent GET');
              });
          }
      });
      socket.connect();
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                gmathews Gary Mathews
                Reporter:
                kiguchi Kota Iguchi (Inactive)
                Reviewer:
                Kota Iguchi (Inactive)
                Tester:
                Samir Mohammed
              • Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                    Git Integration