FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
Fable.Python/src/stdlib/String.fs at main · fable-compiler/Fable.Python · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
fable-compiler
/
Fable.Python
Public
Notifications
You must be signed in to change notification settings
Fork
10
Star
144
Code
Issues
5
Pull requests
3
Discussions
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Discussions
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
Fable.Python
/
src
/
stdlib
/
String.fs
Copy path
More file actions
More file actions
Latest commit
History
History
History
73 lines (59 loc) · 2.62 KB
Breadcrumbs
Fable.Python
/
src
/
stdlib
/
String.fs
Copy path
File metadata and controls
73 lines (59 loc) · 2.62 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
/// Type bindings for Python string module:
https://docs.python.org/3/library/string.html
module
Fable.Python.String
open
System
open
Fable.
Core
// fsharplint:disable MemberNames
type
System.String
with
[<Emit
(
"
$0.format($1...)
"
)
>]
member
_.format
(
[<ParamArray>]
args
:
Object
[])
=
nativeOnly
/// Template class for $-based string substitution
[<Import
(
"
Template
"
,
"
string
"
)
>]
type
Template
(
template
:
string
)
=
/// The template string passed to the constructor
member
_.template
:
string
=
nativeOnly
/// Perform substitution, returning a new string
/// Raises KeyError if placeholders are missing from mapping
[<Emit
(
"
$0.substitute($1)
"
)
>]
member
_.substitute
(
mapping
:
obj
)
:
string
=
nativeOnly
/// Perform substitution using keyword arguments
[<Emit
(
"
$0.substitute(**$1)
"
)
>]
member
_.substituteKw
(
kwargs
:
obj
)
:
string
=
nativeOnly
/// Like substitute(), but returns original placeholder if missing
[<Emit
(
"
$0.safe_substitute($1)
"
)
>]
member
_.safe_substitute
(
mapping
:
obj
)
:
string
=
nativeOnly
/// Like substitute(), but returns original placeholder if missing (keyword args)
[<Emit
(
"
$0.safe_substitute(**$1)
"
)
>]
member
_.safe_substituteKw
(
kwargs
:
obj
)
:
string
=
nativeOnly
/// Returns False if the template has invalid placeholders
[<Emit
(
"
$0.is_valid()
"
)
>]
member
_.is_valid
()
:
bool
=
nativeOnly
/// Returns a list of valid identifiers in the template
[<Emit
(
"
$0.get_identifiers()
"
)
>]
member
_.get_identifiers
()
:
ResizeArray
<
string
>
=
nativeOnly
[<Erase>]
type
IExports
=
/// The concatenation of ascii_lowercase and ascii_uppercase
abstract
ascii_letters:
string
/// The lowercase letters 'abcdefghijklmnopqrstuvwxyz'
abstract
ascii_lowercase:
string
/// The uppercase letters 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
abstract
ascii_uppercase:
string
/// The string '0123456789'
abstract
digits:
string
/// The string '0123456789abcdefABCDEF'
abstract
hexdigits:
string
/// The string '01234567'
abstract
octdigits:
string
/// String of ASCII characters considered punctuation
abstract
punctuation:
string
/// String of ASCII characters considered printable
abstract
printable:
string
/// String containing all ASCII whitespace characters
abstract
whitespace:
string
/// Split the argument into words, capitalize each word, and join them
abstract
capwords:
s
:
string
->
string
/// Split the argument into words using sep, capitalize each word, and join them
abstract
capwords:
s
:
string
*
sep
:
string
->
string
/// Python string module
[<ImportAll
(
"
string
"
)
>]
let
pyString
:
IExports
=
nativeOnly
Back
|
FazBrowse Home
|
New Git URL