pub struct CloudClient { /* private fields */ }Expand description
Cloud platform client for job submission and management
Implementations§
Source§impl CloudClient
impl CloudClient
Sourcepub fn new(config: CloudConfig) -> Self
pub fn new(config: CloudConfig) -> Self
Create a new cloud client
Sourcepub fn connect(&mut self) -> QuantRS2Result<()>
pub fn connect(&mut self) -> QuantRS2Result<()>
Connect to the cloud platform and authenticate
Sourcepub fn list_devices(&self) -> &[DeviceInfo]
pub fn list_devices(&self) -> &[DeviceInfo]
Get list of available devices
Sourcepub fn get_device(&self, name: &str) -> Option<&DeviceInfo>
pub fn get_device(&self, name: &str) -> Option<&DeviceInfo>
Get device by name
Sourcepub fn select_best_device(
&self,
min_qubits: usize,
prefer_qpu: bool,
) -> Option<&DeviceInfo>
pub fn select_best_device( &self, min_qubits: usize, prefer_qpu: bool, ) -> Option<&DeviceInfo>
Get best available device based on requirements
Sourcepub fn submit_job(
&self,
device_name: &str,
circuit: &QuantumCircuit,
shots: Option<usize>,
) -> QuantRS2Result<QuantumJob>
pub fn submit_job( &self, device_name: &str, circuit: &QuantumCircuit, shots: Option<usize>, ) -> QuantRS2Result<QuantumJob>
Submit a quantum job
Sourcepub fn check_job_status(&self, job_id: &str) -> QuantRS2Result<JobStatus>
pub fn check_job_status(&self, job_id: &str) -> QuantRS2Result<JobStatus>
Check job status
Sourcepub fn wait_for_job(
&self,
job_id: &str,
timeout: Option<Duration>,
) -> QuantRS2Result<QuantumJob>
pub fn wait_for_job( &self, job_id: &str, timeout: Option<Duration>, ) -> QuantRS2Result<QuantumJob>
Wait for job completion
Sourcepub fn get_job_result(&self, job_id: &str) -> QuantRS2Result<JobResult>
pub fn get_job_result(&self, job_id: &str) -> QuantRS2Result<JobResult>
Get job result
Sourcepub fn cancel_job(&self, job_id: &str) -> QuantRS2Result<()>
pub fn cancel_job(&self, job_id: &str) -> QuantRS2Result<()>
Cancel a job
Sourcepub fn list_jobs(&self, limit: Option<usize>) -> QuantRS2Result<Vec<QuantumJob>>
pub fn list_jobs(&self, limit: Option<usize>) -> QuantRS2Result<Vec<QuantumJob>>
List user’s jobs
Auto Trait Implementations§
impl Freeze for CloudClient
impl RefUnwindSafe for CloudClient
impl Send for CloudClient
impl Sync for CloudClient
impl Unpin for CloudClient
impl UnwindSafe for CloudClient
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.