Example #1
0
File: K.py Project: plusxp/kx-1
 def __str__(self):
     """K objects are printed the way k would print them
     >>> print k('(1 ; 2 3; "abc")')
     (1
      2 3
      "abc")
      """
     return _K.__repr__(self)
Example #2
0
File: K.py Project: kevinarpe/kx
 def __str__(self):
     """K objects are printed the way k would print them
     >>> print k('(1 ; 2 3; "abc")')
     (1
      2 3
      "abc")
      """
     return _K.__repr__(self)
Example #3
0
File: K.py Project: plusxp/kx-1
 def __repr__(self):
     """returns a representation of the K object which can be evaluated by Python"""
     r = _K.__repr__(self)
     if '\n' in r or '"' in r:
         return 'k(""" ' + r + ' """)'
     return 'k("' + r + '")'
Example #4
0
File: K.py Project: kevinarpe/kx
 def __repr__(self):
     """returns a representation of the K object which can be evaluated by Python"""
     r = _K.__repr__(self)
     if '\n' in r or '"' in r:
         return 'k(""" ' + r + ' """)'
     return 'k("' + r + '")'