Autodesk.Revit.DB.TessellatedShapeBuilderOutcome是Revit API中的一个类,用于描述创建TessellatedShapeBuilder对象时的操作结果。
Autodesk.Revit.DB.TessellatedShapeBuilderOutcome包含以下几个枚举值:
可以通过以下代码示例创建TessellatedShapeBuilder对象,并根据Autodesk.Revit.DB.TessellatedShapeBuilderOutcome的值判断创建结果:
TessellatedShapeBuilder builder = new TessellatedShapeBuilder();
Autodesk.Revit.DB.TessellatedShapeBuilderOutcome outcome = builder.Build();
if (outcome == Autodesk.Revit.DB.TessellatedShapeBuilderOutcome.Success)
{
// 创建TessellatedShapeBuilder对象成功
}
else
{
// 创建TessellatedShapeBuilder对象失败
}
创建TessellatedShapeBuilder对象时,需要提供的几何数据必须符合Revit API支持的几何类型和格式,否则会返回Autodesk.Revit.DB.TessellatedShapeBuilderOutcome.UnsupportedGeometry或Autodesk.Revit.DB.TessellatedShapeBuilderOutcome.NullGeometry枚举值。在处理Autodesk.Revit.DB.TessellatedShapeBuilderOutcome.UnhandledException枚举值时,建议在程序中记录异常信息并及时处理,避免程序进一步崩溃。