Struct DiscordIPCSync
Source pub struct DiscordIPCSync { }
examples/indefinite-sync.rs (
line 4)
3fn main() {
4 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
5
6 client.run().unwrap();
7 client.set_activity("this runs", "forever").unwrap();
8 client.wait().unwrap();
9}
More examples
Hide additional examples
examples/timed-sync.rs (
line 6)
5fn main() {
6 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
7
8 client.run().unwrap();
10
11 client.set_activity("this runs", "for ten seconds").unwrap();
12 sleep(Duration::from_secs(5));
13 client.set_activity("believe it", "or not").unwrap();
14 sleep(Duration::from_secs(5));
15}
examples/indefinite-sync.rs (
line 6)
3fn main() {
4 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
5
6 client.run().unwrap();
7 client.set_activity("this runs", "forever").unwrap();
8 client.wait().unwrap();
9}
More examples
Hide additional examples
examples/timed-sync.rs (
line 9)
5fn main() {
6 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
7
8 client.run().unwrap();
10
11 client.set_activity("this runs", "for ten seconds").unwrap();
12 sleep(Duration::from_secs(5));
13 client.set_activity("believe it", "or not").unwrap();
14 sleep(Duration::from_secs(5));
15}
examples/indefinite-sync.rs (
line 8)
3fn main() {
4 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
5
6 client.run().unwrap();
7 client.set_activity("this runs", "forever").unwrap();
8 client.wait().unwrap();
9}
examples/indefinite-sync.rs (
line 7)
3fn main() {
4 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
5
6 client.run().unwrap();
7 client.set_activity("this runs", "forever").unwrap();
8 client.wait().unwrap();
9}
More examples
Hide additional examples
5fn main() {
6 let mut client = DiscordIPCSync::new("1463450870480900160").unwrap();
7
8 client.run().unwrap();
10
11 client.set_activity("this runs", "for ten seconds").unwrap();
12 sleep(Duration::from_secs(5));
13 client.set_activity("believe it", "or not").unwrap();
14 sleep(Duration::from_secs(5));
15}
Formats the value using the given formatter.
Read more
Executes the destructor for this type.
Read more
Immutably borrows from an owned value.
Read more
Mutably borrows from an owned value.
Read more
Returns the argument unchanged.
Calls U::from(self).
That is, this conversion is whatever the implementation of
From<T> for U chooses to do.
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.