LCOV - code coverage report
Current view: top level - include/linesearches - LineSearch.h (source / functions) Hit Total Coverage
Test: idaholab/moose framework: 2bf808 Lines: 0 4 0.0 %
Date: 2025-07-17 01:28:37 Functions: 0 4 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : //* This file is part of the MOOSE framework
       2             : //* https://mooseframework.inl.gov
       3             : //*
       4             : //* All rights reserved, see COPYRIGHT for full restrictions
       5             : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
       6             : //*
       7             : //* Licensed under LGPL 2.1, please see LICENSE for details
       8             : //* https://www.gnu.org/licenses/lgpl-2.1.html
       9             : 
      10             : #pragma once
      11             : 
      12             : #include "MooseObject.h"
      13             : 
      14             : class FEProblem;
      15             : class LineSearch : public MooseObject
      16             : {
      17             : public:
      18             :   static InputParameters validParams();
      19             : 
      20             :   LineSearch(const InputParameters & parameters);
      21             : 
      22             :   /**
      23             :    * zeros the nonlinear iteration count
      24             :    */
      25             :   void zeroIts() { _nl_its = 0; }
      26             : 
      27             :   /**
      28             :    * read-only reference to number of non-linear iterations
      29             :    */
      30             :   size_t nlIts() const { return _nl_its; }
      31             : 
      32             :   /**
      33             :    * The method that actually implements the line-search
      34             :    */
      35           0 :   virtual void lineSearch() { mooseError("You must implement a line-search method."); }
      36             : 
      37           0 :   virtual void timestepSetup() {}
      38           0 :   virtual void customSetup(const ExecFlagType & /*exec_type*/) {}
      39           0 :   virtual void initialSetup() {}
      40             : 
      41             : protected:
      42             :   /// Reference to the finite element problem
      43             :   FEProblem & _fe_problem;
      44             : 
      45             :   /// number of non-linear iterations
      46             :   size_t _nl_its;
      47             : };

Generated by: LCOV version 1.14