/// <summary>Creates a new instance of MessageIterator. </summary> public MessageIterator(IMessage start, IStructureDefinition startDefinition, string direction, bool handleUnexpectedSegments) { this.message = start; this.direction = direction; this.handleUnexpectedSegments = handleUnexpectedSegments; this.currentDefinitionPath.Add(new Position(startDefinition, -1)); }
protected internal virtual void CreateItemDefinitions(BpmnModel bpmnModel) { foreach (ItemDefinition itemDefinitionElement in bpmnModel.ItemDefinitions.Values) { if (!itemDefinitionMap.ContainsKey(itemDefinitionElement.Id)) { IStructureDefinition structure = null; try { // it is a class Type classStructure = ReflectUtil.LoadClass(itemDefinitionElement.StructureRef); structure = new ClassStructureDefinition(classStructure); } catch (ActivitiException) { // it is a reference to a different structure structure = structureDefinitionMap[itemDefinitionElement.StructureRef]; } Datas.ItemDefinition itemDefinition = new Datas.ItemDefinition(itemDefinitionElement.Id, structure); if (!string.IsNullOrWhiteSpace(itemDefinitionElement.ItemKind)) { itemDefinition.ItemKind = (ItemKind)Enum.Parse(typeof(ItemKind), itemDefinitionElement.ItemKind); } itemDefinitionMap[itemDefinition.Id] = itemDefinition; } } }
public NonStandardStructureDefinition( IStructureDefinition parent, IStructureDefinition thePreviousSibling, string name, int position) { if (string.IsNullOrEmpty(name)) { throw new ArgumentNullException(nameof(name), "name is missing"); } Parent = parent; Name = name; previousSibling = thePreviousSibling; Position = position; }
/// <summary> /// /// </summary> /// <param name="id"></param> /// <param name="structure"></param> public ItemDefinition(string id, IStructureDefinition structure) : this() { this.id = id; this.structure = structure; }