/// <summary> /// Create an IFCFaceSurface object from a handle of type IfcFaceSurface. /// </summary> /// <param name="ifcFaceSurface">The IFC handle.</param> /// <returns>The IFCFace object.</returns> public static IFCFaceSurface ProcessIFCFaceSurface(IFCAnyHandle ifcFaceSurface) { if (IFCAnyHandleUtil.IsNullOrHasNoValue(ifcFaceSurface)) { Importer.TheLog.LogNullError(IFCEntityType.IfcFaceSurface); return(null); } if (IFCImportFile.TheFile.SchemaVersion > IFCSchemaVersion.IFC2x3 && IFCAnyHandleUtil.IsValidSubTypeOf(ifcFaceSurface, IFCEntityType.IfcAdvancedFace)) { return(IFCAdvancedFace.ProcessIFCAdvancedFace(ifcFaceSurface)); } IFCEntity face; if (!IFCImportFile.TheFile.EntityMap.TryGetValue(ifcFaceSurface.StepId, out face)) { face = new IFCFaceSurface(ifcFaceSurface); } return(face as IFCFaceSurface); }
/// <summary> /// Create an IFCFaceSurface object from a handle of type IfcFaceSurface. /// </summary> /// <param name="ifcFaceSurface">The IFC handle.</param> /// <returns>The IFCFace object.</returns> public static IFCFaceSurface ProcessIFCFaceSurface(IFCAnyHandle ifcFaceSurface) { if (IFCAnyHandleUtil.IsNullOrHasNoValue(ifcFaceSurface)) { Importer.TheLog.LogNullError(IFCEntityType.IfcFaceSurface); return null; } if (IFCImportFile.TheFile.SchemaVersion > IFCSchemaVersion.IFC2x3 && IFCAnyHandleUtil.IsSubTypeOf(ifcFaceSurface, IFCEntityType.IfcAdvancedFace)) { Importer.TheLog.LogUnhandledSubTypeError(ifcFaceSurface, IFCEntityType.IfcFaceSurface, false); return null; } IFCEntity face; if (!IFCImportFile.TheFile.EntityMap.TryGetValue(ifcFaceSurface.StepId, out face)) face = new IFCFaceSurface(ifcFaceSurface); return (face as IFCFaceSurface); }