Skip to main content

A package a consice description of structured data

Project description

Structured data description and generation

About the package

This package allows consice descriptions of structured data. It allows one to embed tags and options to each node of the tree-like structure which are interpreted by the application. Tags and options are embeded in the keys when written in JSON and YAML formats, while they are specified as attributes in the XML format.

Motivation

This package defines a simple text format to describe structured data. The motivation comes from describing the document layouts of various forms, creating hierarchical geometric models etc. The idea is similar to HTML semantics, keeping the structure and meaning of various elements clear while describing their styles by CSS. In case of hierarchical geometric models, the description of the model structure and the configuration of each geometric object can be separated.

Specification

The description is has 3 parts:

  • Structure
    • This part describes the structure of the document or the system.
    • The basic element composing the entire structure is called an element which has a name and an associated type.
    • The name and type of an element are described as the key in the Yaml file like "name[options]{tags}".
  • Components
    • A component is meant to define a type, similar to a class in object-oriented programming languages.
    • This part contains components which can be reused as part of the structure.
  • Configuration
    • The configuration (style) of each component or element is specified here.
    • A component can be specified by its name, while an element can be specified as C1.e1 for an element e1 which is a child of component C1.

The basic format is Yaml. There is a header section in the Yaml file where one can modify the above Structure/components/configuration keys like

header:
  structureKey: documnent
  componentsKey: components
  configurationKey: styles
  target: HTML+CSS
  
documennt[Page]: ~

components: ~

styles: ~
  Page:
    color: navy

Usage

This package only specifies the format to describe structured data. How the contents are used is left to the application. As the original motivation was to describe the page layout or hierachical data, some derived outputs may be produced from these descriptions. There are several forseen targets as listed below.

Target Description
Tkinter Tkinter GUI layout
HTML+CSS HTML+CSS files
Cgeom Geometry package (private)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sddgen-0.0.3.tar.gz (13.0 kB view details)

Uploaded Source

File details

Details for the file sddgen-0.0.3.tar.gz.

File metadata

  • Download URL: sddgen-0.0.3.tar.gz
  • Upload date:
  • Size: 13.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.12

File hashes

Hashes for sddgen-0.0.3.tar.gz
Algorithm Hash digest
SHA256 0311afaba84eef79773185bb0822dd24fc3f12eca4ce6ca3ee5cbcbd7634fae7
MD5 85a3f693887398c14af412b2c29559eb
BLAKE2b-256 f36c4fe5b8f7b231983c3a1d6a6f79b16a98503a5c568ae8ccdb557845a0089b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page