pub struct PageFilesProperty {
pub id: Option<String>,
pub files: Vec<File>,
}
Expand description
https://developers.notion.com/reference/page-property-values#files
$.['*'].id
: An underlying identifier for the property.id
remains constant when the property name changes.$.['*'].type
: Always"files"
$.['*'].files
: An array of objects containing information about the files. If the file does not exist, an empty array will be returned.
Note: The ['*']
part represents the column name you set when creating the database.
Example files page property value
{
"Files & media": {
"id": "Q%7Dn%3E",
"type": "files",
"files": [
{
"name": "Project Alpha blueprint",
"type": "file",
"file": {
"url": "https://prod-files-secure.s3.us-west-2.amazonaws.com/daa95f86-2d56-4e18-be3b-16d81b31dc0d",
"expiry_time": "2024-04-04T10:45:54.308Z"
}
}
]
}
}
Fields§
§id: Option<String>
An underlying identifier for the property.
id
remains constant when the property name changes.
files: Vec<File>
An array of objects containing information about the files.
When creating, both the external path of the file and name
are required.
Implementations§
Source§impl PageFilesProperty
impl PageFilesProperty
Trait Implementations§
Source§impl Clone for PageFilesProperty
impl Clone for PageFilesProperty
Source§fn clone(&self) -> PageFilesProperty
fn clone(&self) -> PageFilesProperty
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for PageFilesProperty
impl Debug for PageFilesProperty
Source§impl Default for PageFilesProperty
impl Default for PageFilesProperty
Source§fn default() -> PageFilesProperty
fn default() -> PageFilesProperty
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PageFilesProperty
impl<'de> Deserialize<'de> for PageFilesProperty
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 Display for PageFilesProperty
impl Display for PageFilesProperty
Source§impl From<File> for PageFilesProperty
impl From<File> for PageFilesProperty
Source§impl<T> From<T> for PageFilesProperty
impl<T> From<T> for PageFilesProperty
Source§impl PartialEq for PageFilesProperty
impl PartialEq for PageFilesProperty
Source§impl Serialize for PageFilesProperty
impl Serialize for PageFilesProperty
impl Eq for PageFilesProperty
impl StructuralPartialEq for PageFilesProperty
Auto Trait Implementations§
impl Freeze for PageFilesProperty
impl RefUnwindSafe for PageFilesProperty
impl Send for PageFilesProperty
impl Sync for PageFilesProperty
impl Unpin for PageFilesProperty
impl UnwindSafe for PageFilesProperty
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