init.hxx 3.02 KB
Newer Older
1
2
// Copyright (C) 2008, 2009, 2011 EPITA Research and Development
// Laboratory (LRDE)
3
//
4
// This file is part of Olena.
5
//
6
7
8
9
10
// Olena is free software: you can redistribute it and/or modify it under
// the terms of the GNU General Public License as published by the Free
// Software Foundation, version 2 of the License.
//
// Olena is distributed in the hope that it will be useful,
11
12
13
14
15
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
// General Public License for more details.
//
// You should have received a copy of the GNU General Public License
16
// along with Olena.  If not, see <http://www.gnu.org/licenses/>.
17
18
//
// As a special exception, you may use this file as part of a free
19
// software project without restriction.  Specifically, if other files
20
// instantiate templates or use macros or inline functions from this
21
22
23
24
25
// file, or you compile this file and link it with other files to produce
// an executable, this file does not by itself cause the resulting
// executable to be covered by the GNU General Public License.  This
// exception does not however invalidate any other reasons why the
// executable file might be covered by the GNU General Public License.
26
27
28
29
30
31
32
33
34
35
36
37
38
39

#ifndef MLN_CORE_ROUTINE_INIT_HXX
# define MLN_CORE_ROUTINE_INIT_HXX

/// \file mln/core/routine/init.hxx
///
// All overloaded "mln::init" routines have to be declared in
// the present file.  It allows for *deferred* use of these routines.

namespace mln
{

  // Forward declarations.
  namespace fun { namespace i2v { template <typename T> class array; } }
40
  namespace pw { namespace internal { template <typename F, typename S, typename E> class image_base; } }
41
  namespace pw { template <typename F, typename S> class image; }
42
  template <typename I, typename F> struct image_if;
43
44
45
46



  /// Kind: function_t
47
  /// Type: F1,
48
  /// From: pw::image<F,S>
49
50
  template <typename F, typename S, typename E, typename J>
  void init_(tag::image_t, pw::image<F,S>& target, const Image<J>& model);
51

52
53
54
55
56
  /// Kind: image_t
  /// Type: vertex_image<P,V,G>
  /// From: J
  template <typename P, typename V, typename G, typename J>
  void init_(tag::image_t, vertex_image<P,V,G>& target, const Image<J>& model);
57
58

  /// Kind: image_t
59
  /// Type: F
60
  /// From: J
61
62
  template <typename I, typename F, typename J>
  void init_(tag::image_t, image_if<I,F>& target, const J& model);
63
64


65
66
67
68
69
70
  /// Kind: function_t
  /// Type: F,
  /// From: pw::internal::image_base<F,S,E>
  template <typename F, typename S, typename E>
  void init_(tag::function_t, F& f, const pw::internal::image_base<F,S,E>& model);

71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
  /// Kind: function_t
  /// Type: F
  /// From: image_if<I,F>
  template <typename I, typename F>
  void init_(tag::function_t, F& f, const image_if<I,F>& model);

  /// Kind: function_t
  /// Type: fun::i2v::array<T1>
  /// From: fun::i2v::array<T2>
  template <typename T1, typename T2>
  void init_(tag::function_t,
	     fun::i2v::array<T1>&	  f,
	     const fun::i2v::array<T2>&	  model);

} // end of namespace mln

#endif // ! MLN_CORE_ROUTINE_INIT_HXX