Back to index

texmacs  1.0.7.15
Functions
tm_link.cpp File Reference
#include "tm_link.hpp"
#include "../Plugins/Openssl/openssl.hpp"
#include "timer.hpp"

Go to the source code of this file.

Functions

static bool message_complete (string s)
static string message_receive (string &s)

Function Documentation

static bool message_complete ( string  s) [static]

Definition at line 21 of file tm_link.cpp.

                            {
  int start= 0;
  int i, n= N(s);
  if (n>0 && s[0] == '!') start= 1;
  for (i=start; i<n; i++)
    if (s[i] == '\n') break;
  if (i == n) return false;
  return (n - (i+1)) >= as_int (s (start, i));
}

Here is the call graph for this function:

Here is the caller graph for this function:

static string message_receive ( string s) [static]

Definition at line 32 of file tm_link.cpp.

                            {
  int start= 0;
  int i, n= N(s);
  if (n>0 && s[0] == '!') start= 1;
  for (i=start; i<n; i++)
    if (s[i] == '\n') break;
  if (i == n) return "";
  int l= as_int (s (start, i++));
  string r= s (i, i+l);
  s= s (i+l, n);
  return r;
}

Here is the call graph for this function:

Here is the caller graph for this function: