pub trait TypedStringExt {
// Required methods
fn typed_new_string(
&self,
s: impl AsRef<str>,
) -> LocalObject<'_, JavaString>;
fn typed_get_string(&self, s: &Object<impl StrongRef, JavaString>) -> String;
}Expand description
Extension methods for typed string maintenance.
Required Methods§
Sourcefn typed_new_string(&self, s: impl AsRef<str>) -> LocalObject<'_, JavaString>
fn typed_new_string(&self, s: impl AsRef<str>) -> LocalObject<'_, JavaString>
Creates a new string from the given string.
Sourcefn typed_get_string(&self, s: &Object<impl StrongRef, JavaString>) -> String
fn typed_get_string(&self, s: &Object<impl StrongRef, JavaString>) -> String
Returns the string slice of the given string object.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.