pub struct AddFile {
pub external_id: Option<String>,
pub name: String,
pub directory: Option<String>,
pub source: Option<String>,
pub mime_type: Option<String>,
pub metadata: Option<HashMap<String, String>>,
pub asset_ids: Option<Vec<i64>>,
pub data_set_id: Option<i64>,
pub source_created_time: Option<i64>,
pub source_modified_time: Option<i64>,
pub security_categories: Option<Vec<i64>>,
pub labels: Option<Vec<CogniteExternalId>>,
}Expand description
Create a new file.
Fields§
§external_id: Option<String>File external ID. Must be unique accross all files in the project.
name: StringFile name.
directory: Option<String>Directory containing the file. Must be an absolute, unix-style path.
source: Option<String>Source of the file.
mime_type: Option<String>File mime type, e.g. application/pdf.
metadata: Option<HashMap<String, String>>Custom, application specific metadata. String key -> String value. Limits: Maximum length of key is 128 bytes, value 10240 bytes, up to 256 key-value pairs, of total size at most 10240.
asset_ids: Option<Vec<i64>>List of assets the file is tied to.
data_set_id: Option<i64>Data set the file belongs to.
source_created_time: Option<i64>Timestamp in milliseconds since epoch when this file was created in the source system.
source_modified_time: Option<i64>Timestamp in milliseconds since epoch when this file was last modified in the source system.
security_categories: Option<Vec<i64>>The required security categories to access this file.
labels: Option<Vec<CogniteExternalId>>List of labels associated with this file.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for AddFile
impl<'de> Deserialize<'de> for AddFile
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 EqIdentity for AddFile
impl EqIdentity for AddFile
Source§impl From<FileMetadata> for AddFile
impl From<FileMetadata> for AddFile
Source§fn from(file: FileMetadata) -> AddFile
fn from(file: FileMetadata) -> AddFile
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for AddFile
impl RefUnwindSafe for AddFile
impl Send for AddFile
impl Sync for AddFile
impl Unpin for AddFile
impl UnwindSafe for AddFile
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