src/Level1/ExProcessM.cc
bool ExchProcM::getExch(const ParameterSet& pset, int idx,
                                                     string& exch, bool warn) const
  {
  exch = string("");                            // We don't know any exchange
  ParameterSet::const_iterator item;         // A pix into parameter list
  string Nidx = "";                             // Name addition per index
  if(idx >= 0) Nidx                             // If index exists then set up
    += string("(")+Gdec(idx)+string(")");       // the parameter name to append
  string pstate, pname=string("MutExch")+Nidx;	// Parameter name for process
  item = pset.seek(pname);			// Pix in pset for MutExch(i)
  if(item != pset.end())			// Retrieve the process (string)
    {
    (*item).parse(pname,exch,pstate);		//   Process as a string
    return true;				//   Return we were successful
    }
  if(warn)					// If we didnt find the exchange
    XPerror(20, pname, 1); 			// process definition, warn
  return false;
  }
/* This will be a parameter such as   MutExch(0)  (2) : (0,1,3,5) - Mutual exchange

   The string value defines the components (spins) involved in the exchange
   process. The function getExch will just get the process definition, it doesn't
   bother to parse it. The function parseExch will take the string from getExch
   and split it up into individual spins to be placed into the array Spins.
   Function getComps just oversees the process of getting the components so that 
   it looks like it is done in one step.

   The string value of Exch will be something akin to (0,1,3,5). We need to then
   to parse out the integer values on each side of , but lying between ().
   Also we must insure there are no repeats.                                    */
This will be a parameter such as   MutExch(0)  (2) : (0,1,3,5) - Mutual exchange
The string value defines the components (spins) involved in the exchange
process. The function getExch will just get the process definition, it doesn't
bother to parse it. The function parseExch will take the string from getExch
and split it up into individual spins to be placed into the array Spins.
Function getComps just oversees the process of getting the components so that
it looks like it is done in one step.

The string value of Exch will be something akin to (0,1,3,5). We need to then
to parse out the integer values on each side of , but lying between ().
Also we must insure there are no repeats.
This will be a parameter such as MutExch ( 0 ) ( 2 ) : ( 0 1 3 5 ) - Mutual exchange The string value defines the components ( spins ) involved in the exchange process . The function getExch will just get the process definition it doesn ' t bother to parse it . The function parseExch will take the string from getExch and split it up into individual spins to be placed into the array Spins . Function getComps just oversees the process of getting the components so that it looks like it is done in one step . The string value of Exch will be something akin to ( 0 1 3 5 ) . We need to then to parse out the integer values on each side of but lying between () . Also we must insure there are no repeats .
bool ExchProcM::getExch(const ParameterSet& pset, int idx,
                                                     string& exch, bool warn) const
  {
  exch = string("");                            
  ParameterSet::const_iterator item;         
  string Nidx = "";                             
  if(idx >= 0) Nidx                             
    += string("(")+Gdec(idx)+string(")");       
  string pstate, pname=string("MutExch")+Nidx;	
  item = pset.seek(pname);			
  if(item != pset.end())			
    {
    (*item).parse(pname,exch,pstate);		
    return true;				
    }
  if(warn)					
    XPerror(20, pname, 1); 			
  return false;
  }
bool ExchProcM :: getExch ( const ParameterSet & pset , int idx , string & exch , bool warn ) const { exch = string ( " " ) ; ParameterSet :: const_iterator item ; string Nidx = " " ; if ( idx >= 0 ) Nidx += string ( " " ) + Gdec ( idx ) + string ( " " ) ; string pstate , pname = string ( " " ) + Nidx ; item = pset . seek ( pname ) ; if ( item != pset . end ( ) ) { ( * item ) . parse ( pname , exch , pstate ) ; return true ; } if ( warn ) XPerror ( 20 , pname , 1 ) ; return false ; }
This will be a parameter such as   MutExch(0)  (2) : (0,1,3,5) - Mutual exchange
The string value defines the components (spins) involved in the exchange
process.
This will be a parameter such as MutExch ( 0 ) ( 2 ) : ( 0 1 3 5 ) - Mutual exchange The string value defines the components ( spins ) involved in the exchange process .
// We don't know any exchange // A pix into parameter list // Name addition per index // If index exists then set up // the parameter name to append // Parameter name for process // Pix in pset for MutExch(i) // Retrieve the process (string) //   Process as a string //   Return we were successful // If we didnt find the exchange // process definition, warn