An IfcCircle is a curve consisting of a set of points having equal distance from the center.
NOTE A circular arc segment is defined by using the IfcTrimmedCurve with BasisCurve being an IfcCircle.
C = SELF\IfcConic.Position.Location
x = SELF\IfcConic.Position.P[1]
y = SELF\IfcConic.Position.P[2]
z = SELF\IfcConic.Position.P[3]
R = Radiusand the circle is parameterized as
![]()
The parameterization range is 0 ≤ u ≤ 2π (0 ≤ u ≤ 360 degree).
In the placement coordinate system defined above, the circle is the equation C = 0, where![]()
The positive sense of the circle at any point is in the tangent direction, T, to the curve at the point, where
![]()
NOTE Entity adapted from circle defined in ISO 10303-42
XSD Specification
<xs:element name="IfcCircle" type="ifc:IfcCircle" substitutionGroup="ifc:IfcConic" nillable="true"/> <xs:complexType name="IfcCircle"> <xs:complexContent> <xs:extension base="ifc:IfcConic"> <xs:attribute name="Radius" type="ifc:IfcPositiveLengthMeasure" use="optional"/> xs:extension> xs:complexContent> xs:complexType>
EXPRESS Specification
ENTITY IfcCircle
SUBTYPE OF (IfcConic);
Radius : IfcPositiveLengthMeasure;
END_ENTITY;
/* Generated By: IFC Tools Project EXPRESS TO JAVA COMPILER: Do not edit this file!! */ package ifc2x3javatoolbox.ifc2x3tc1; /** * This is a default implementation of the entity IfcCircle
*
* Copyright: CC BY-NC-SA 3.0 DE (cc) 2013 Eike Tauscher and Michael Theiler
* The whole package including this class is licensed under
* * Creative Commons Attribution-Non-Commercial-Share Alike 3.0 Germany.
* If you are using the package or parts of it in any commercial way, a commercial license is required. * Visit http://www.ifctoolsproject.com for more information * or contact us directly: [email protected]
*/ public class IfcCircle extends IfcConic implements ClassInterface { private static final String[] nonInverseAttributes = new String[]{"IfcAxis2Placement","IfcPositiveLengthMeasure"}; private java.util.ArrayListstepParameter = null; private java.util.HashSet listenerList = null; protected int stepLineNumber; /** Radius is an DEMANDED attribute - may not be null**/ protected IfcPositiveLengthMeasure Radius; /** * The default constructor. **/ public IfcCircle(){} /** * Constructs a new IfcCircle object using the given parameters. * * @param Position DEMANDED parameter of type IfcAxis2Placement - may not be null. * @param Radius DEMANDED parameter of type IfcPositiveLengthMeasure - may not be null. **/ public IfcCircle(IfcAxis2Placement Position, IfcPositiveLengthMeasure Radius) { this.Position = Position; this.Radius = Radius; resolveInverses(); } /** * This method initializes the IfcCircle object using the given parameters. * * @param Position DEMANDED parameter of type IfcAxis2Placement - may not be null. * @param Radius DEMANDED parameter of type IfcPositiveLengthMeasure - may not be null. **/ public void setParameters(IfcAxis2Placement Position, IfcPositiveLengthMeasure Radius) { this.Position = Position; this.Radius = Radius; resolveInverses(); } /** * This method is used internally and should NOT be used for own purposes. **/ void initialize(java.util.ArrayList parameters) { this.Position = (IfcAxis2Placement) parameters.get(0); this.Radius = (IfcPositiveLengthMeasure) parameters.get(1); resolveInverses(); } /** * This method is used internally and should NOT be used for own purposes. **/ void destruct() { super.destruct(); listenerList = null; } private void resolveInverses() { } /** * This method is used internally and should NOT be used for own purposes. **/ String[] getNonInverseAttributeTypes() { return IfcCircle.nonInverseAttributes; } /** * This method is used internally and should NOT be used for own purposes. **/ private java.util.HashSet getRedefinedDerivedAttributeTypes() { java.util.HashSet redefinedDerivedAttributes = new java.util.HashSet (); return redefinedDerivedAttributes; } /** * This method returns the object IFC STEP representation. This method is called by the IfcModel object to write IFC STEP files. * * @return the IFC STEP representation of this object **/ public String getStepLine() { String stepString = new String("#"+this.stepLineNumber+"= "); stepString = stepString.concat("IFCCIRCLE("); if(getRedefinedDerivedAttributeTypes().contains("Position")) stepString = stepString.concat("*,"); else{ if(this.Position != null) stepString = stepString.concat(((RootInterface)this.Position).getStepParameter(IfcAxis2Placement.class.isInterface())+","); else stepString = stepString.concat("$,"); } if(getRedefinedDerivedAttributeTypes().contains("Radius")) stepString = stepString.concat("*);"); else{ if(this.Radius != null) stepString = stepString.concat(((RootInterface)this.Radius).getStepParameter(IfcPositiveLengthMeasure.class.isInterface())+");"); else stepString = stepString.concat("$);"); } return stepString; } /** * This method is used internally and should NOT be used for own purposes. **/ public String getStepParameter(boolean isSelectType) { return "#" + this.stepLineNumber; } /** * This method returns the line number within a IFC STEP representation. This method is called from other objects, where this one is referenced. * * @return the STEP line number **/ public int getStepLineNumber() { return this.stepLineNumber; } /** * This method is used internally and should NOT be used for own purposes. **/ void setStepLineNumber(int number) { this.stepLineNumber = number; } /** * This method sets the Radius attribute to the given value. * * @param Radius OPTIONAL value to set **/ public void setRadius(IfcPositiveLengthMeasure Radius) { this.Radius = Radius; fireChangeEvent(); } /** * This method returns the value of the Radius attribute. * * @return the value of Radius /**/ public IfcPositiveLengthMeasure getRadius() { return this.Radius; } /** * This method is used internally and should NOT be used for own purposes. **/ void setStepParameter(java.util.ArrayList parameter) { this.stepParameter = parameter; } /** * This method is used internally and should NOT be used for own purposes. **/ java.util.ArrayList getStepParameter() { return this.stepParameter; } /** * This method registers an ObjectChangeListener to this object. An event is fired whenever one of its values was changed. * *@param listener the listener to register **/ public void addObjectChangeListener(ObjectChangeListener listener) { if (listenerList == null) listenerList = new java.util.HashSet (1,1); listenerList.add(listener); } /** * This method unregisters an ObjectChangeListener from this object. * *@param listener the listener to unregister **/ public void removeObjectChangeListener(ObjectChangeListener listener) { if (listenerList == null) return; listenerList.remove(listener); if (listenerList.size()==0) listenerList = null; } /** * This method removes all currently registered ObjectChangeListeners from this object. **/ public void removeAllObjectChangeListeners() { listenerList = null; } protected void fireChangeEvent() { if(listenerList == null) return; for(ObjectChangeListener listener : listenerList) listener.ifcModelObjectChange(this); } /** * This method clones the object (deep cloning). * * @return the cloned object **/ public Object clone() { IfcCircle ifcCircle = new IfcCircle(); if(this.Position != null) ifcCircle.setPosition((IfcAxis2Placement)this.Position.clone()); if(this.Radius != null) ifcCircle.setRadius((IfcPositiveLengthMeasure)this.Radius.clone()); return ifcCircle; } /** * This method copys the object as shallow copy (all referenced objects are remaining). * * @return the cloned object **/ public Object shallowCopy() { IfcCircle ifcCircle = new IfcCircle(); if(this.Position != null) ifcCircle.setPosition(this.Position); if(this.Radius != null) ifcCircle.setRadius(this.Radius); return ifcCircle; } /** * This method returns the objects standard description. * * @return the standard description **/ public String toString() { return "#"+ this.getStepLineNumber() + " " + this.getClass().getSimpleName(); } }