@@ 55-63 (lines=9) @@ | ||
52 | * |
|
53 | * @return Join[] |
|
54 | */ |
|
55 | public function generate(Query $query) |
|
56 | { |
|
57 | $uniqueId = spl_object_hash($query); |
|
58 | if (!isset($this->joinCache[$uniqueId])) { |
|
59 | $this->joinCache[$uniqueId] = $this->build($query); |
|
60 | } |
|
61 | ||
62 | return $this->joinCache[$uniqueId]; |
|
63 | } |
|
64 | ||
65 | /** |
|
66 | * @param Query $query |
@@ 61-69 (lines=9) @@ | ||
58 | * |
|
59 | * @return Select|null |
|
60 | */ |
|
61 | public function generate(Query $query) |
|
62 | { |
|
63 | $uniqueId = spl_object_hash($query); |
|
64 | if (!isset($this->selectCache[$uniqueId])) { |
|
65 | $this->selectCache[$uniqueId] = $this->build($query); |
|
66 | } |
|
67 | ||
68 | return $this->selectCache[$uniqueId]; |
|
69 | } |
|
70 | ||
71 | protected function build(Query $query) |
|
72 | { |
|
@@ 92-100 (lines=9) @@ | ||
89 | * |
|
90 | * @return string[] |
|
91 | */ |
|
92 | public function getSelectFieldMap(Query $query) |
|
93 | { |
|
94 | $uniqueId = spl_object_hash($query); |
|
95 | if (!isset($this->selectFieldMapCache[$uniqueId])) { |
|
96 | $this->selectFieldMapCache[$uniqueId] = $this->buildSelectFieldMap($query); |
|
97 | } |
|
98 | ||
99 | return $this->selectFieldMapCache[$uniqueId]; |
|
100 | } |
|
101 | ||
102 | /** |
|
103 | * @param Query $query |