Ignore:
Timestamp:
Nov 5, 2010, 3:45:55 PM (14 years ago)
Author:
garnier
Message:

update ti head

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/global/management/src/G4DataVector.cc

    r1337 r1340  
    2525//
    2626//
    27 // $Id: G4DataVector.cc,v 1.9 2007/11/13 17:35:06 gcosmo Exp $
    28 // GEANT4 tag $Name: geant4-09-04-beta-01 $
     27// $Id: G4DataVector.cc,v 1.12 2010/11/01 13:55:53 gcosmo Exp $
     28// GEANT4 tag $Name: global-V09-03-22 $
    2929//
    3030//
     
    8888{
    8989  clear();
    90   size_t sizeV=0;
     90  G4int sizeV=0;
    9191 
    9292  // retrieve in ascii mode
     
    9696    fIn >> sizeV;
    9797    if (fIn.fail())  { return false; }
    98    
     98    if (sizeV<=0)
     99    {
     100#ifdef G4VERBOSE 
     101      G4cerr << "G4DataVector::Retrieve():";
     102      G4cerr << " Invalid vector size: " << sizeV << G4endl;
     103#endif
     104      return false;
     105    }
     106
    99107    reserve(sizeV);
    100     for(size_t i = 0; i < sizeV ; i++)
     108    for(G4int i = 0; i < sizeV ; i++)
    101109    {
    102110      G4double vData=0.0;
     
    120128
    121129  reserve(sizeV);
    122   for(size_t i = 0; i < sizeV; i++)
     130  for(G4int i = 0; i < sizeV; i++)
    123131  {
    124132    push_back(value[i]);
     
    130138std::ostream& operator<<(std::ostream& out, const G4DataVector& pv)
    131139{
    132   out << pv.size() << G4endl;
     140  out << pv.size() << std::setprecision(12) << G4endl;
    133141  for(size_t i = 0; i < pv.size(); i++)
    134142  {
    135     out << std::setprecision(12) << pv[i] << G4endl;
     143    out << pv[i] << G4endl;
    136144  }
     145  out << std::setprecision(6);
    137146
    138147  return out;
Note: See TracChangeset for help on using the changeset viewer.