Lines Matching refs:bytearray
1 /* PyByteArray (bytearray) implementation */
14 class bytearray "PyByteArrayObject *" "&PyByteArray_Type"
270 // result->ob_bytes is NULL if result is an empty bytearray:
365 PyErr_SetString(PyExc_IndexError, "bytearray index out of range");
384 PyErr_SetString(PyExc_IndexError, "bytearray index out of range");
423 "bytearray indices must be integers or slices, not %.200s",
467 tricky here because the bytearray object has already been
473 shrunk. Otherwise, the bytearray is restored in its previous
479 /* memmove() removed bytes, the bytearray object cannot be
542 "can't set bytearray slice from %.100s",
569 // nasty __index__ method that changes the size of the bytearray:
579 PyErr_SetString(PyExc_IndexError, "bytearray index out of range");
609 // has a nasty __index__ method that changes the size of the bytearray:
619 PyErr_SetString(PyExc_IndexError, "bytearray index out of range");
645 "bytearray indices must be integers or slices, not %.200s",
743 bytearray.__init__
879 "cannot convert '%.200s' object to bytearray",
951 "bytearray object is too large to make repr");
1022 "str() on a bytearray instance", 1)) {
1040 "Comparison between bytearray and string", 1))
1089 "deallocated bytearray object has exported buffers");
1138 bytearray.clear
1140 Remove all items from the bytearray.
1153 bytearray.copy
1203 bytearray.removeprefix as bytearray_removeprefix
1208 Return a bytearray with the given prefix string removed if present.
1210 If the bytearray starts with the prefix string, return
1211 bytearray[len(prefix):]. Otherwise, return a copy of the original
1212 bytearray.
1235 bytearray.removesuffix as bytearray_removesuffix
1240 Return a bytearray with the given suffix string removed if present.
1242 If the bytearray ends with the suffix string and that suffix is not
1243 empty, return bytearray[:-len(suffix)]. Otherwise, return a copy of
1244 the original bytearray.
1269 bytearray.translate
1356 /* Fix the size of the resulting bytearray */
1375 bytearray.maketrans
1381 Return a translation table useable for the bytes or bytearray translate method.
1398 bytearray.replace
1424 bytearray.split
1427 The delimiter according which to split the bytearray.
1434 Return a list of the sections in the bytearray, using sep as the delimiter.
1466 bytearray.partition
1471 Partition the bytearray into three parts using the given separator.
1473 This will search for the separator sep in the bytearray. If the separator is
1475 separator itself, and the part after it as new bytearray objects.
1478 original bytearray object and two empty bytearray objects.
1503 bytearray.rpartition
1508 Partition the bytearray into three parts using the given separator.
1510 This will search for the separator sep in the bytearray, starting at the end.
1512 separator, the separator itself, and the part after it as new bytearray
1515 If the separator is not found, returns a 3-tuple containing two empty bytearray
1516 objects and the copy of the original bytearray object.
1541 bytearray.rsplit = bytearray.split
1543 Return a list of the sections in the bytearray, using sep as the delimiter.
1545 Splitting is done starting at the end of the bytearray and working to the front.
1577 bytearray.reverse
1611 bytearray.insert
1619 Insert a single item into the bytearray before the given index.
1631 "cannot add more objects to bytearray");
1652 bytearray.append
1658 Append a single item to the end of the bytearray.
1669 "cannot add more objects to bytearray");
1681 bytearray.extend
1687 Append all the items from the iterator or sequence to the end of the bytearray.
1711 "can't extend bytearray with %.100s",
1787 bytearray.pop
1809 "pop from empty bytearray");
1831 bytearray.remove
1837 Remove the first occurrence of a value in the bytearray.
1849 PyErr_SetString(PyExc_ValueError, "value not found in bytearray");
1905 bytearray.strip
1923 bytearray.lstrip
1941 bytearray.rstrip
1959 bytearray.decode
1962 The encoding with which to decode the bytearray.
1970 Decode the bytearray using the codec registered for encoding.
1995 bytearray.join
2000 Concatenate any number of bytes/bytearray objects.
2002 The bytearray whose method is called is inserted in between each pair.
2004 The result is returned as a new bytearray object.
2015 bytearray.splitlines
2019 Return a list of the lines in the bytearray, breaking at line boundaries.
2037 bytearray.fromhex
2042 Create a bytearray object from a string of hexadecimal numbers.
2045 Example: bytearray.fromhex('B9 01EF') -> bytearray(b'\\xb9\\x01\\xef')
2060 bytearray.hex
2068 Create a string of hexadecimal numbers from a bytearray object.
2071 >>> value = bytearray([0xb9, 0x01, 0xef])
2118 bytearray.__reduce__ as bytearray_reduce
2131 bytearray.__reduce_ex__ as bytearray_reduce_ex
2147 bytearray.__sizeof__ as bytearray_sizeof
2149 Returns the size of the bytearray object in memory, in bytes.
2275 "bytearray(iterable_of_ints) -> bytearray\n\
2276 bytearray(string, encoding[, errors]) -> bytearray\n\
2277 bytearray(bytes_or_buffer) -> mutable copy of bytes_or_buffer\n\
2278 bytearray(int) -> bytes array of size given by the parameter initialized with null bytes\n\
2279 bytearray() -> empty bytes array\n\
2281 Construct a mutable bytearray object from:\n\
2293 "bytearray",