00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #if !defined (octave_streamoff_array_h)
00024 #define octave_streamoff_array_h 1
00025
00026 #if defined (__GNUG__) && defined (USE_PRAGMA_INTERFACE_IMPLEMENTATION)
00027 #pragma interface
00028 #endif
00029
00030 #include <iostream>
00031
00032 #include "ArrayN.h"
00033 #include "mx-op-defs.h"
00034
00035 class boolNDArray;
00036
00037
00038
00039 class streamoff_array : public ArrayN<std::streamoff>
00040 {
00041 public:
00042
00043 streamoff_array (void) : ArrayN<std::streamoff> () { }
00044
00045 streamoff_array (const dim_vector& dv,
00046 const std::streamoff& val = resize_fill_value ())
00047 : ArrayN<std::streamoff> (dv, val) { }
00048
00049 streamoff_array (const ArrayN<std::streamoff>& sa)
00050 : ArrayN<std::streamoff> (sa) { }
00051
00052 streamoff_array (const streamoff_array& sa)
00053 : ArrayN<std::streamoff> (sa) { }
00054
00055 ~streamoff_array (void) { }
00056
00057 streamoff_array& operator = (const streamoff_array& sa)
00058 {
00059 if (this != &sa)
00060 ArrayN<std::streamoff>::operator = (sa);
00061
00062 return *this;
00063 }
00064
00065 streamoff_array squeeze (void) const
00066 { return ArrayN<std::streamoff>::squeeze (); }
00067
00068 boolNDArray all (int dim = -1) const;
00069 boolNDArray any (int dim = -1) const;
00070
00071 static int compute_index (Array<int>& ra_idx,
00072 const dim_vector& dimensions);
00073
00074 static std::streamoff resize_fill_value (void) { return 0; }
00075 };
00076
00077 streamoff_array& operator += (streamoff_array& l, const std::streamoff& r);
00078 streamoff_array& operator -= (streamoff_array& l, const std::streamoff& r);
00079
00080 streamoff_array& operator += (streamoff_array& l, const streamoff_array& r);
00081 streamoff_array& operator -= (streamoff_array& l, const streamoff_array& r);
00082
00083 NDCMP_OP_DECL (mx_el_eq, std::streamoff, streamoff_array);
00084 NDCMP_OP_DECL (mx_el_ne, std::streamoff, streamoff_array);
00085
00086 NDCMP_OP_DECL (mx_el_eq, streamoff_array, std::streamoff);
00087 NDCMP_OP_DECL (mx_el_ne, streamoff_array, std::streamoff);
00088
00089 NDCMP_OP_DECL (mx_el_eq, streamoff_array, streamoff_array);
00090 NDCMP_OP_DECL (mx_el_ne, streamoff_array, streamoff_array);
00091
00092 BIN_OP_DECL (streamoff_array, operator +, streamoff_array, streamoff_array);
00093 BIN_OP_DECL (streamoff_array, operator -, streamoff_array, streamoff_array);
00094
00095 BIN_OP_DECL (streamoff_array, operator +, streamoff_array, std::streamoff);
00096 BIN_OP_DECL (streamoff_array, operator -, streamoff_array, std::streamoff);
00097
00098 BIN_OP_DECL (streamoff_array, operator +, std::streamoff, streamoff_array);
00099 BIN_OP_DECL (streamoff_array, operator -, std::streamoff, streamoff_array);
00100
00101 #endif
00102
00103
00104
00105
00106
00107