Currently the only way to create a new file is to upload one from the local disk. In some cases it would be useful to be able to create a blank file directly on the remote machine.
The function signature will be:
impl File {
//...
/// Create a blank file on the managed host.
fn create(&self, host: &mut Host) -> Result<()>;
//...
}
There are several places that this function will need to be added to:
file/mod.rs -> impl File
file/mod.rs -> trait FileTarget
file/ffi.rs -> pub extern "C" fn file_create(...)
- All implementation of
FileTarget in target/...
- Agent repo ->
api/file.rs
- Examples repo -> Projects for Rust, C and PHP
- Tests repo -> Test suites for Rust, C and PHP
Currently the only way to create a new file is to upload one from the local disk. In some cases it would be useful to be able to create a blank file directly on the remote machine.
The function signature will be:
There are several places that this function will need to be added to:
file/mod.rs-> impl Filefile/mod.rs-> trait FileTargetfile/ffi.rs-> pub extern "C" fn file_create(...)FileTargetintarget/...api/file.rs