Include¶
barescriptModel.bare¶
barescript_type_model¶
- bare_script.include.barescript_type_model()¶
Get the BareScript type model
- Returns:
The BareScript type model
- Return type:
barescript_validate_expression¶
- bare_script.include.barescript_validate_expression(expr)¶
Validate an expression model
- Parameters:
expr (dict) – The expression model
- Returns:
The validated expression model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
barescript_validate_script¶
- bare_script.include.barescript_validate_script(script)¶
Validate a BareScript model
- Parameters:
script (dict) – The BareScript model
- Returns:
The validated BareScript model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
base64.bare¶
base64_decode¶
base64_encode¶
data.bare¶
data_aggregate¶
data_calculated_field¶
- bare_script.include.data_calculated_field(data, field_name, expr, variables=None)¶
Add a calculated field to a data array
data_filter¶
data_join¶
- bare_script.include.data_join(left_data, right_data, join_expr, right_expr=None, is_left_join=None, variables=None)¶
Join two data arrays
- Parameters:
- Returns:
The joined data array
- Return type:
data_parse_csv¶
data_sort¶
data_top¶
- bare_script.include.data_top(data, count=None, category_fields=None)¶
Keep the top rows for each category
data_validate¶
- bare_script.include.data_validate(data, csv=None)¶
Validate a data array
- Parameters:
- Returns:
The map of field name to field type
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
dataLineChart.bare¶
data_line_chart_elements¶
- bare_script.include.data_line_chart_elements(data, line_chart, options=None)¶
Render a line chart as an element model
data_line_chart_validate¶
- bare_script.include.data_line_chart_validate(line_chart)¶
Validate a line chart model
- Parameters:
line_chart (dict) – The line chart model
- Returns:
The validated line chart model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
dataTable.bare¶
data_table_elements¶
data_table_markdown¶
data_table_validate¶
- bare_script.include.data_table_validate(data_table)¶
Validate a data table model
- Parameters:
data_table (dict) – The data table model
- Returns:
The validated data table model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
elementModel.bare¶
element_model_to_string¶
- bare_script.include.element_model_to_string(elements, indent=None)¶
Render an element model to an HTML or SVG string
element_model_validate¶
gzip.bare¶
gzip_compress¶
- bare_script.include.gzip_compress(bytes_, level=None)¶
Compress a byte value array (or a string, as UTF-8) with gzip
gzip_uncompress¶
markdown.bare¶
markdown_escape¶
markdown_header_id¶
markdown_paragraph_text¶
markdown_title¶
markdown_validate¶
- bare_script.include.markdown_validate(markdown)¶
Validate a Markdown model
- Parameters:
markdown (dict) – The Markdown model
- Returns:
The validated Markdown model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
markdownElements.bare¶
markdown_elements¶
markdownParser.bare¶
markdown_parse¶
markdownString.bare¶
markdown_to_string¶
- bare_script.include.markdown_to_string(markdown, wrap_width=None, ref_count=None)¶
Render a Markdown model as Markdown text
- Parameters:
markdown (dict) – The Markdown model
wrap_width (int or None, optional) – The text wrap width (default is 100). If zero or less, text is not wrapped.
ref_count (int or None, optional) – The minimum number of occurrences of a link/image URL for which a link/image reference is rendered (default is 0). If zero or less, all links/images are rendered inline.
- Returns:
The Markdown text
- Return type:
qrcode.bare¶
qrcode_elements¶
- bare_script.include.qrcode_elements(message, size, level=None)¶
Generate the element model for a QR code
qrcode_matrix¶
schema.bare¶
schema_get_enum_values¶
schema_get_referenced_types¶
- bare_script.include.schema_get_referenced_types(types, type_name, referenced_types=None)¶
Get a user type’s referenced type model
- Parameters:
types (dict) – The schema’s type model
type_name (str) – The type name
referenced_types (dict or None, optional) – A map of referenced user type name to user type model to update
- Returns:
The referenced type model
- Return type:
schema_get_struct_members¶
schema_validate¶
- bare_script.include.schema_validate(types, type_name, value, member_fqn=None)¶
Validate a value using a schema type model
- Parameters:
types (dict) – The schema’s type model
type_name (str) – The type name
value – The value to validate
member_fqn (str or None, optional) – The fully-qualified member name (for error messages)
- Returns:
The validated, transformed value
- Raises:
SchemaValidationError – A validation error occurred
schemaDoc.bare¶
schema_doc_markdown¶
- bare_script.include.schema_doc_markdown(types, type_name, options=None)¶
Generate the Schema Markdown user type documentation as an array of Markdown text lines
schemaParser.bare¶
schema_parse¶
- bare_script.include.schema_parse(text, types=None, filename=None, validate=None)¶
Parse Schema Markdown text
- Parameters:
text (str or list(str)) – The Schema Markdown text
types (dict or None, optional) – The schema’s type model to update
filename (str or None, optional) – The file name (for error messages)
validate (bool or None, optional) – If True (the default), validate the type model after parsing
- Returns:
The schema’s type model
- Return type:
- Raises:
SchemaParserError – A parsing error occurred
schemaTypeModel.bare¶
schema_type_model¶
- bare_script.include.schema_type_model()¶
Get the Schema Markdown type model
- Returns:
The Schema Markdown type model
- Return type:
schema_type_model_validate¶
- bare_script.include.schema_type_model_validate(types)¶
Validate a Schema Markdown type model
- Parameters:
types (dict) – The schema’s type model to validate
- Returns:
The validated type model
- Return type:
- Raises:
SchemaValidationError – A validation error occurred
tar.bare¶
tar_create¶
- bare_script.include.tar_create(files)¶
Create a tar archive (USTAR format) from an array of regular files. Each file has mode 644, and no directory entries are written.
- Parameters:
The array of file objects. Each file object has the following members:
”name” - the file path
”bytes” - the file content byte value array (integers 0 to 255) or string (as UTF-8)
”mtime” - the optional file modification datetime (default is the Unix epoch)
- Returns:
The tar archive byte value array, or None if creation fails
- Return type:
tar_extract¶
- bare_script.include.tar_extract(bytes_)¶
Extract the regular files of a tar archive (USTAR, GNU, or PAX format)