◐ Shell
clean mode source ↗

rustpython_vm::obj::objstr::PyString - Rust

str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'."

impl PyString[src]

pub fn as_str(&self) -> &str[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

fn into(self) -> U[src]

Performs the conversion.

impl<T> IntoPyObject for T where
    T: PyValue
[src]

fn into_pyobject(
    Self,
    &VirtualMachine
) -> Result<Rc<PyObject<dyn PyObjectPayload + 'static>>, PyRef<PyBaseException>>
[src]

impl<T> PyObjectPayload for T where
    T: 'static + PyValue
[src]

fn as_any(&Self) -> &(dyn Any + 'static)[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

fn vzip(self) -> V