23 #ifndef _IGNITE_COMPUTE_COMPUTE 24 #define _IGNITE_COMPUTE_COMPUTE 26 #include <ignite/common/common.h> 32 #include <ignite/impl/compute/compute_impl.h> 84 Compute(common::concurrent::SharedPointer<impl::compute::ComputeImpl> impl) :
103 template<
typename R,
typename F>
106 return impl.Get()->CallAsync<R, F>(func).GetValue();
123 template<
typename R,
typename F>
126 return impl.Get()->CallAsync<R, F>(func);
141 return impl.Get()->RunAsync<F>(action).GetValue();
157 return impl.Get()->RunAsync<F>(action);
171 template<
typename R,
typename F>
174 return impl.Get()->BroadcastAsync<R, F>(func).GetValue();
188 impl.Get()->BroadcastAsync<F,
false>(func).GetValue();
204 template<
typename R,
typename F>
207 return impl.Get()->BroadcastAsync<R, F>(func);
223 return impl.Get()->BroadcastAsync<F,
false>(func);
228 common::concurrent::SharedPointer<impl::compute::ComputeImpl> impl;
233 #endif //_IGNITE_COMPUTE_COMPUTE R Call(const F &func)
Calls provided ComputeFunc on a node within the underlying cluster group.
Definition: compute.h:104
Future< R > CallAsync(const F &func)
Asyncronuously calls provided ComputeFunc on a node within the underlying cluster group...
Definition: compute.h:124
Future< void > RunAsync(const F &action)
Asyncronuously runs provided ComputeFunc on a node within the underlying cluster group.
Definition: compute.h:155
Specialization for void type.
Definition: future.h:167
Defines compute grid functionality for executing tasks and closures over nodes in the ClusterGroup...
Definition: compute.h:74
void Broadcast(const F &func)
Broadcasts provided ComputeFunc to all nodes in the cluster group.
Definition: compute.h:186
Compute(common::concurrent::SharedPointer< impl::compute::ComputeImpl > impl)
Constructor.
Definition: compute.h:84
Declares ignite::compute::ComputeFunc class template.
void Run(const F &action)
Runs provided ComputeFunc on a node within the underlying cluster group.
Definition: compute.h:139
Declares ignite::Future class template.
std::vector< R > Broadcast(const F &func)
Broadcasts provided ComputeFunc to all nodes in the cluster group.
Definition: compute.h:172
Apache Ignite API.
Definition: cache.h:48
Declares ignite::IgniteError class.
Future class template.
Definition: future.h:46
Future< std::vector< R > > BroadcastAsync(const F &func)
Asyncronuously broadcasts provided ComputeFunc to all nodes in the cluster group. ...
Definition: compute.h:205
Future< void > BroadcastAsync(const F &func)
Asyncronuously broadcasts provided ComputeFunc to all nodes in the cluster group. ...
Definition: compute.h:221