comparison liboctave/array/Array.h @ 19861:19755f4fc851

maint: Cleanup C++ code to follow Octave coding conventions. Try to wrap long lines to < 80 characters. Use GNU style and don't indent first brace of function definition. "case" statement is aligned flush left with brace of switch stmt. Remove trailing '\' line continuation from the end of #define macros. Use 2 spaces for indent. * files-dock-widget.cc, history-dock-widget.cc, main-window.cc, octave-cmd.cc, octave-dock-widget.cc, octave-gui.cc, resource-manager.cc, settings-dialog.cc, shortcut-manager.cc, welcome-wizard.cc, workspace-view.cc, cellfun.cc, data.cc, debug.cc, debug.h, dirfns.cc, error.h, file-io.cc, gl-render.cc, gl-render.h, gl2ps-renderer.h, graphics.cc, graphics.in.h, help.cc, input.cc, load-path.cc, load-path.h, lookup.cc, lu.cc, oct-stream.cc, octave-default-image.h, ordschur.cc, pr-output.cc, qz.cc, strfns.cc, symtab.cc, symtab.h, sysdep.cc, variables.cc, zfstream.h, __fltk_uigetfile__.cc, __init_fltk__.cc, __magick_read__.cc, __osmesa_print__.cc, audiodevinfo.cc, ov-classdef.cc, ov-classdef.h, ov-fcn.h, ov-float.cc, ov-flt-complex.cc, ov-java.cc, ov-range.cc, ov-re-mat.cc, ov-usr-fcn.h, ov.cc, op-int.h, options-usage.h, pt-eval.cc, Array-C.cc, Array-fC.cc, Array.cc, Array.h, PermMatrix.cc, Sparse.cc, chMatrix.h, dSparse.cc, dim-vector.h, bsxfun-decl.h, bsxfun-defs.cc, oct-norm.cc, Sparse-op-defs.h, oct-inttypes.cc, oct-inttypes.h, main.in.cc, mkoctfile.in.cc: Cleanup C++ code to follow Octave coding conventions.
author Rik <rik@octave.org>
date Wed, 25 Feb 2015 11:55:49 -0800
parents 4197fc428c7d
children
comparison
equal deleted inserted replaced
19860:e8ccfc5d892b 19861:19755f4fc851
495 //@} 495 //@}
496 496
497 //@{ 497 //@{
498 //! Indexing with possible resizing and fill 498 //! Indexing with possible resizing and fill
499 499
500 // FIXME -- this is really a corner case, that should better be 500 // FIXME: this is really a corner case, that should better be
501 // handled directly in liboctinterp. 501 // handled directly in liboctinterp.
502 502
503 503
504 Array<T> index (const idx_vector& i, bool resize_ok, const T& rfv) const; 504 Array<T> index (const idx_vector& i, bool resize_ok, const T& rfv) const;
505 Array<T> index (const idx_vector& i, bool resize_ok) const 505 Array<T> index (const idx_vector& i, bool resize_ok) const
611 //! Count nonzero elements. 611 //! Count nonzero elements.
612 octave_idx_type nnz (void) const; 612 octave_idx_type nnz (void) const;
613 613
614 //! Find indices of (at most n) nonzero elements. If n is specified, 614 //! Find indices of (at most n) nonzero elements. If n is specified,
615 //! backward specifies search from backward. 615 //! backward specifies search from backward.
616 Array<octave_idx_type> find (octave_idx_type n = -1, bool backward = false) const; 616 Array<octave_idx_type> find (octave_idx_type n = -1,
617 bool backward = false) const;
617 618
618 //! Returns the n-th element in increasing order, using the same 619 //! Returns the n-th element in increasing order, using the same
619 //! ordering as used for sort. n can either be a scalar index or a 620 //! ordering as used for sort. n can either be a scalar index or a
620 //! contiguous range. 621 //! contiguous range.
621 Array<T> nth_element (const idx_vector& n, int dim = 0) const; 622 Array<T> nth_element (const idx_vector& n, int dim = 0) const;