~/bend-docscommunity

text.bend checks

raw source on the hub · import bend-osdev-apparmor@0.1.0.0/text.bend as Text

bend-osdev-apparmor: byte-string helpers on List<&2, U32>, the form the package works on inside (profile text, names, paths). Public interfaces take Octets (bend-osdev-bytes) and convert once.

1 import
import Base

Types

type AaSplit source · line 176 · raw

Data

a name cut at its first "//": the part before it, and the rest after it

Definitions

def AaText.is_nil source · line 6 · raw

@xs:List<&2, U32> -> Bool

def AaText.append source · line 13 · raw

@xs:List<&2, U32> -> @ys:List<&2, U32> -> List<&2, U32>

def AaText.rev_onto source · line 20 · raw

@xs:List<&2, U32> -> @acc:List<&2, U32> -> List<&2, U32>

def AaText.rev source · line 27 · raw

@xs:List<&2, U32> -> List<&2, U32>

def AaText.len source · line 30 · raw

@xs:List<&2, U32> -> Nat

def AaText.eq source · line 37 · raw

@xs:List<&2, U32> -> @ys:List<&2, U32> -> Bool

def AaText.of_string source · line 49 · raw

@s:String -> List<&2, U32>

the codes of a string's characters

def AaText.to_string source · line 56 · raw

@xs:List<&2, U32> -> String

def AaText.is source · line 64 · raw

@xs:List<&2, U32> -> @s:String -> Bool

xs is exactly the string s

def AaText.starts source · line 76 · raw

@xs:List<&2, U32> -> @s:String -> Bool

xs begins with the string s

def AaText.prefix source · line 88 · raw

@xs:List<&2, U32> -> @ys:List<&2, U32> -> Bool

xs begins with ys

def AaText.drop source · line 99 · raw

@n:Nat -> @xs:List<&2, U32> -> List<&2, U32>

def AaText.has source · line 110 · raw

@xs:List<&2, U32> -> @+c:U32 -> Bool

def AaText.head source · line 117 · raw

@xs:List<&2, U32> -> U32

def AaText.last source · line 124 · raw

@xs:List<&2, U32> -> @l:U32 -> U32

def AaText.init source · line 132 · raw

@xs:List<&2, U32> -> List<&2, U32>

the list without its last element

def AaText.member source · line 144 · raw

@xs:List<&2, List<&2, U32>> -> @+x:List<&2, U32> -> Bool

x is one of the names xs

def AaText.one_of source · line 152 · raw

@ns:List<&2, String> -> @+s:List<&2, U32> -> Bool

s is one of the strings ns

def AaText.subset source · line 160 · raw

@xs:List<&2, List<&2, U32>> -> @+ys:List<&2, List<&2, U32>> -> Bool

every name of xs is one of ys

def AaText.tail source · line 168 · raw

@xs:List<&2, U32> -> List<&2, U32>

split at the first "//": the text before it, and the rest after it

def AaText.split2.go source · line 179 · raw

@xs:List<&2, U32> -> @+prev:Bool -> @+acc:List<&2, U32> -> AaSplit

def AaText.split2 source · line 187 · raw

@xs:List<&2, U32> -> AaSplit

def AaText.split2.opt source · line 191 · raw

@m:Maybe<&2, List<&2, U32>> -> Maybe<&2, AaSplit>

the split of a rest, if there is one

def AaText.lappend source · line 198 · raw

@xs:List<&2, List<&2, U32>> -> @ys:List<&2, List<&2, U32>> -> List<&2, List<&2, U32>>