Loading [MathJax]/extensions/tex2jax.js
Thrill
0.1
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
+
Variables
a
b
c
d
f
g
i
k
l
m
n
p
r
s
t
v
w
x
+
Typedefs
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Enumerations
+
Enumerator
c
d
h
i
m
s
t
w
+
Classes
Class List
Class Index
Class Hierarchy
+
Class Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
~
+
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
Enumerations
+
Enumerator
a
b
c
d
f
m
n
o
p
r
s
t
v
w
+
Related Functions
o
p
s
+
Files
File List
+
File Members
+
All
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
r
s
t
u
w
+
Functions
b
c
d
f
g
h
j
l
m
o
p
r
s
t
u
w
Variables
Typedefs
+
Macros
_
a
b
c
d
f
h
i
l
m
o
p
s
t
u
Examples
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
pad.cpp
Go to the documentation of this file.
1
/*******************************************************************************
2
* tlx/string/pad.cpp
3
*
4
* Part of tlx - http://panthema.net/tlx
5
*
6
* Copyright (C) 2007-2017 Timo Bingmann <tb@panthema.net>
7
*
8
* All rights reserved. Published under the Boost Software License, Version 1.0
9
******************************************************************************/
10
11
#include <
tlx/string/pad.hpp
>
12
13
namespace
tlx
{
14
15
std::string
pad
(
const
std::string
& s,
size_t
len,
char
pad_char) {
16
std::string
str = s;
17
str.resize(len, pad_char);
18
return
str;
19
}
20
21
}
// namespace tlx
22
23
/******************************************************************************/
tlx::pad
std::string pad(const std::string &s, size_t len, char pad_char)
Truncate or pad string to exactly len characters.
Definition:
pad.cpp:15
tlx
Definition:
exclusive_scan.hpp:17
pad.hpp
thrill::mem::string
std::basic_string< char, std::char_traits< char >, Allocator< char > > string
string with Manager tracking
Definition:
allocator.hpp:220
extlib
tlx
tlx
string
pad.cpp
Generated on Mon Apr 6 2020 09:17:55 for Thrill by
1.8.13