C# Solidworks二次开发:枚举应用实战(第五讲)

大家好,今天是我们枚举应用的第五讲。

下面是今天要介绍的枚举:

(1)第一个枚举为swConStraintType_e,这个枚举为草图约束,下面是官方的具体枚举值:

Member Description
swConstraintType_ALONGX 48
swConstraintType_ALONGX3D 64
swConstraintType_ALONGXPOINTS 51
swConstraintType_ALONGXPOINTS3D 66
swConstraintType_ALONGY 49
swConstraintType_ALONGY3D 65
swConstraintType_ALONGYPOINTS 52
swConstraintType_ALONGYPOINTS3D 67
swConstraintType_ALONGZ 50
swConstraintType_ALONGZPOINTS 53
swConstraintType_ANGLE 2
swConstraintType_ANGLE3P 43
swConstraintType_ARCANG180 19
swConstraintType_ARCANG270 20
swConstraintType_ARCANG90 18
swConstraintType_ARCANGBOTTOM 22
swConstraintType_ARCANGLEFT 23
swConstraintType_ARCANGRIGHT 24
swConstraintType_ARCANGTOP 21
swConstraintType_ARCLENGTH 44
swConstraintType_ATINTERSECT 13
swConstraintType_ATMIDDLE 12
swConstraintType_ATPIERCE 40
swConstraintType_BELTTRACTION 69
swConstraintType_BLOCKFIXEDLOCK 70 = Lock two blocks together
swConstraintType_BLOCKNORMALLOCK 71 = Lock blocks to be normal to one another (3D sketch)
swConstraintType_BLOCKROTATELOCK 72 = Lock blocks to rotate around each other (3D sketch)
swConstraintType_C3TOUCH 83
swConstraintType_CIRCULARPATTCNT 77
swConstraintType_COINCIDENT 9
swConstraintType_COLINEAR 27
swConstraintType_CONCENTRIC 10
swConstraintType_CONICRHO 82
swConstraintType_CORADIAL 28
swConstraintType_DIAMETER 15
swConstraintType_DISTANCE 1
swConstraintType_DOUBLEANGLE 84 = Double angle display
swConstraintType_DOUBLEDISTANCE 41
swConstraintType_ELLIPSEANG180 34
swConstraintType_ELLIPSEANG270 35
swConstraintType_ELLIPSEANG90 33
swConstraintType_ELLIPSEANGBOTTOM 37
swConstraintType_ELLIPSEANGLEFT 38
swConstraintType_ELLIPSEANGRIGHT 39
swConstraintType_ELLIPSEANGTOP 36
swConstraintType_EQUALCURV3DALIGN 80 = Aligned equal curvature between 3D splines
swConstraintType_EQUALCURVATURE 61
swConstraintType_EQUALTANGENT 62
swConstraintType_FAKESLOTCONSTRAINT 73 = Not actually a constraint; for display purposes only
swConstraintType_FITSPLINE 60
swConstraintType_FIXED 17
swConstraintType_FIXEDSLOT 74 = Fix a slot
swConstraintType_FLANGEFACEDIST 81 = Distance from virtual point to the relevant flange face
swConstraintType_HORIZONTAL 4
swConstraintType_HORIZPOINTS 25
swConstraintType_INTERSECTION 56
swConstraintType_INVALIDCTYPE 0
swConstraintType_ISOBYPOINT 58 = ISO curve when its constraint parameter is determined by an external point
swConstraintType_LINEARPATTCNT 76
swConstraintType_MERGEPOINTS 42
swConstraintType_NORMAL 45
swConstraintType_NORMALPOINTS 46
swConstraintType_OFFSETEDGE 16
swConstraintType_PARALLEL 7
swConstraintType_PARALLELYZ 54
swConstraintType_PARALLELZX 55
swConstraintType_PATTERNED 57
swConstraintType_PERPENDICULAR 8
swConstraintType_PLANAROFFSET 79 = For routing pipe offsets
swConstraintType_RADIALOFFSET 78 = For routing pipe offsets
swConstraintType_RADIUS 3
swConstraintType_SAMECURVELENGTH 85 = Equal arc/spline length
swConstraintType_SAMEISOPARAM 59 = Common relation for all pieces ( for the face ) of the surface's iso curve
swConstraintType_SAMELENGTH 14
swConstraintType_SAMESLOTS 75 = Same slot width and length
swConstraintType_SKETCHOFFSET 47 = Between entities of the same sketch
swConstraintType_SNAPANGLE 31
swConstraintType_SNAPGRID 29
swConstraintType_SNAPLENGTH 30
swConstraintType_SYMMETRIC 11
swConstraintType_TANGENT 6
swConstraintType_TANGENTFACE 63
swConstraintType_TRACTION 68
swConstraintType_USEEDGE 32
swConstraintType_VERTICAL 5 = Applies only to sketch lines
swConstraintType_VERTPOINTS 26 = Applies only to sketch points

