MArray-defs.h

Go to the documentation of this file.
00001 /*
00002 
00003 Copyright (C) 1996-2012 John W. Eaton
00004 Copyright (C) 2009 VZLU Prague, a.s.
00005 
00006 This file is part of Octave.
00007 
00008 Octave is free software; you can redistribute it and/or modify it
00009 under the terms of the GNU General Public License as published by the
00010 Free Software Foundation; either version 3 of the License, or (at your
00011 option) any later version.
00012 
00013 Octave is distributed in the hope that it will be useful, but WITHOUT
00014 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00015 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00016 for more details.
00017 
00018 You should have received a copy of the GNU General Public License
00019 along with Octave; see the file COPYING.  If not, see
00020 <http://www.gnu.org/licenses/>.
00021 
00022 */
00023 
00024 #if !defined (octave_MArray_defs_h)
00025 #define octave_MArray_defs_h 1
00026 
00027 #include "mx-inlines.cc"
00028 
00029 // Instantiate the OP= operators.
00030 #define MARRAY_OP_ASSIGN_DEFS(A_T, E_T, RHS_T, API) \
00031   MARRAY_OP_ASSIGN_DECLS (A_T, E_T, template, API, , RHS_T)
00032 
00033 #define MARRAY_OP_ASSIGN_DEFS1(A_T, E_T, RHS_T, API) \
00034   MARRAY_OP_ASSIGN_DECLS1 (A_T, E_T, template, API, , RHS_T)
00035 
00036 // Instantiate the unary operators.
00037 #define MARRAY_UNOP_DEFS(A_T, E_T, API) \
00038   MARRAY_UNOP_DECLS (A_T, E_T, template, API, )
00039 
00040 // Instantiate the binary operators.
00041 #define MARRAY_BINOP_DEFS(A_T, E_T, API) \
00042   MARRAY_BINOP_DECLS (A_T, E_T, template, API, , A_T<E_T>, E_T) \
00043   MARRAY_BINOP_DECLS (A_T, E_T, template, API, , E_T, A_T<E_T>) \
00044   MARRAY_AA_BINOP_DECLS (A_T, E_T, template, API, )
00045 
00046 #define MDIAGARRAY2_BINOP_DEFS(A_T, E_T, API) \
00047   MDIAGARRAY2_DAS_BINOP_DECLS (A_T, E_T, template, API, , A_T<E_T>, E_T) \
00048   MDIAGARRAY2_SDA_BINOP_DECLS (A_T, E_T, template, API, , E_T, A_T<E_T>) \
00049   MDIAGARRAY2_DADA_BINOP_DECLS (A_T, E_T, template, API, )
00050 
00051 // The following macros are for external use.
00052 
00053 // Instantiate all the MArray friends for MArray element type T.
00054 #define INSTANTIATE_MARRAY_FRIENDS(T, API) \
00055   MARRAY_OP_ASSIGN_DEFS1 (MArray, T, T, API) \
00056   MARRAY_OP_ASSIGN_DEFS (MArray, T, MArray<T>, API) \
00057   MARRAY_UNOP_DEFS (MArray, T, API) \
00058   MARRAY_BINOP_DEFS (MArray, T, API)
00059 
00060 // Instantiate all the MDiagArray2 friends for MDiagArray2 element type T.
00061 #define INSTANTIATE_MDIAGARRAY2_FRIENDS(T, API) \
00062   MARRAY_UNOP_DEFS (MDiagArray2, T, API) \
00063   MDIAGARRAY2_BINOP_DEFS (MDiagArray2, T, API)
00064 
00065 // Now we have all the definitions we need.
00066 
00067 #endif
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines