Home
last modified time | relevance | path

Searched refs:Resource (Results 1 – 25 of 102) sorted by relevance

12345

/wasmtime-44.0.1/crates/wasi/src/p2/host/
H A Dtcp.rs8 use wasmtime::component::Resource;
19 this: Resource<TcpSocket>, in start_bind()
20 network: Resource<Network>, in start_bind()
45 this: Resource<TcpSocket>, in start_connect()
46 network: Resource<Network>, in start_connect()
69 this: Resource<TcpSocket>, in finish_connect()
70 ) -> SocketResult<(Resource<DynInputStream>, Resource<DynOutputStream>)> { in finish_connect()
98 this: Resource<TcpSocket>, in accept()
100 Resource<TcpSocket>, in accept()
101 Resource<DynInputStream>, in accept()
[all …]
H A Dio.rs7 use wasmtime::component::{Resource, ResourceTable};
43 stream: Resource<OutputStream>, in blocking_write_and_flush()
53 stream: Resource<OutputStream>, in blocking_write_zeroes_and_flush()
63 stream: Resource<OutputStream>, in subscribe()
64 ) -> wasmtime::Result<Resource<Pollable>> { in subscribe()
75 Resource::new_borrow(stream.rep()), in flush()
87 dst: Resource<OutputStream>, in splice()
88 src: Resource<InputStream>, in splice()
96 dst: Resource<OutputStream>, in blocking_splice()
97 src: Resource<InputStream>, in blocking_splice()
[all …]
H A Dudp.rs14 use wasmtime::component::Resource;
23 this: Resource<udp::UdpSocket>, in start_bind()
24 network: Resource<Network>, in start_bind()
45 this: Resource<udp::UdpSocket>, in stream()
109 this: Resource<udp::UdpSocket>, in address_family()
122 this: Resource<udp::UdpSocket>, in set_unicast_hop_limit()
137 this: Resource<udp::UdpSocket>, in set_receive_buffer_size()
156 fn subscribe(&mut self, this: Resource<UdpSocket>) -> wasmtime::Result<Resource<DynPollable>> { in subscribe()
406 use wasmtime::component::Resource;
436 self_: Resource<UdpSocket>, in start_bind()
[all …]
H A Dfilesystem.rs10 use wasmtime::component::Resource;
28 err: Resource<wasmtime::Error>, in filesystem_error_code()
45 fd: Resource<types::Descriptor>, in advise()
63 fd: Resource<types::Descriptor>, in get_flags()
72 fd: Resource<types::Descriptor>, in get_type()
81 fd: Resource<types::Descriptor>, in set_size()
91 fd: Resource<types::Descriptor>, in set_times()
104 fd: Resource<types::Descriptor>, in read()
141 fd: Resource<types::Descriptor>, in write()
162 fd: Resource<types::Descriptor>, in read_directory()
[all …]
/wasmtime-44.0.1/crates/debugger/src/host/
H A Dapi.rs307 d: Resource<Debuggee>, in get_module()
319 d: Resource<Debuggee>, in get_memory()
334 d: Resource<Debuggee>, in get_global()
391 async fn clone(&mut self, self_: Resource<Instance>) -> Result<Resource<Instance>> { in clone()
435 async fn clone(&mut self, self_: Resource<Module>) -> Result<Resource<Module>> { in clone()
620 async fn clone(&mut self, self_: Resource<Memory>) -> Result<Resource<Memory>> { in clone()
662 async fn clone(&mut self, self_: Resource<Global>) -> Result<Resource<Global>> { in clone()
710 async fn clone(&mut self, self_: Resource<Table>) -> Result<Resource<Table>> { in clone()
746 async fn clone(&mut self, self_: Resource<Func>) -> Result<Resource<Func>> { in clone()
796 tag: Resource<Tag>, in make()
[all …]
/wasmtime-44.0.1/crates/wasi-http/src/p2/
H A Dtypes_impl.rs14 use wasmtime::component::Resource;
100 fields: Resource<FieldMap>, in set()
134 fields: Resource<FieldMap>, in append()
160 fn clone(&mut self, fields: Resource<FieldMap>) -> wasmtime::Result<Resource<FieldMap>> { in clone()
224 headers: Resource<FieldMap>, in new()
416 _headers: Resource<FieldMap>, in send_informational()
518 id: Resource<HostIncomingBody>, in stream()
533 id: Resource<HostIncomingBody>, in finish()
549 headers: Resource<FieldMap>, in new()
688 id: Resource<HostOutgoingBody>, in write()
[all …]
/wasmtime-44.0.1/crates/wasi-http/src/p3/host/
H A Dtypes.rs24 fields: &Resource<Fields>, in get_fields()
33 fields: &Resource<Fields>, in get_fields_mut()
59 req: &Resource<Request>, in get_request()
66 req: &Resource<Request>, in get_request_mut()
75 res: &Resource<Response>, in get_response()
82 res: &Resource<Response>, in get_response_mut()
297 fn clone(&mut self, fields: Resource<Fields>) -> wasmtime::Result<Resource<Fields>> { in clone()
359 req: Resource<Request>, in consume_body()
393 req: Resource<Request>, in set_method()
413 req: Resource<Request>, in set_path_with_query()
[all …]
/wasmtime-44.0.1/crates/wasi-io/src/
H A Dimpls.rs11 use wasmtime::component::{Resource, ResourceTable};
136 fn subscribe(&mut self, stream: Resource<DynOutputStream>) -> Result<Resource<DynPollable>> { in subscribe()
142 stream: Resource<DynOutputStream>, in blocking_write_and_flush()
158 stream: Resource<DynOutputStream>, in blocking_write_zeroes_and_flush()
192 dest: Resource<DynOutputStream>, in splice()
193 src: Resource<DynInputStream>, in splice()
221 dest: Resource<DynOutputStream>, in blocking_splice()
222 src: Resource<DynInputStream>, in blocking_splice()
264 stream: Resource<DynInputStream>, in blocking_read()
281 stream: Resource<DynInputStream>, in blocking_skip()
[all …]
/wasmtime-44.0.1/crates/wasi-tls/src/p2/
H A Dhost.rs2 use wasmtime::component::Resource;
28 input: Resource<DynInputStream>, in new()
29 output: Resource<DynOutputStream>, in new()
30 ) -> wasmtime::Result<Resource<HostClientHandshake>> { in new()
46 this: Resource<HostClientHandshake>, in finish()
92 this: Resource<HostFutureClientStreams>, in subscribe()
93 ) -> wasmtime::Result<Resource<DynPollable>> { in subscribe()
99 this: Resource<HostFutureClientStreams>, in get()
106 Resource<DynInputStream>, in get()
107 Resource<DynOutputStream>, in get()
[all …]
/wasmtime-44.0.1/crates/wasi/src/p3/sockets/host/types/
H A Dudp.rs9 use wasmtime::component::{Accessor, Resource, ResourceTable};
14 socket: &'a Resource<UdpSocket>, in get_socket()
24 socket: &'a Resource<UdpSocket>, in get_socket_mut()
35 socket: Resource<UdpSocket>, in send()
59 socket: Resource<UdpSocket>, in receive()
71 socket: Resource<UdpSocket>, in bind()
86 socket: Resource<UdpSocket>, in connect()
124 socket: Resource<UdpSocket>, in get_address_family()
137 socket: Resource<UdpSocket>, in set_unicast_hop_limit()
152 socket: Resource<UdpSocket>, in set_receive_buffer_size()
[all …]
H A Dtcp.rs28 socket: &'a Resource<TcpSocket>, in get_socket()
38 socket: &'a Resource<TcpSocket>, in get_socket_mut()
57 type Item = Resource<TcpSocket>;
248 socket: Resource<TcpSocket>, in connect()
273 socket: Resource<TcpSocket>, in listen()
296 socket: Resource<TcpSocket>, in send()
321 socket: Resource<TcpSocket>, in receive()
349 socket: Resource<TcpSocket>, in bind()
390 socket: Resource<TcpSocket>, in get_address_family()
398 socket: Resource<TcpSocket>, in set_listen_backlog_size()
[all …]
/wasmtime-44.0.1/crates/wasmtime/src/runtime/component/resources/
H A Dhost_static.rs154 impl<T> Resource<T> implementation
162 pub fn new_own(rep: u32) -> Resource<T> { in new_own()
163 Resource(HostResource::new_own(rep, ())) in new_own()
173 pub fn new_borrow(rep: u32) -> Resource<T> { in new_borrow()
174 Resource(HostResource::new_borrow(rep, ())) in new_borrow()
218 unsafe impl<T: 'static> ComponentType for Resource<T> { implementation
227 unsafe impl<T: 'static> Lower for Resource<T> { implementation
247 unsafe impl<T: 'static> Lift for Resource<T> { implementation
254 Ok(Resource(host_resource)) in linear_lift_from_flat()
263 Ok(Resource(host_resource)) in linear_lift_from_memory()
[all …]
/wasmtime-44.0.1/crates/wasi/src/p2/host/filesystem/
H A Dsync.rs7 use wasmtime::component::Resource;
16 err: Resource<streams::Error>, in filesystem_error_code()
25 fd: Resource<sync_filesystem::Descriptor>, in advise()
41 fd: Resource<sync_filesystem::Descriptor>, in get_flags()
48 fd: Resource<sync_filesystem::Descriptor>, in get_type()
55 fd: Resource<sync_filesystem::Descriptor>, in set_size()
63 fd: Resource<sync_filesystem::Descriptor>, in set_times()
74 fd: Resource<sync_filesystem::Descriptor>, in read()
83 fd: Resource<sync_filesystem::Descriptor>, in write()
92 fd: Resource<sync_filesystem::Descriptor>, in read_directory()
[all …]
/wasmtime-44.0.1/crates/component-macro/tests/expanded/
H A Dresources-import.rs8 fn new(&mut self) -> wasmtime::component::Resource<WorldResource>; in new()
13 rep: wasmtime::component::Resource<WorldResource>, in drop()
28 rep: wasmtime::component::Resource<WorldResource>, in drop()
514 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
551 wasmtime::component::Resource<Bar>, in list_own_arg()
557 wasmtime::component::Resource<Bar>, in list_borrow_arg()
563 wasmtime::component::Resource<Bar>, in list_result()
576 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
651 wasmtime::component::Resource<Bar>, in list_result()
955 rep: wasmtime::component::Resource<A>, in drop()
[all …]
H A Dresources-import_async.rs11 Output = wasmtime::component::Resource<WorldResource>, in new()
15 self_: wasmtime::component::Resource<WorldResource>, in foo()
20 rep: wasmtime::component::Resource<WorldResource>, in drop()
27 Output = wasmtime::component::Resource<WorldResource>, in new()
33 self_: wasmtime::component::Resource<WorldResource>, in foo()
42 rep: wasmtime::component::Resource<WorldResource>, in drop()
568 x: wasmtime::component::Resource<Bar>, in bar_own_arg()
572 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
656 x: wasmtime::component::Resource<Bar>, in bar_own_arg()
662 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
[all …]
H A Dresources-import_tracing_async.rs11 Output = wasmtime::component::Resource<WorldResource>, in new()
15 self_: wasmtime::component::Resource<WorldResource>, in foo()
20 rep: wasmtime::component::Resource<WorldResource>, in drop()
27 Output = wasmtime::component::Resource<WorldResource>, in new()
33 self_: wasmtime::component::Resource<WorldResource>, in foo()
42 rep: wasmtime::component::Resource<WorldResource>, in drop()
631 x: wasmtime::component::Resource<Bar>, in bar_own_arg()
635 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
684 wasmtime::component::Resource<Bar>, in list_own_arg()
719 x: wasmtime::component::Resource<Bar>, in bar_own_arg()
[all …]
H A Dresources-import_concurrent.rs5 rep: wasmtime::component::Resource<WorldResource>, in drop()
12 Output = wasmtime::component::Resource<WorldResource>, in new()
16 self_: wasmtime::component::Resource<WorldResource>, in foo()
134 Output = wasmtime::component::Resource<WorldResource>, in some_world_func()
392 rep: wasmtime::component::Resource<Bar>, in drop()
488 x: wasmtime::component::Resource<Bar>, in bar_own_arg()
492 x: wasmtime::component::Resource<Bar>, in bar_borrow_arg()
541 wasmtime::component::Resource<Bar>, in list_own_arg()
547 wasmtime::component::Resource<Bar>, in list_borrow_arg()
554 wasmtime::component::Resource<Bar>, in list_result()
[all …]
/wasmtime-44.0.1/examples/min-platform/embedding/src/
H A Dwasi.rs484 ) -> Result<Resource<DynPollable>> { in subscribe_duration()
490 ) -> Result<Resource<DynPollable>> { in subscribe_instant()
640 _: Resource<wasi::filesystem::types::Descriptor>, in read_via_stream()
647 _: Resource<wasi::filesystem::types::Descriptor>, in write_via_stream()
654 _: Resource<wasi::filesystem::types::Descriptor>, in append_via_stream()
660 _: Resource<wasi::filesystem::types::Descriptor>, in advise()
669 _: Resource<wasi::filesystem::types::Descriptor>, in sync_data()
675 _: Resource<wasi::filesystem::types::Descriptor>, in get_flags()
682 _: Resource<wasi::filesystem::types::Descriptor>, in get_type()
689 _: Resource<wasi::filesystem::types::Descriptor>, in set_size()
[all …]
/wasmtime-44.0.1/crates/wasi/src/p2/
H A Dstdio.rs6 use wasmtime::component::Resource;
16 fn get_stdin(&mut self) -> Result<Resource<streams::DynInputStream>, wasmtime::Error> { in get_stdin()
23 fn get_stdout(&mut self) -> Result<Resource<streams::DynOutputStream>, wasmtime::Error> { in get_stdout()
30 fn get_stderr(&mut self) -> Result<Resource<streams::DynOutputStream>, wasmtime::Error> { in get_stderr()
41 fn drop(&mut self, r: Resource<TerminalInput>) -> wasmtime::Result<()> { in drop()
48 fn drop(&mut self, r: Resource<TerminalOutput>) -> wasmtime::Result<()> { in drop()
54 fn get_terminal_stdin(&mut self) -> wasmtime::Result<Option<Resource<TerminalInput>>> { in get_terminal_stdin()
64 fn get_terminal_stdout(&mut self) -> wasmtime::Result<Option<Resource<TerminalOutput>>> { in get_terminal_stdout()
74 fn get_terminal_stderr(&mut self) -> wasmtime::Result<Option<Resource<TerminalOutput>>> { in get_terminal_stderr()
H A Dpoll.rs5 use wasmtime::component::{Resource, ResourceTable};
8 fn poll(&mut self, pollables: Vec<Resource<DynPollable>>) -> Result<Vec<u32>> { in poll()
14 fn ready(&mut self, pollable: Resource<DynPollable>) -> Result<bool> { in ready()
17 fn block(&mut self, pollable: Resource<DynPollable>) -> Result<()> { in block()
20 fn drop(&mut self, pollable: Resource<DynPollable>) -> Result<()> { in drop()
/wasmtime-44.0.1/tests/all/component_model/
H A Dresources.rs407 let t = Resource::new_own(100); in drop_host_twice()
481 let t1 = Resource::new_own(100); in manually_destroy()
594 i.get_typed_func::<(Resource<MyType>,), (Resource<MyType>,)>(&mut store, "a")?; in dynamic_val()
598 let t1 = Resource::new_own(100); in dynamic_val()
605 Val::Resource(resource) => { in dynamic_val()
624 Val::Resource(resource) => { in dynamic_val()
653 Val::Resource(resource) => { in dynamic_val()
870 let f = i.get_typed_func::<(&Resource<MyType>,), (Resource<MyType>,)>(&mut store, "f")?; in borrows_must_be_dropped_before_lifting()
1076 let f = i.get_typed_func::<(&Resource<MyType>, &Resource<MyType>), ()>(&mut store, "f")?; in pass_moved_resource()
1491 |_cx, (r1, r2): (Resource<MyType>, Resource<MyType>)| { in guest_different_host_same()
[all …]
/wasmtime-44.0.1/crates/wasi-nn/src/
H A Dwit.rs22 use wasmtime::component::{HasData, Resource, ResourceTable};
175 ) -> wasmtime::Result<Result<Resource<Graph>, Resource<Error>>> { in load()
200 ) -> wasmtime::Result<Result<Resource<Graph>, Resource<Error>>> { in load_by_name()
221 graph: Resource<Graph>, in init_execution_context()
222 ) -> wasmtime::Result<Result<Resource<GraphExecutionContext>, Resource<Error>>> { in init_execution_context()
237 fn drop(&mut self, graph: Resource<Graph>) -> wasmtime::Result<()> { in drop()
246 exec_context: Resource<GraphExecutionContext>, in compute()
248 ) -> wasmtime::Result<Result<Vec<NamedTensor>, Resource<Error>>> { in compute()
293 ) -> wasmtime::Result<Resource<Tensor>> { in new()
318 fn drop(&mut self, tensor: Resource<Tensor>) -> wasmtime::Result<()> { in drop()
[all …]
/wasmtime-44.0.1/crates/wasi/src/p3/filesystem/
H A Dhost.rs28 fd: &'a Resource<Descriptor>, in get_descriptor()
38 fd: &'a Resource<Descriptor>, in get_file()
46 fd: &'a Resource<Descriptor>, in get_dir()
58 a: &Resource<Descriptor>, in get_dir_pair()
59 b: &Resource<Descriptor>, in get_dir_pair()
87 a: &Resource<Descriptor>, in get_dir_pair()
88 b: &Resource<Descriptor>, in get_dir_pair()
499 fd: Resource<Descriptor>, in read_via_stream()
530 fd: Resource<Descriptor>, in write_via_stream()
558 fd: Resource<Descriptor>, in append_via_stream()
[all …]
/wasmtime-44.0.1/crates/component-macro/tests/
H A Dcodegen.rs54 use wasmtime::component::Resource;
94 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
100 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
108 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
114 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
122 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
128 fn drop(&mut self, _: Resource<MyA>) -> Result<()> { in drop()
428 use wasmtime::component::Resource;
489 fn new(&mut self) -> Resource<R> { in new()
492 fn foo(&mut self, _: Resource<R>) {} in foo()
[all …]
/wasmtime-44.0.1/crates/wasi-keyvalue/src/
H A Dlib.rs84 use wasmtime::component::{HasData, Resource, ResourceTable, ResourceTableError};
164 fn open(&mut self, identifier: String) -> Result<Resource<Bucket>, Error> { in open()
183 fn get(&mut self, bucket: Resource<Bucket>, key: String) -> Result<Option<Vec<u8>>, Error> { in get()
194 fn delete(&mut self, bucket: Resource<Bucket>, key: String) -> Result<(), Error> { in delete()
200 fn exists(&mut self, bucket: Resource<Bucket>, key: String) -> Result<bool, Error> { in exists()
207 bucket: Resource<Bucket>, in list_keys()
220 fn drop(&mut self, bucket: Resource<Bucket>) -> Result<()> { in drop()
229 bucket: Resource<Bucket>, in increment()
251 bucket: Resource<Bucket>, in get_many()
268 bucket: Resource<Bucket>, in set_many()
[all …]

12345