(2)第二个为swDesignTableErrors_e,这个枚举值为设计表的错误,下面是官方的具体枚举值:

Member Description
swDTbCannotOpen 27
swDTblCfgInvalid 1
swDTblCorrupt 2
swDTblCurrentlyEditing 5
swDTblDataInvalidComponetState 15
swDTblDataInvalidFeatureState 16
swDTblDisplayStateError 18
swDTblExiting 3
swDTblFileNotFound 8
swDTblInvalidColCustomProp 10
swDTblInvalidColumnDimName 11
swDTblInvalidColumnFeatName 12
swDTblInvalidColumnKeyWord 13
swDTblInvalidColumnValue 9
swDTblInvalidConfigName 14
swDTblInvalidRowNameKeyword 21
swDTblInvalidYesNoData 17
swDTblLinkChanged 7
swDTblModelFeatRequired 19
swDTblNegitiveDimension 25
swDTblNoError 0
swDTblNoFileName 4
swDTblNotSuppressible 23
swDTblParentConfigInvalid 20
swDTblTableIsEmpty 24
swDTblTolTypeInvalid 22
swDTblTooManyColumns 6
swDTbUnUsedConfiguration 26
swDTConfigCircularDefinition 33
swDTDimAngleValueRangeError 31
swDTDimValueRangeError 30
swDTInvalidComponentName 28
swDTInvalidEquation 32
swDTNeedsComponent 29

(3)第三个为swFaultEntityErrorCode_e,这个枚举为实体故障错误码,下面是官方具体的枚举值:

Member Description
swBodyCorrupt 1 = Data structure is corrupt
swBodyInsideOut 3 = Body is inside out
swBodyInvalidIdentifiers 2 = Body has invalid or duplicate identifiers
swBodyRegionsInconsistent 4 = Regions of body are inconsistent
swEdgeBadFaceOrder 14 = On a non-manifold edge, the face order around the edge does not match the order of the faces' surfaces around the edge
swEdgeBadWire 15 = Two wireframe edges intersect at a position other than a vertex
swEdgeNonPeriodicCurve 5 = Open or non-periodic curve on ring edge
swEdgeNonPeriodicNomGeom 6 = Open or non-periodic nominal geometry on ring edge
swEdgeSpcurveOutOfTol 11 = Spcurve not within edge's tolerance
swEdgeSpcurveOutOfTolNomGeom 12 = Spcurve not within edge's tolerance of nominal geometry
swEdgeTouchEdge 36 = Edges touch
swEdgeVertexNotLie 7 = Vertex does not lie on edge's curve
swEdgeVertexNotLieNomGeom 8 = Vertex does not lie on nominal geometry
swEdgeVerticesTouch 13 = Vertices of edge touch
swEdgeWrongDir 9 = Curve in wrong direction for edge
swEdgeWrongDirNomGeom 10 = Nominal geometry in wrong direction
swEntityStateInvalid 34 = State of entity is invalid
swFaceBadEdge 17 = Edge does not lie on face's surface
swFaceBadEdgeOrder 18 = Edge order around the face does not match the order of the edges' curves around the face
swFaceBadLoops 20 = Loops inconsistent
swFaceBadVertex 16 = Vertex does not lie on face's surface
swFaceBadWireframe 22 = A wireframe edge intersects a face at a position other than a vertex
swFaceCheckerFailure 23 = Checker failure during face/face check
swFaceFaceInconsistency 24 = Inconsistent faces
swFaceNoAccomVertex 19 = A surface singularity has no accompanying vertex
swFaceSelfIntersecting 21 = Face is self intersecting
swGeomDegenerate 26 = Geometry degenerated
swGeomStateSelfIntersect 25 = Geometry is self intersecting
swRegionBadShells 27 = Inconsistent shells
swShellBadTopologyGeometry 28 = A topological entity belonging to a shell is not geometrically within the shell
swShellIntersect 29 = Shell shell inconsistency
swTopolMissingGeometry 35 = Missing geometry
swTopolNotG1Continuous 30 = Topology's geometry is not G1 continuous
swTopolSizeBoxViolation 31 = Some or all of entity is outside size box
swTopolStateCheckFail 32 = Checker failure
swTopolStateNoGeometry 33 = Missing geometry

