OpenCores
URL https://opencores.org/ocsvn/w11/w11/trunk

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.7/] [tools/] [src/] [librtools/] [RosPrintfS.hpp] - Blame information for rev 33

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 10 wfjm
// $Id: RosPrintfS.hpp 357 2011-01-31 08:00:13Z mueller $
2
//
3
// Copyright 2000-2011 by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4
//
5
// This program is free software; you may redistribute and/or modify it under
6
// the terms of the GNU General Public License as published by the Free
7
// Software Foundation, either version 2, or at your option any later version.
8
//
9
// This program is distributed in the hope that it will be useful, but
10
// WITHOUT ANY WARRANTY, without even the implied warranty of MERCHANTABILITY
11
// or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
12
// for complete details.
13
// 
14
// Revision History: 
15
// Date         Rev Version  Comment
16
// 2011-01-30   357   1.0    Adopted from CTBprintfS
17
// 2000-10-29     -   -      Last change on CTBprintfS
18
// ---------------------------------------------------------------------------
19
 
20
/*!
21
  \file
22
  \version $Id: RosPrintfS.hpp 357 2011-01-31 08:00:13Z mueller $
23
  \brief   Declaration of class RosPrintfS .
24
*/
25
 
26
#ifndef included_Retro_RosPrintfS
27
#define included_Retro_RosPrintfS 1
28
 
29
#include "RosPrintfBase.hpp"
30
 
31
namespace Retro {
32
 
33
  template <class T>
34
  class RosPrintfS : public RosPrintfBase {
35
    public:
36
                    RosPrintfS(T value, const char* form, int width, int prec);
37
 
38
      virtual void  ToStream(std::ostream& os) const;
39
 
40
    protected:
41
      T             fValue;                 //!< value to be printed
42
  };
43
 
44
  template <>
45
  void RosPrintfS<char>::ToStream(std::ostream& os) const;
46
  template <>
47
  void RosPrintfS<int>::ToStream(std::ostream& os) const;
48
  template <>
49
  void RosPrintfS<const char*>::ToStream(std::ostream& os) const;
50
  template <>
51
  void RosPrintfS<const void*>::ToStream(std::ostream& os) const;
52
 
53
} // end namespace Retro
54
 
55
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.