Project

General

Profile

« Previous | Next » 

Revision 2300

sql_gen.py: Code: str(): Added class name. Added repr().

View differences:

lib/sql_gen.py
11 11
class Code:
12 12
    def to_str(self, db): raise NotImplemented()
13 13
    
14
    def __str__(self): return str(self.__dict__)
14
    def __str__(self): return util.class_name(self)+repr(self.__dict__)
15
    
16
    def __repr__(self): return str(self)
15 17

  
16 18
class CustomCode(Code):
17 19
    def __init__(self, str_): self.str_ = str_

Also available in: Unified diff