Topological data scripting

Introduction
First to use the Part module functionality you have to load the Part module into the interpreter:

Class Diagram
This is a UML overview about the most important classes of the Part module:

Geometry
The geomtric objects are the building block of all topological objects:
 * Geom Base class of the geometric objects
 * Line A straight line in 3D, defined by starting point and and point
 * Circle Circle or circle segment defined by a center point and start and end point
 * ...... And soon some more ;-)

Topology
The following topological data types are available:
 * COMPOUND A group of any type of topological object.
 * COMPSOLID A composite solid is a set of solids connected by their faces. It expands the notions of WIRE and SHELL to solids.
 * SOLID A part of space limited by shells. It is three dimensional.
 * SHELL A set of faces connected by their edges. A shell can be open or closed.
 * FACE In 2D it is part of a plane; in 3D it is part of a surface. Its geometry is constrained (trimmed) by contours. It is two dimensional.
 * WIRE A set of edges connected by their vertices. It can be an open or closed contour depending on whether the edges are linked or not.
 * EDGE A topological element corresponding to a restrained curve. An edge is generally limited by vertices. It has one dimension.
 * VERTEX A topological element corresponding to a point. It has zero dimension.
 * SHAPE A generic term covering all of the above.

Creating basic types
You can directly create basic topological objects through the module:

Exploring shapes
You can explore the topological data structure:

Creating Topology
We will now create a topology by constructing it out of simpler geometry. As a case study we use a part as seen in the picture which consists of four vertexes, two circles and two lines.

Creating Geometry
First we have to create the distinct geometric parts of this wire. And we have to take care that the vertexes of the geometric parts are at the same position. Otherwise we can later on not connect the geometric parts to a topology!

So we create first the points:

Arc
To create an arc of circle we make a helper point and create the arc of circle through three points:

Line
The line can be created very simple out of the points:

Put all together
The last step is to put the geometric base elements together and bake a topological shape:

Make a prism
Now extrude the wire in a direction and make an actual 3D shape: