parameters: ( self, request, request_data )
docstring: Send a raw request with the supplied request block, and
      return the server's response. If the server is not running, it is started.
  
      This method is useful where the query block is not supplied, i.e. where just
      the files are being updated.
  
      The request block should contain the optional query block only. The file
      data are added automatically.
docstring_summary: Send a raw request with the supplied request block, and
      return the server's response. If the server is not running, it is started.
docstring_tokens: Send a raw request with the supplied request block and return the server s response . If the server is not running it is started .
function: def _PostRequest( self, request, request_data ):
      """Send a raw request with the supplied request block, and
      return the server's response. If the server is not running, it is started.
  
      This method is useful where the query block is not supplied, i.e. where just
      the files are being updated.
  
      The request block should contain the optional query block only. The file
      data are added automatically."""
  
      if not self._ServerIsRunning():
        raise ValueError( 'Not connected to server' )
  
      def MakeIncompleteFile( name, file_data ):
        return {
          'type': 'full',
          'name': name,
          'text': file_data[ 'contents' ],
        }
  
      file_data = request_data.get( 'file_data', {} )
  
      full_request = {
        'files': [ MakeIncompleteFile( x, file_data[ x ] )
                   for x in file_data.keys()
                   if 'javascript' in file_data[ x ][ 'filetypes' ] ],
      }
      full_request.update( request )
      try:
        response = urllib.request.urlopen(
          self._GetServerAddress(),
          data = ToBytes( json.dumps( full_request ) ) )
  
        json_response = json.loads( response.read() )
        response.close()
        return json_response
      except urllib.error.HTTPError as response:
        exception = ToUnicode( response.fp.read() )
        response.close()
        raise RuntimeError( exception )
function_tokens: def _PostRequest ( self , request , request_data ) : if not self . _ServerIsRunning ( ) : raise ValueError ( 'Not connected to server' ) def MakeIncompleteFile ( name , file_data ) : return { 'type' : 'full' , 'name' : name , 'text' : file_data [ 'contents' ] , } file_data = request_data . get ( 'file_data' , { } ) full_request = { 'files' : [ MakeIncompleteFile ( x , file_data [ x ] ) for x in file_data . keys ( ) if 'javascript' in file_data [ x ] [ 'filetypes' ] ] , } full_request . update ( request ) try : response = urllib . request . urlopen ( self . _GetServerAddress ( ) , data = ToBytes ( json . dumps ( full_request ) ) ) json_response = json . loads ( response . read ( ) ) response . close ( ) return json_response except urllib . error . HTTPError as response : exception = ToUnicode ( response . fp . read ( ) ) response . close ( ) raise RuntimeError ( exception )