Molybden API
Loading...
Searching...
No Matches
molybden::File Struct Reference

The file data. More...

#include <upload_data.hpp>

Public Attributes

std::string name
 The file name including extension.
 
std::string content_type
 The content type determined by the file extension.
 
std::shared_ptr< FileValuevalue
 The file value.
 

Detailed Description

The file data.

Depending on how the request was constructed can contain the path to a file, or the bytes representing a file.

Contains the path when the value is taken from an <input type="file"> element of the submitted form. May contain bytes in case the request in the "multipart/form-data" format was constructed manually in a JavaScript code.

Member Data Documentation

◆ content_type

std::string molybden::File::content_type

The content type determined by the file extension.

It will be application/octet-stream when there is no MIME type associated with the file extension. The file extension is part of the file name.


The documentation for this struct was generated from the following file: