| 2584 | @classmethod |
| 2585 | def setup_classes(cls): |
| 2586 | class Point(cls.Basic): |
| 2587 | def __init__(self, x, y): |
| 2588 | self.x = x |
| 2589 | self.y = y |
| 2590 | |
| 2591 | def __composite_values__(self): |
| 2592 | return [self.x, self.y] |
| 2593 | |
| 2594 | __hash__ = None |
| 2595 | |
| 2596 | def __eq__(self, other): |
| 2597 | return ( |
| 2598 | isinstance(other, Point) |
| 2599 | and other.x == self.x |
| 2600 | and other.y == self.y |
| 2601 | ) |
| 2602 | |
| 2603 | def __ne__(self, other): |
| 2604 | return not isinstance(other, Point) or not self.__eq__(other) |
| 2605 | |
| 2606 | class Graph(cls.DeclarativeBasic): |
| 2607 | __tablename__ = "graph" |
no outgoing calls