Source code for cam.chain

"""BlenderCAM 'chain.py'

All properties of a CAM Chain (a series of Operations), and the Chain's Operation reference.
"""

from bpy.props import (
    BoolProperty,
    CollectionProperty,
    IntProperty,
    StringProperty,
)
from bpy.types import PropertyGroup


# this type is defined just to hold reference to operations for chains
[docs] class opReference(PropertyGroup):
[docs] name: StringProperty( name="Operation Name", default="Operation", )
[docs] computing = False # for UiList display
# chain is just a set of operations which get connected on export into 1 file.
[docs] class camChain(PropertyGroup):
[docs] index: IntProperty( name="Index", description="Index in the hard-defined camChains", default=-1, )
[docs] active_operation: IntProperty( name="Active Operation", description="Active operation in chain", default=-1, )
[docs] name: StringProperty( name="Chain Name", default="Chain", )
[docs] filename: StringProperty( name="File Name", default="Chain", ) # filename of
[docs] valid: BoolProperty( name="Valid", description="True if whole chain is ok for calculation", default=True, )
[docs] computing: BoolProperty( name="Computing Right Now", description="", default=False, )
# this is to hold just operation names.
[docs] operations: CollectionProperty( type=opReference, )