/// <summary> /// adds a model as a reference model can be called inside a transaction /// </summary> /// <param name="refModelPath">the file path of the xbim model to reference, this must be an xbim file</param> /// <param name="owner">the actor who supplied the model</param> /// <returns></returns> public XbimReferencedModel AddModelReference(string refModelPath, IfcActorSelect owner) { XbimReferencedModel retVal; if (!IsTransacting) { using (var txn = BeginTransaction()) { var docInfo = Instances.New <IfcDocumentInformation>(); docInfo.DocumentId = NextReferenceIdentifier(); docInfo.Name = refModelPath; docInfo.DocumentOwner = owner; docInfo.IntendedUse = RefDocument; retVal = new XbimReferencedModel(docInfo); AddModelReference(retVal); txn.Commit(); } } else { var docInfo = Instances.New <IfcDocumentInformation>(); docInfo.DocumentId = NextReferenceIdentifier(); docInfo.Name = refModelPath; docInfo.DocumentOwner = owner; docInfo.IntendedUse = RefDocument; retVal = new XbimReferencedModel(docInfo); AddModelReference(retVal); } return(retVal); }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: case 8: base.IfcParse(propIndex, value); break; case 9: _subContractor = (IfcActorSelect)value.EntityVal; break; case 10: _jobDescription = value.StringVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: case 8: base.Parse(propIndex, value, nestedIndex); return; case 9: _subContractor = (IfcActorSelect)(value.EntityVal); return; case 10: _jobDescription = value.StringVal; return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: case 8: base.IfcParse(propIndex, value); break; case 9: _subContractor = (IfcActorSelect) value.EntityVal; break; case 10: _jobDescription = value.StringVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: _name = value.StringVal; return; case 1: _version = value.StringVal; return; case 2: _publisher = (IfcActorSelect)(value.EntityVal); return; case 3: _versionDate = value.StringVal; return; case 4: _location = value.StringVal; return; case 5: _description = value.StringVal; return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
/// <summary> /// Set the IfcRelAssociatesApproval object /// </summary> /// <param name="sheetName">Sheet name</param> /// <param name="rowName">Row name</param> /// <param name="ifcApproval">IfcApproval object</param> /// <param name="ifcRelAssociatesApproval">IfcRelAssociatesApproval object</param> private void SetRelObjectToApproval(string sheetName, string rowName, IfcApproval ifcApproval, IfcRelAssociatesApproval ifcRelAssociatesApproval) { IfcRoot ifcRoot = GetRootObject(sheetName, rowName); //sheetName = sheetName.ToLower().Trim(); if (ifcRoot != null) //we have a object { ifcRelAssociatesApproval.RelatedObjects.Add(ifcRoot); return; } if (sheetName == Constants.WORKSHEET_CONTACT) { IfcActorSelect ifcActorSelect = GetActorSelect(rowName); if (ifcActorSelect != null) { //see if the relation ship exists, if so no need to create IfcActorSelect IfcActorSelectTest = Model.Instances.OfType <IfcApprovalActorRelationship>() .Where(aar => aar.Approval == ifcApproval) .Select(aar => aar.Actor).OfType <IfcActorSelect>() .Where(po => po == ifcActorSelect) .FirstOrDefault(); if (IfcActorSelectTest == null) { IfcApprovalActorRelationship ifcApprovalActorRelationship = Model.Instances.New <IfcApprovalActorRelationship>(); ifcApprovalActorRelationship.Actor = ifcActorSelect; ifcApprovalActorRelationship.Approval = ifcApproval; } } } }
/// <summary> /// Writes out a contact, /// </summary> /// <param name="actor"></param> /// <param name="helper"></param> public ContactType(IfcActorSelect actor, CoBieLiteHelper helper) : this() { var personAndOrganization = actor as IfcPersonAndOrganization; var person = actor as IfcPerson; var organisation = actor as IfcOrganization; if (personAndOrganization != null) { ConvertOrganisation(personAndOrganization.TheOrganization, helper); ConvertPerson(personAndOrganization.ThePerson, helper); } else if (person != null) { ConvertPerson(person, helper); } else if (organisation != null) { ConvertOrganisation(organisation, helper); } ////Attributes //AttributeType[] ifcAttributes = helper.GetAttributes(actor); //if (ifcAttributes != null && ifcAttributes.Length > 0) // ContactAttributes = new AttributeCollectionType { Attribute = ifcAttributes }; }
public IfcLibraryInformation(IfcLabel __Name, IfcLabel?__Version, IfcActorSelect __Publisher, IfcDateTime?__VersionDate, IfcURIReference?__Location, IfcText?__Description) { this._Name = __Name; this._Version = __Version; this._Publisher = __Publisher; this._VersionDate = __VersionDate; this._Location = __Location; this._Description = __Description; }
public IfcInventory(IfcGloballyUniqueId __GlobalId, IfcOwnerHistory __OwnerHistory, IfcLabel?__Name, IfcText?__Description, IfcLabel?__ObjectType, IfcInventoryTypeEnum?__PredefinedType, IfcActorSelect __Jurisdiction, IfcPerson[] __ResponsiblePersons, IfcDate?__LastUpdateDate, IfcCostValue __CurrentValue, IfcCostValue __OriginalValue) : base(__GlobalId, __OwnerHistory, __Name, __Description, __ObjectType) { this._PredefinedType = __PredefinedType; this._Jurisdiction = __Jurisdiction; this._ResponsiblePersons = new HashSet <IfcPerson>(__ResponsiblePersons); this._LastUpdateDate = __LastUpdateDate; this._CurrentValue = __CurrentValue; this._OriginalValue = __OriginalValue; }
public IfcConstraint(IfcLabel __Name, IfcText?__Description, IfcConstraintEnum __ConstraintGrade, IfcLabel?__ConstraintSource, IfcActorSelect __CreatingActor, IfcDateTime?__CreationTime, IfcLabel?__UserDefinedGrade) { this._Name = __Name; this._Description = __Description; this._ConstraintGrade = __ConstraintGrade; this._ConstraintSource = __ConstraintSource; this._CreatingActor = __CreatingActor; this._CreationTime = __CreationTime; this._UserDefinedGrade = __UserDefinedGrade; }
public IfcLibraryInformation(IfcLabel __Name, IfcLabel?__Version, IfcActorSelect __Publisher, IfcDateTime?__VersionDate, IfcURIReference?__Location, IfcText?__Description) { this.Name = __Name; this.Version = __Version; this.Publisher = __Publisher; this.VersionDate = __VersionDate; this.Location = __Location; this.Description = __Description; this.LibraryInfoForObjects = new HashSet <IfcRelAssociatesLibrary>(); this.HasLibraryReferences = new HashSet <IfcLibraryReference>(); }
public IfcApproval(IfcIdentifier?__Identifier, IfcLabel?__Name, IfcText?__Description, IfcDateTime?__TimeOfApproval, IfcLabel?__Status, IfcLabel?__Level, IfcText?__Qualifier, IfcActorSelect __RequestingApproval, IfcActorSelect __GivingApproval) { this._Identifier = __Identifier; this._Name = __Name; this._Description = __Description; this._TimeOfApproval = __TimeOfApproval; this._Status = __Status; this._Level = __Level; this._Qualifier = __Qualifier; this._RequestingApproval = __RequestingApproval; this._GivingApproval = __GivingApproval; }
public IfcCostSchedule(IfcGloballyUniqueId __GlobalId, IfcOwnerHistory __OwnerHistory, IfcLabel?__Name, IfcText?__Description, IfcLabel?__ObjectType, IfcActorSelect __SubmittedBy, IfcActorSelect __PreparedBy, IfcDateTimeSelect __SubmittedOn, IfcLabel?__Status, IfcActorSelect[] __TargetUsers, IfcDateTimeSelect __UpdateDate, IfcIdentifier __ID, IfcCostScheduleTypeEnum __PredefinedType) : base(__GlobalId, __OwnerHistory, __Name, __Description, __ObjectType) { this._SubmittedBy = __SubmittedBy; this._PreparedBy = __PreparedBy; this._SubmittedOn = __SubmittedOn; this._Status = __Status; this._TargetUsers = new HashSet <IfcActorSelect>(__TargetUsers); this._UpdateDate = __UpdateDate; this._ID = __ID; this._PredefinedType = __PredefinedType; }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.Parse(propIndex, value, nestedIndex); return; case 5: _assetID = value.StringVal; return; case 6: _originalValue = (IfcCostValue)(value.EntityVal); return; case 7: _currentValue = (IfcCostValue)(value.EntityVal); return; case 8: _totalReplacementCost = (IfcCostValue)(value.EntityVal); return; case 9: _owner = (IfcActorSelect)(value.EntityVal); return; case 10: _user = (IfcActorSelect)(value.EntityVal); return; case 11: _responsiblePerson = (IfcPerson)(value.EntityVal); return; case 12: _incorporationDate = (IfcCalendarDate)(value.EntityVal); return; case 13: _depreciatedValue = (IfcCostValue)(value.EntityVal); return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.IfcParse(propIndex, value); break; case 5: _AssetID = value.StringVal; break; case 6: _OriginalValue = (IfcCostValue)value.EntityVal; break; case 7: _CurrentValue = (IfcCostValue)value.EntityVal; break; case 8: _TotalReplacementCost = (IfcCostValue)value.EntityVal; break; case 9: _Owner = (IfcActorSelect)value.EntityVal; break; case 10: _User = (IfcActorSelect)value.EntityVal; break; case 11: _ResponsiblePerson = (IfcPerson)value.EntityVal; break; case 12: _IncorporationDate = (IfcCalendarDate)value.EntityVal; break; case 13: _DepreciatedValue = (IfcCostValue)value.EntityVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public IfcAsset(IfcGloballyUniqueId __GlobalId, IfcOwnerHistory __OwnerHistory, IfcLabel?__Name, IfcText?__Description, IfcLabel?__ObjectType, IfcIdentifier __AssetID, IfcCostValue __OriginalValue, IfcCostValue __CurrentValue, IfcCostValue __TotalReplacementCost, IfcActorSelect __Owner, IfcActorSelect __User, IfcPerson __ResponsiblePerson, IfcCalendarDate __IncorporationDate, IfcCostValue __DepreciatedValue) : base(__GlobalId, __OwnerHistory, __Name, __Description, __ObjectType) { this._AssetID = __AssetID; this._OriginalValue = __OriginalValue; this._CurrentValue = __CurrentValue; this._TotalReplacementCost = __TotalReplacementCost; this._Owner = __Owner; this._User = __User; this._ResponsiblePerson = __ResponsiblePerson; this._IncorporationDate = __IncorporationDate; this._DepreciatedValue = __DepreciatedValue; }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.IfcParse(propIndex, value); break; case 5: _SubmittedBy = (IfcActorSelect)value.EntityVal; break; case 6: _PreparedBy = (IfcActorSelect)value.EntityVal; break; case 7: _SubmittedOn = (IfcDateTimeSelect)value.EntityVal; break; case 8: _Status = (IfcLabel)value.StringVal; break; case 10: _TargetUsers.Add((IfcActorSelect)value.EntityVal); break; case 11: _UpdateDate = (IfcDateTimeSelect)value.EntityVal; break; case 12: _ID = (IfcIdentifier)value.EntityVal; break; case 13: _PredefinedType = (IfcCostScheduleTypeEnum)Enum.Parse(typeof(IfcCostScheduleTypeEnum), value.EnumVal); break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.Parse(propIndex, value, nestedIndex); return; case 5: _submittedBy = (IfcActorSelect)(value.EntityVal); return; case 6: _preparedBy = (IfcActorSelect)(value.EntityVal); return; case 7: _submittedOn = (IfcDateTimeSelect)(value.EntityVal); return; case 8: _status = value.StringVal; return; case 9: _targetUsers.InternalAdd((IfcActorSelect)value.EntityVal); return; case 10: _updateDate = (IfcDateTimeSelect)(value.EntityVal); return; case 11: _iD = value.StringVal; return; case 12: _predefinedType = (IfcCostScheduleTypeEnum)System.Enum.Parse(typeof(IfcCostScheduleTypeEnum), value.EnumVal, true); return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
public static String RoleName(this IfcActorSelect actor) { if (actor is IfcPerson) { return(((IfcPerson)actor).RolesString); } else if (actor is IfcPersonAndOrganization) { return(((IfcPersonAndOrganization)actor).RolesString); } else if (actor is IfcOrganization) { return(((IfcOrganization)actor).RolesString); } return(""); }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: _identifier = value.StringVal; return; case 1: _name = value.StringVal; return; case 2: _description = value.StringVal; return; case 3: _timeOfApproval = value.StringVal; return; case 4: _status = value.StringVal; return; case 5: _level = value.StringVal; return; case 6: _qualifier = value.StringVal; return; case 7: _requestingApproval = (IfcActorSelect)(value.EntityVal); return; case 8: _givingApproval = (IfcActorSelect)(value.EntityVal); return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
internal IfcInventory(DatabaseIfc db, IfcInventory i, DuplicateOptions options) : base(db, i, options) { PredefinedType = i.PredefinedType; mJurisdiction = db.Factory.Duplicate(i.mJurisdiction, options); mResponsiblePersons.AddRange(i.mResponsiblePersons.Select(x => db.Factory.Duplicate(x, options))); mLastUpdateDate = i.mLastUpdateDate; if (mLastUpdateDateSS != null) { mLastUpdateDateSS = db.Factory.Duplicate(i.mLastUpdateDateSS, options); } if (i.mCurrentValue != null) { mCurrentValue = db.Factory.Duplicate(i.mCurrentValue, options); } if (i.mOriginalValue != null) { mOriginalValue = db.Factory.Duplicate(i.mOriginalValue, options); } }
private void SetRoles(Contact contact, IfcActorSelect actor) { IfcActorRole ifcActorRole = null; IfcPerson ifcPerson = (actor is IfcPerson) ? actor as IfcPerson : null; IfcOrganization ifcOrganization = (actor is IfcOrganization) ? actor as IfcOrganization : null; //IfcPersonAndOrganization ifcPersonAndOrganization = (actor is IfcPersonAndOrganization) ? actor as IfcPersonAndOrganization : null; //does not handle IfcPersonAndOrganization although it is a IfcActorSelect if (actor is IfcPersonAndOrganization) { throw new ArgumentException("Expecting IfcPerson or IfcOrganization"); } //swap categories into Roles foreach (var item in contact.Categories) { if (Exchanger.StringHasValue(item.Code)) { ifcActorRole = Exchanger.TargetRepository.Instances.New <IfcActorRole>(); ifcActorRole.RoleString = item.Code; ifcActorRole.Description = item.Description; if (ifcPerson != null) { ifcPerson.Roles.Add(ifcActorRole);//add to existing collection } if (ifcOrganization != null) { ifcOrganization.Roles.Add(ifcActorRole);//add to existing collection } //if (ifcPersonAndOrganization != null) //{ // if (ifcPersonAndOrganization.Roles == null) // { // ifcPersonAndOrganization.SetRoles(ifcActorRole);//create the ActorRoleCollection and set to Roles field // } // else // { // ifcPersonAndOrganization.Roles.Add(ifcActorRole);//add to existing collection // } //} } } }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: _actor = (IfcActorSelect)(value.EntityVal); return; case 1: _approval = (IfcApproval)(value.EntityVal); return; case 2: _role = (IfcActorRole)(value.EntityVal); return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
public virtual void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: _actor = (IfcActorSelect)value.EntityVal; break; case 1: _approval = (IfcApproval)value.EntityVal; break; case 2: _role = (IfcActorRole)value.EntityVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public IfcDocumentInformation(IfcIdentifier __DocumentId, IfcLabel __Name, IfcText?__Description, IfcDocumentReference[] __DocumentReferences, IfcText?__Purpose, IfcText?__IntendedUse, IfcText?__Scope, IfcLabel?__Revision, IfcActorSelect __DocumentOwner, IfcActorSelect[] __Editors, IfcDateAndTime __CreationTime, IfcDateAndTime __LastRevisionTime, IfcDocumentElectronicFormat __ElectronicFormat, IfcCalendarDate __ValidFrom, IfcCalendarDate __ValidUntil, IfcDocumentConfidentialityEnum?__Confidentiality, IfcDocumentStatusEnum?__Status) { this._DocumentId = __DocumentId; this._Name = __Name; this._Description = __Description; this._DocumentReferences = new HashSet <IfcDocumentReference>(__DocumentReferences); this._Purpose = __Purpose; this._IntendedUse = __IntendedUse; this._Scope = __Scope; this._Revision = __Revision; this._DocumentOwner = __DocumentOwner; this._Editors = new HashSet <IfcActorSelect>(__Editors); this._CreationTime = __CreationTime; this._LastRevisionTime = __LastRevisionTime; this._ElectronicFormat = __ElectronicFormat; this._ValidFrom = __ValidFrom; this._ValidUntil = __ValidUntil; this._Confidentiality = __Confidentiality; this._Status = __Status; }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.IfcParse(propIndex, value); //fall through and call base break; case 5: _theActor = (IfcActorSelect)(value.EntityVal); break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
/// <summary> /// Writes out a contact, /// </summary> /// <param name="actor"></param> /// <param name="helper"></param> public ContactConverter(IfcActorSelect actor, CoBieLiteUkHelper helper) { var personAndOrganization = actor as IfcPersonAndOrganization; var person = actor as IfcPerson; var organisation = actor as IfcOrganization; if (personAndOrganization != null) { ConvertOrganisation(personAndOrganization.TheOrganization, helper); ConvertPerson(personAndOrganization.ThePerson, helper); } else if(person!=null) ConvertPerson(person, helper); else if(organisation!=null) ConvertOrganisation(organisation, helper); ////Attributes //AttributeType[] ifcAttributes = helper.GetAttributes(actor); //if (ifcAttributes != null && ifcAttributes.Length > 0) // ContactAttributes = new AttributeCollectionType { Attribute = ifcAttributes }; }
public override void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.IfcParse(propIndex, value); break; case 5: _InventoryType = (IfcInventoryTypeEnum)Enum.Parse(typeof(IfcInventoryTypeEnum), value.EnumVal); break; case 6: _Jurisdiction = (IfcActorSelect)value.EntityVal; break; case 7: _ResponsiblePersons.Add((IfcPerson)value.EntityVal); break; case 8: _LastUpdateDate = (IfcCalendarDate)value.EntityVal; break; case 9: _CurrentValue = (IfcCostValue)value.EntityVal; break; case 10: _OriginalValue = (IfcCostValue)value.EntityVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public override void Parse(int propIndex, IPropertyValue value, int[] nestedIndex) { switch (propIndex) { case 0: case 1: case 2: case 3: case 4: base.Parse(propIndex, value, nestedIndex); return; case 5: _inventoryType = (IfcInventoryTypeEnum)System.Enum.Parse(typeof(IfcInventoryTypeEnum), value.EnumVal, true); return; case 6: _jurisdiction = (IfcActorSelect)(value.EntityVal); return; case 7: _responsiblePersons.InternalAdd((IfcPerson)value.EntityVal); return; case 8: _lastUpdateDate = (IfcCalendarDate)(value.EntityVal); return; case 9: _currentValue = (IfcCostValue)(value.EntityVal); return; case 10: _originalValue = (IfcCostValue)(value.EntityVal); return; default: throw new XbimParserException(string.Format("Attribute index {0} is out of range for {1}", propIndex + 1, GetType().Name.ToUpper())); } }
protected override Contact Mapping(IfcActorSelect actor, Contact target) { var helper = ((IfcToCOBieLiteUkExchanger)Exchanger).Helper; var personAndOrganization = actor as IfcPersonAndOrganization; var person = actor as IfcPerson; var organisation = actor as IfcOrganization; if (personAndOrganization != null) { ConvertOrganisation(target, personAndOrganization.TheOrganization); ConvertPerson(target, personAndOrganization.ThePerson); } else if (person != null) { ConvertPerson(target, person); } else if (organisation != null) { ConvertOrganisation(target, organisation); } if (string.IsNullOrWhiteSpace(target.Email)) { target.Email = string.Format("unknown{0}@undefined.email", actor.EntityLabel); } target.CreatedBy = helper.GetCreatedBy(actor); target.CreatedOn = helper.GetCreatedOn(actor); if (target.Categories == null || !target.Categories.Any()) { target.Categories = CoBieLiteUkHelper.UnknownCategory; } ////Attributes //AttributeType[] ifcAttributes = helper.GetAttributes(actor); //if (ifcAttributes != null && ifcAttributes.Length > 0) // ContactAttributes = new AttributeCollectionType { Attribute = ifcAttributes }; //Documents no link available IfcActorSelect not inherited from IfcRoot return(target); }
public static bool HasEmail(this IfcActorSelect actor, string emailAddress) { var personOrg = actor as IfcPersonAndOrganization; if (personOrg != null) { return(personOrg.HasEmail(emailAddress)); } var person = actor as IfcPerson; if (person != null) { return(person.HasEmail(emailAddress)); } var organisation = actor as IfcOrganization; if (organisation != null) { return(organisation.HasEmail(emailAddress)); } return(false); }
public static String RoleName(this IfcActorSelect actor) { var person = actor as IfcPerson; if (person != null) { return(string.Join("; ", person.Roles.Select(r => r.RoleString))); } var personAndOrganization = actor as IfcPersonAndOrganization; if (personAndOrganization != null) { return(string.Join("; ", personAndOrganization.Roles.Select(r => r.RoleString))); } var organization = actor as IfcOrganization; if (organization != null) { return(string.Join("; ", organization.Roles.Select(r => r.RoleString))); } return(""); }
internal IfcOccupant(IfcActorSelect a, IfcOccupantTypeEnum type) : base(a) { mPredefinedType = type; }
public virtual void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: _name = value.StringVal; break; case 1: _description = value.StringVal; break; case 2: _constraintGrade = (IfcConstraintEnum) Enum.Parse(typeof (IfcConstraintEnum), value.EnumVal); break; case 3: _constraintSource = value.StringVal; break; case 4: _creatingActor = (IfcActorSelect) value.EntityVal; break; case 5: _creationTime = (IfcDateTimeSelect) value.EntityVal; break; case 6: _userDefinedGrade = value.StringVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
internal IfcActor(DatabaseIfc db, IfcActor a) : base(db,a,false) { TheActor = db.Factory.Duplicate(a.mDatabase[ a.mTheActor]) as IfcActorSelect; }
internal IfcActor(IfcActorSelect a) : base(a.Database) { if(mDatabase.mModelView != ModelView.If2x3NotAssigned && mDatabase.mModelView != ModelView.Ifc4NotAssigned ) throw new Exception("Invalid Model View for IfcActor : " + mDatabase.ModelView.ToString()); mTheActor = a.Index; }
public IfcActor(IfcActorSelect a) : base(a.Database) { mTheActor = a.Index; }
public void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: _documentId = value.StringVal; break; case 1: _name = value.StringVal; break; case 2: _description = value.StringVal; break; case 3: if (_documentReferences == null) _documentReferences = new XbimSet<IfcDocumentReference>(this); _documentReferences.Add_Reversible((IfcDocumentReference) value.EntityVal); break; case 4: _purpose = value.StringVal; break; case 5: _intendedUse = value.StringVal; break; case 6: _scope = value.StringVal; break; case 7: _revision = value.StringVal; break; case 8: _documentOwner = (IfcActorSelect) value.EntityVal; break; case 9: if (_editors == null) _editors = new XbimSet<IfcActorSelect>(this); _editors.Add_Reversible((IfcActorSelect) value.EntityVal); break; case 10: _creationTime = (IfcDateAndTime) value.EntityVal; break; case 11: _lastRevisionTime = (IfcDateAndTime) value.EntityVal; break; case 12: _electronicFormat = (IfcDocumentElectronicFormat) value.EntityVal; break; case 13: _validFrom = (IfcCalendarDate) value.EntityVal; break; case 14: _validUntil = (IfcCalendarDate) value.EntityVal; break; case 15: _confidentiality = (IfcDocumentConfidentialityEnum) Enum.Parse(typeof (IfcDocumentConfidentialityEnum), value.EnumVal, true); break; case 16: _status = (IfcDocumentStatusEnum) Enum.Parse(typeof (IfcDocumentStatusEnum), value.EnumVal, true); break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }
public virtual void IfcParse(int propIndex, IPropertyValue value) { switch (propIndex) { case 0: _actor = (IfcActorSelect) value.EntityVal; break; case 1: _approval = (IfcApproval) value.EntityVal; break; case 2: _role = (IfcActorRole) value.EntityVal; break; default: this.HandleUnexpectedAttribute(propIndex, value); break; } }