1. Home
  2. Docs
  3. LunchBox Documentation
  4. Grasshopper Components
  5. Serialization

Serialization

LunchBox’s Serialization components enable users to serialize geometry, encrypt text, create GUIDs, and Hash objects.


Component Descriptions

Below, each component is described and visual examples are given. We’ve also included special Notes and Tips that can help users with less familiar situations.

The Serialization dropdown menu in LunchBox for Grasshopper

Description

Appearance


Deserialize Geometry

Converts a list of serialized text into geometry

Input:

  • Text, in one of the supported formats: Binary, JSON, or XML

Results:

  • Geometry constructed from the serialized text
Deserialize geometry

Serialize Geometry

Creates a mathematical conoid surface.

Input:

  • Geometry as a list (Tip: pass through a Brep component first)
  • Specify the output type by right-clicking on the Serialize component and choosing an option.

Results:

  • A list of serialized geometry as text, formatted to the selected type (Binary, JSON, or XML)
Serialize Example
Right-click on the component to select an output type (Binary, JSON, or XML)

Decrypt Text

Decrypts encrypted text with a passphrase. Supports Cipher Block Chaining (CBC), Electronic Codebook (ECB), and Cipher Feedback (CFB).

Input:

  • Encrypted text to decrypt
  • The correct passphrase
  • Specify the encryption type by right-clicking on the component and choosing an option (CBC, ECB, or CFB).

Results:

  • Decrypted Text
Decrypt text example
Encryption/Decryption types

Encrypt Text

Replaces text with other characters and allows users to create a custom passphrase to decrypt the message. Supports Cipher Block Chaining (CBC), Electronic Codebook (ECB), and Cipher Feedback (CFB).

Input:

  • Text to encrypt
  • Text to use as a passphrase
  • Specify the encryption type by right-clicking on the component and choosing an option (CBC, ECB, or CFB).

Results:

  • Encrypted text
Simple example using a plain text input.
Encrypt Text using a list of Serialized Geometry as input.
Encryption/Decryption types

Create GUID

Generates a list of GUIDs

Input:

  • A whole number to specify how many GUIDs to create
  • Specify the GUID format by right-clicking on the component and choosing an option

Results:

  • A list of GUIDs
Hyperbolic Paraboloid example setup
Right click on the component to select a format from the available types.

Hash Objects

Creates a hash for an object

Input:

  • An object to hash (Tip: Pass polysurface geometry through a Brep component first)
  • Select an SHA type by right-clicking on the component and choosing one of the available options.

Results:

  • A hash
Hash Objects example
Hash Objects SHA options
Hash Objects with a Brep example

How can we help?