forked from 1b-agent/opencadstudio-upstream
ocs_doc_api: Phase 3-ii — typed AttributeDefinition create (Phase 3 complete)
- CreateAttributeDefinition(AttributeDefinitionSpec) op (append-only). - backend add_attribute_definition (ATTDEF tag/prompt/default/insertion/height/rotation). - facade create_attribute_definition; entity_kind_name AttributeDefinition/AttributeEntity. - spec AttributeDefinition family; api_reference + binding_schema regenerated; mocks + baseline. - Test phase3ii_create_attribute_definition -> 614 host lib + 3 consistency green.
This commit is contained in:
1 parent
8d8c120880
commit
f8ae54a351
14 files changed
+128
-3
No files matched your search
@@ -136,6 +136,18 @@ pub struct DimensionAngularSpec {
|
||||
pub arc_location: [f64; 3],
|
||||
}
|
||||
|
||||
/// Construction spec for an `ATTDEF` (attribute definition): the tag, prompt,
|
||||
/// and default value for an in-block attribute, at an insertion point.
|
||||
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
|
||||
pub struct AttributeDefinitionSpec {
|
||||
pub tag: String,
|
||||
pub prompt: String,
|
||||
pub default_value: String,
|
||||
pub insertion_point: [f64; 3],
|
||||
pub height: f64,
|
||||
pub rotation: f64,
|
||||
}
|
||||
|
||||
/// Construction spec for a `RASTER_IMAGE`: an image file placed at
|
||||
/// `insertion_point` with per-pixel world-unit vectors `u_vector`/`v_vector` and
|
||||
/// pixel `size` (width, height). The host auto-registers the ImageDefinition.
|
||||
@@ -210,6 +222,7 @@ impl crate::gen::Operation {
|
||||
CreateDimensionRadius(_) => "CreateDimensionRadius",
|
||||
CreateDimensionDiameter(_) => "CreateDimensionDiameter",
|
||||
CreateDimensionAngular(_) => "CreateDimensionAngular",
|
||||
CreateAttributeDefinition(_) => "CreateAttributeDefinition",
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user