(4)第四个为swKernelErrorCode_e,这个枚举为内核错误码,下面是官方的具体枚举值:

Member Description
swErrorBodyDontKnit -101041
swErrorCheckFailed -105061
swErrorCheckFailed2 -113812
swErrorCurveDiscontinuous -100131
swErrorCurveShort -101057
swErrorEdgeIncorrectOrder -116406
swErrorEdgeisectInvalid -116404
swErrorError 0
swErrorFacecheckFailed -113829
swErrorFaceFaceInconsistent -113816
swErrorFaceRedundant -116402
swErrorFailed -101063
swErrorGeometryDegenerate -113806
swErrorGeometryDiscontinuous -113827
swErrorGeometryMissing -113803
swErrorGeometrySelfx -113805
swErrorHasInvalidentity -101004
swErrorInconsistentDirs -116403
swErrorInvalidEntity -100914
swErrorInvalidGeometry -100999
swErrorInvalidGeometry2 -113808
swErrorInvalidKnots -100978
swErrorInvalidLoop -116405
swErrorInvalidParameter -100120
swErrorInvalidPattern -101042
swErrorInvalidSharing -100921
swErrorLoopsInconsistent -113826
swErrorNotEntity -100022
swErrorSuccess 1
swErrorSurfaceDiscontinuous -100129
swErrorTopologySelfx -113804
swErrorUnknown -1
swErrorVertexNotOnCurve -113818
swErrorVerticesTouch -113821

本篇文章要介绍的就是这么多,我们下篇文章再见。

相关推荐
linx2954 分钟前
单元九 · 零基础路线图-第 7–9 周·类与 RAII
c语言·开发语言·数据结构·c++·嵌入式硬件·算法
XiaoZhenHua9821 分钟前
C#工业机器视觉Recipe配方系统设计:多型号、多相机、多工位参数如何统一管理
c#·软件架构·机器视觉·工业自动化·工业软件·recipe
白色的北极熊1 小时前
c语言 输出菱形字符串
c语言·开发语言
学习智者1 小时前
《玄》IDE v3.6.3重磅发布:全功能修复与性能飞跃
开发语言·c++·ide·算法·中文语言 玄
奔跑吧树袋熊2 小时前
多租户隔离该做到哪一层:从连接池到 ORM 的取舍
开发语言·数据库·oracle·系统架构
大江东去浪淘尽千古风流人物2 小时前
【LoMa】局部特征匹配重访:从LoMa-B到旋转不变LoMa-R的架构与工程实践
开发语言·深度学习·计算机视觉·r语言·视觉定位·sfm·局部特征匹配
菜鸟~noob2332 小时前
【电子战】测向精度极限——克拉美-罗下限(CRLB)与误差分析【含matlab代码】
开发语言·matlab
m0_734571762 小时前
深入理解C++ 析构函数<二>析构顺序
开发语言·c++
T1mzhou2 小时前
ARM64 Linux 6.10 内核驱动(14):drivers/base/platform.c:板级设备主战场
linux·c语言·开发语言·arm开发
小孩玩什么2 小时前
深入理解字符串匹配算法:BF算法,KMP算法
java·c语言·开发语言·数据结构·c++·算法