Commit e0ed218c authored by sjplimp's avatar sjplimp Committed by GitHub
Browse files

Merge pull request #224 from akohlmey/get-vars

provide an accessor for names of LAMMPS variables
parents efc7b23b c5513c4f
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1079,3 +1079,10 @@ bool Info::has_exceptions() const {
  return false;
#endif
}

/* ---------------------------------------------------------------------- */

char **Info::get_variable_names(int &num) {
    num = input->variable->nvar;
    return input->variable->names;
}
+2 −0
Original line number Diff line number Diff line
@@ -39,6 +39,8 @@ class Info : protected Pointers {
  bool has_ffmpeg_support() const;
  bool has_exceptions() const;

  char **get_variable_names(int &num);

private:
  void available_styles(FILE * out, int flags);