def to_OrderedDict(self, include_null=True):
        """
        Convert to OrderedDict.
        """
        if include_null:
            return OrderedDict(self.items())
        else:
            items = list()
            for c in self.__table__._columns:
                try:
                    items.append((c.name, self.__dict__[c.name]))
                except KeyError:
                    pass
            return OrderedDict(items)
def to_OrderedDict ( self , include_null = True ) : if include_null : return OrderedDict ( self . items ( ) ) else : items = list ( ) for c in self . __table__ . _columns : try : items . append ( ( c . name , self . __dict__ [ c . name ] ) ) except KeyError : pass return OrderedDict ( items )
Convert to OrderedDict.