1 | // Copyright (C) 2010-2014 Conrad Sanderson |
---|
2 | // Copyright (C) 2010-2014 NICTA (www.nicta.com.au) |
---|
3 | // Copyright (C) 2010 Dimitrios Bouzas |
---|
4 | // |
---|
5 | // This Source Code Form is subject to the terms of the Mozilla Public |
---|
6 | // License, v. 2.0. If a copy of the MPL was not distributed with this |
---|
7 | // file, You can obtain one at http://mozilla.org/MPL/2.0/. |
---|
8 | |
---|
9 | |
---|
10 | |
---|
11 | //! \addtogroup op_find |
---|
12 | //! @{ |
---|
13 | |
---|
14 | |
---|
15 | |
---|
16 | class op_find |
---|
17 | { |
---|
18 | public: |
---|
19 | |
---|
20 | template<typename T1> |
---|
21 | inline static uword |
---|
22 | helper |
---|
23 | ( |
---|
24 | Mat<uword>& indices, |
---|
25 | const Base<typename T1::elem_type, T1>& X |
---|
26 | ); |
---|
27 | |
---|
28 | template<typename T1, typename op_type> |
---|
29 | inline static uword |
---|
30 | helper |
---|
31 | ( |
---|
32 | Mat<uword>& indices, |
---|
33 | const mtOp<uword, T1, op_type>& X, |
---|
34 | const typename arma_op_rel_only<op_type>::result junk1 = 0, |
---|
35 | const typename arma_not_cx<typename T1::elem_type>::result junk2 = 0 |
---|
36 | ); |
---|
37 | |
---|
38 | template<typename T1, typename op_type> |
---|
39 | inline static uword |
---|
40 | helper |
---|
41 | ( |
---|
42 | Mat<uword>& indices, |
---|
43 | const mtOp<uword, T1, op_type>& X, |
---|
44 | const typename arma_op_rel_only<op_type>::result junk1 = 0, |
---|
45 | const typename arma_cx_only<typename T1::elem_type>::result junk2 = 0 |
---|
46 | ); |
---|
47 | |
---|
48 | template<typename T1, typename T2, typename glue_type> |
---|
49 | inline static uword |
---|
50 | helper |
---|
51 | ( |
---|
52 | Mat<uword>& indices, |
---|
53 | const mtGlue<uword, T1, T2, glue_type>& X, |
---|
54 | const typename arma_glue_rel_only<glue_type>::result junk1 = 0, |
---|
55 | const typename arma_not_cx<typename T1::elem_type>::result junk2 = 0, |
---|
56 | const typename arma_not_cx<typename T2::elem_type>::result junk3 = 0 |
---|
57 | ); |
---|
58 | |
---|
59 | template<typename T1, typename T2, typename glue_type> |
---|
60 | inline static uword |
---|
61 | helper |
---|
62 | ( |
---|
63 | Mat<uword>& indices, |
---|
64 | const mtGlue<uword, T1, T2, glue_type>& X, |
---|
65 | const typename arma_glue_rel_only<glue_type>::result junk1 = 0, |
---|
66 | const typename arma_cx_only<typename T1::elem_type>::result junk2 = 0, |
---|
67 | const typename arma_cx_only<typename T2::elem_type>::result junk3 = 0 |
---|
68 | ); |
---|
69 | |
---|
70 | template<typename T1> |
---|
71 | inline static void apply(Mat<uword>& out, const mtOp<uword, T1, op_find>& X); |
---|
72 | }; |
---|
73 | |
---|
74 | |
---|
75 | |
---|
76 | class op_find_simple |
---|
77 | { |
---|
78 | public: |
---|
79 | |
---|
80 | template<typename T1> |
---|
81 | inline static void apply(Mat<uword>& out, const mtOp<uword, T1, op_find_simple>& X); |
---|
82 | }; |
---|
83 | |
---|
84 | |
---|
85 | |
---|
86 | class op_find_finite |
---|
87 | { |
---|
88 | public: |
---|
89 | |
---|
90 | template<typename T1> |
---|
91 | inline static void apply(Mat<uword>& out, const mtOp<uword, T1, op_find_finite>& X); |
---|
92 | }; |
---|
93 | |
---|
94 | |
---|
95 | |
---|
96 | class op_find_nonfinite |
---|
97 | { |
---|
98 | public: |
---|
99 | |
---|
100 | template<typename T1> |
---|
101 | inline static void apply(Mat<uword>& out, const mtOp<uword, T1, op_find_nonfinite>& X); |
---|
102 | }; |
---|
103 | |
---|
104 | |
---|
105 | |
---|
106 | //! @} |
---|