| OLD | NEW |
| 1 // This file was GENERATED by command: | 1 // This file was GENERATED by command: |
| 2 // pump.py bind.h.pump | 2 // pump.py bind.h.pump |
| 3 // DO NOT EDIT BY HAND!!! | 3 // DO NOT EDIT BY HAND!!! |
| 4 | 4 |
| 5 | 5 |
| 6 | 6 |
| 7 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 7 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 8 // Use of this source code is governed by a BSD-style license that can be | 8 // Use of this source code is governed by a BSD-style license that can be |
| 9 // found in the LICENSE file. | 9 // found in the LICENSE file. |
| 10 | 10 |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 typename P5, typename P6> | 88 typename P5, typename P6> |
| 89 internal::InvokerStorageHolder<internal::InvokerStorage6<Sig,P1, P2, P3, P4, | 89 internal::InvokerStorageHolder<internal::InvokerStorage6<Sig,P1, P2, P3, P4, |
| 90 P5, P6> > | 90 P5, P6> > |
| 91 Bind(Sig f, const P1& p1, const P2& p2, const P3& p3, const P4& p4, | 91 Bind(Sig f, const P1& p1, const P2& p2, const P3& p3, const P4& p4, |
| 92 const P5& p5, const P6& p6) { | 92 const P5& p5, const P6& p6) { |
| 93 return internal::MakeInvokerStorageHolder( | 93 return internal::MakeInvokerStorageHolder( |
| 94 new internal::InvokerStorage6<Sig, P1, P2, P3, P4, P5, P6>( | 94 new internal::InvokerStorage6<Sig, P1, P2, P3, P4, P5, P6>( |
| 95 f, p1, p2, p3, p4, p5, p6)); | 95 f, p1, p2, p3, p4, p5, p6)); |
| 96 } | 96 } |
| 97 | 97 |
| 98 template <typename Sig, typename P1, typename P2, typename P3, typename P4, |
| 99 typename P5, typename P6, typename P7> |
| 100 internal::InvokerStorageHolder<internal::InvokerStorage7<Sig,P1, P2, P3, P4, |
| 101 P5, P6, P7> > |
| 102 Bind(Sig f, const P1& p1, const P2& p2, const P3& p3, const P4& p4, |
| 103 const P5& p5, const P6& p6, const P7& p7) { |
| 104 return internal::MakeInvokerStorageHolder( |
| 105 new internal::InvokerStorage7<Sig, P1, P2, P3, P4, P5, P6, P7>( |
| 106 f, p1, p2, p3, p4, p5, p6, p7)); |
| 107 } |
| 108 |
| 98 // Specializations to allow binding all the free arguments in a | 109 // Specializations to allow binding all the free arguments in a |
| 99 // pre-existing base::Callback<>. This does not give full support for | 110 // pre-existing base::Callback<>. This does not give full support for |
| 100 // currying, but is significantly simpler and addresses the use case | 111 // currying, but is significantly simpler and addresses the use case |
| 101 // where a base::Callback<> needs to be invoked on another context/thread. | 112 // where a base::Callback<> needs to be invoked on another context/thread. |
| 102 template <typename Sig, typename P1> | 113 template <typename Sig, typename P1> |
| 103 base::Closure Bind(const base::Callback<Sig>& callback, const P1& p1) { | 114 base::Closure Bind(const base::Callback<Sig>& callback, const P1& p1) { |
| 104 return base::Bind(&internal::BindMoreFunc1<Sig, P1>, callback, p1); | 115 return base::Bind(&internal::BindMoreFunc1<Sig, P1>, callback, p1); |
| 105 } | 116 } |
| 106 | 117 |
| 107 template <typename Sig, typename P1, typename P2> | 118 template <typename Sig, typename P1, typename P2> |
| (...skipping 25 matching lines...) Expand all Loading... |
| 133 } | 144 } |
| 134 | 145 |
| 135 template <typename Sig, typename P1, typename P2, typename P3, typename P4, | 146 template <typename Sig, typename P1, typename P2, typename P3, typename P4, |
| 136 typename P5, typename P6> | 147 typename P5, typename P6> |
| 137 base::Closure Bind(const base::Callback<Sig>& callback, const P1& p1, | 148 base::Closure Bind(const base::Callback<Sig>& callback, const P1& p1, |
| 138 const P2& p2, const P3& p3, const P4& p4, const P5& p5, const P6& p6) { | 149 const P2& p2, const P3& p3, const P4& p4, const P5& p5, const P6& p6) { |
| 139 return base::Bind(&internal::BindMoreFunc6<Sig, P1, P2, P3, P4, P5, P6>, | 150 return base::Bind(&internal::BindMoreFunc6<Sig, P1, P2, P3, P4, P5, P6>, |
| 140 callback, p1, p2, p3, p4, p5, p6); | 151 callback, p1, p2, p3, p4, p5, p6); |
| 141 } | 152 } |
| 142 | 153 |
| 154 template <typename Sig, typename P1, typename P2, typename P3, typename P4, |
| 155 typename P5, typename P6, typename P7> |
| 156 base::Closure Bind(const base::Callback<Sig>& callback, const P1& p1, |
| 157 const P2& p2, const P3& p3, const P4& p4, const P5& p5, const P6& p6, |
| 158 const P7& p7) { |
| 159 return base::Bind(&internal::BindMoreFunc7<Sig, P1, P2, P3, P4, P5, P6, P7>, |
| 160 callback, p1, p2, p3, p4, p5, p6, p7); |
| 161 } |
| 162 |
| 143 } // namespace base | 163 } // namespace base |
| 144 | 164 |
| 145 #endif // BASE_BIND_H_ | 165 #endif // BASE_BIND_H_ |
| OLD | NEW |