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

Subversion Repositories thor

[/] [thor/] [trunk/] [FT64v5/] [software/] [CC64/] [source/] [txtStream.cpp] - Blame information for rev 48

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 48 robfinch
#include "stdafx.h"
2
#include <string.h>
3
#include "txtStream.h"
4
 
5
void txtoStream::printf(char *fmt, char *str)
6
{
7
  if (level==0)
8
    return;
9
  snprintf(buf, sizeof(buf), fmt, str);
10
        write(buf);
11
}
12
 
13
void txtoStream::printf(char *fmt, char *str, int n)
14
{
15
  if (level==0)
16
    return;
17
 snprintf(buf, sizeof(buf), fmt, str, n);
18
 write(buf);
19
}
20
 
21
void txtoStream::printf(char *fmt, char *str, char *str2)
22
{
23
  if (level==0)
24
    return;
25
 snprintf(buf, sizeof(buf), fmt, str, str2);
26
 write(buf);
27
}
28
 
29
void txtoStream::printf(char *fmt, char *str, char *str2, int n)
30
{
31
  if (level==0)
32
    return;
33
        snprintf(buf, sizeof(buf), fmt, str, str2, n);
34
        write(buf);
35
}
36
 
37
void txtoStream::printf(char *fmt, int n)
38
{
39
  if (level==0)
40
    return;
41
        snprintf(buf, sizeof(buf), fmt, n);
42
        write(buf);
43
}
44
 
45
void txtoStream::printf(char *fmt, __int64 n)
46
{
47
  if (level==0)
48
    return;
49
        snprintf(buf, sizeof(buf), fmt, n);
50
        write(buf);
51
}
52
 
53
void txtoStream::printf(char *fmt, int n, int m)
54
{
55
  if (level==0)
56
    return;
57
        snprintf(buf, sizeof(buf), fmt, n, m);
58
        write(buf);
59
}
60
 
61
void txtoStream::printf(char *fmt, int n, char *str)
62
{
63
  if (level==0)
64
    return;
65
        snprintf(buf, sizeof(buf), fmt, n, str);
66
        write(buf);
67
}
68
 
69
void txtoStream::puts(const char *str)
70
{
71
  if (level==0)
72
    return;
73
  while(*str) {
74
    putch(*str);
75
    str++;
76
  }
77
}
78
 

powered by: WebSVN 2.1.0

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