pub struct ExecuteRequest<'a> {
pub channel: Channel,
pub mode: Mode,
pub edition: Edition,
pub crate_type: CrateType,
pub tests: bool,
pub backtrace: bool,
pub code: Cow<'a, str>,
}Expand description
Request structure to execute Rust code on the playground.
Specifies compilation parameters and the source code to run.
Fields§
§channel: ChannelThe Rust release channel to use (stable, beta, nightly).
mode: ModeThe compilation mode: debug or release.
edition: EditionThe Rust edition to compile and run with (2015, 2018, 2021, 2024).
crate_type: CrateTypeThe crate type: binary or library.
tests: boolWhether to include test code during execution.
backtrace: boolWhether to enable backtrace output on runtime errors.
code: Cow<'a, str>The Rust source code to compile and execute.
Implementations§
Source§impl<'a> ExecuteRequest<'a>
impl<'a> ExecuteRequest<'a>
Sourcepub fn new(
channel: Channel,
mode: Mode,
edition: Edition,
crate_type: CrateType,
tests: bool,
backtrace: bool,
code: Cow<'a, str>,
) -> Self
pub fn new( channel: Channel, mode: Mode, edition: Edition, crate_type: CrateType, tests: bool, backtrace: bool, code: Cow<'a, str>, ) -> Self
Creates a new ExecuteRequest.
§Arguments
channel- Rust release channel.mode- Compilation mode (debug/release).edition- Rust edition.crate_type- Crate type (binary or library).tests- Whether to run test code.backtrace- Whether to enable backtraces.code- Source code to execute.
§Returns
An ExecuteRequest initialized with the given parameters.
Trait Implementations§
Source§impl<'a> Clone for ExecuteRequest<'a>
impl<'a> Clone for ExecuteRequest<'a>
Source§fn clone(&self) -> ExecuteRequest<'a>
fn clone(&self) -> ExecuteRequest<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for ExecuteRequest<'a>
impl<'a> Debug for ExecuteRequest<'a>
Source§impl<'a> Default for ExecuteRequest<'a>
impl<'a> Default for ExecuteRequest<'a>
Source§impl<'de, 'a> Deserialize<'de> for ExecuteRequest<'a>
impl<'de, 'a> Deserialize<'de> for ExecuteRequest<'a>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<'a> PartialEq for ExecuteRequest<'a>
impl<'a> PartialEq for ExecuteRequest<'a>
Source§impl<'a> Serialize for ExecuteRequest<'a>
impl<'a> Serialize for ExecuteRequest<'a>
impl<'a> Eq for ExecuteRequest<'a>
impl<'a> StructuralPartialEq for ExecuteRequest<'a>
Auto Trait Implementations§
impl<'a> Freeze for ExecuteRequest<'a>
impl<'a> RefUnwindSafe for ExecuteRequest<'a>
impl<'a> Send for ExecuteRequest<'a>
impl<'a> Sync for ExecuteRequest<'a>
impl<'a> Unpin for ExecuteRequest<'a>
impl<'a> UnwindSafe for ExecuteRequest<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneDebuggableStorage for Twhere
T: DebuggableStorage + Clone,
impl<T> CloneDebuggableStorage for Twhere
T: DebuggableStorage + Clone,
fn clone_storage(&self) -> Box<dyn CloneDebuggableStorage>
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> CloneableStorage for T
impl<T> CloneableStorage for T
fn clone_storage(&self) -> Box<dyn CloneableStorage>
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.