pub enum MediaType {
Show 25 variants
Plain(String),
Html(String),
Latex(String),
Javascript(String),
Markdown(String),
Svg(String),
Png(String),
Jpeg(String),
Gif(String),
Json(JsonObject),
GeoJson(JsonObject),
DataTable(Box<TabularDataResource>),
Plotly(JsonObject),
WidgetView(JsonObject),
WidgetState(JsonObject),
VegaLiteV2(JsonObject),
VegaLiteV3(JsonObject),
VegaLiteV4(JsonObject),
VegaLiteV5(JsonObject),
VegaLiteV6(JsonObject),
VegaV3(JsonObject),
VegaV4(JsonObject),
VegaV5(JsonObject),
Vdom(JsonObject),
Other((String, Value)),
}
Expand description
An enumeration representing various Media types, otherwise known as MIME (Multipurpose Internet Mail Extensions) types.
These types are used to indicate the nature of the data in a rich content message such as DisplayData
, UpdateDisplayData
, and ExecuteResult
.
Variants§
Plain(String)
Plain text, typically representing unformatted text. (e.g. Python’s _repr_
or _repr_pretty_
methods).
Html(String)
HTML, (as displayed via Python’s _repr_html_
method).
Latex(String)
LaTeX, (as displayed using Python’s _repr_latex_
method).
Javascript(String)
Raw JavaScript code.
Markdown(String)
Markdown text, (as displayed using Python’s _repr_markdown_
method).
Svg(String)
SVG image text, (as displayed using Python’s _repr_svg_
method).
Png(String)
PNG image data.
Jpeg(String)
JPEG image data.
Gif(String)
GIF image data.
Json(JsonObject)
Raw JSON Object
GeoJson(JsonObject)
GeoJSON data, a format for encoding a variety of geographic data structures.
DataTable(Box<TabularDataResource>)
Data table in JSON format, requires both a data
and schema
.
Example: {data: [{'ghost': true, 'says': "boo"}], schema: {fields: [{name: 'ghost', type: 'boolean'}, {name: 'says', type: 'string'}]}}
.
Plotly(JsonObject)
Plotly JSON Schema for for rendering graphs and charts.
WidgetView(JsonObject)
Jupyter/IPython widget view in JSON format.
WidgetState(JsonObject)
Jupyter/IPython widget state in JSON format.
VegaLiteV2(JsonObject)
VegaLite data in JSON format for version 2 visualizations.
VegaLiteV3(JsonObject)
VegaLite data in JSON format for version 3 visualizations.
VegaLiteV4(JsonObject)
VegaLite data in JSON format for version 4 visualizations.
VegaLiteV5(JsonObject)
VegaLite data in JSON format for version 5 visualizations.
VegaLiteV6(JsonObject)
VegaLite data in JSON format for version 6 visualizations.
VegaV3(JsonObject)
Vega data in JSON format for version 3 visualizations.
VegaV4(JsonObject)
Vega data in JSON format for version 4 visualizations.
VegaV5(JsonObject)
Vega data in JSON format for version 5 visualizations.
Vdom(JsonObject)
Represents Virtual DOM (nteract/vdom) data in JSON format.