Holst::JupyterCell
Inherits JSON::Serializable < Reference < Object
Constructors
new(pull : JSON::PullParser)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
cell_type
Sourcecell_type=(cell_type : String)
Sourceexecution_count
Sourceexecution_count=(execution_count : Int32 | Nil)
Sourceget_image
Sourcehas_data?
Sourcehas_image?
Sourceid
Sourceid=(id : String | Nil)
Sourceis_code?
Sourceis_markdown?
Sourcemetadata
Sourcemetadata=(metadata : JSON::Any)
Sourceoutputs
Sourceoutputs=(outputs : Array(Hash(String, JSON::Any)) | Nil)
Sourcesource
Sourcesource=(source : Array(String) | Nil)
Sourcetype
Returns the cell's type as a CellType, either Markdown or code
Example:
notebook.cells[0].type # => Holst::CellType::MARKDOWN
notebook.cells[1].type # => Holst::CellType::CODE