public bool TryGetRootElement(string id, out tRootElement element) { element = null; if (id == null) { return(false); } element = Definition.Items.FirstOrDefault(t => t.id.Equals(id)); return(element != null); }
public static bool IsDataStore(tRootElement element) { return(element is tDataStore); }
public static bool IsCorrelationProperty(tRootElement element) { return(element is tCorrelationProperty); }
public static bool IsCollaboration(tRootElement element) { return(element is tCollaboration); }
public static bool IsInterface(tRootElement element) { return(element is tInterface); }
public static bool IsGlobalBusinessRuleTask(tRootElement element) { return(element is tGlobalBusinessRuleTask); }
public static bool IsResource(tRootElement element) { return(element is tResource); }
public static bool IsEscalation(tRootElement element) { return(element is tEscalation); }
public static bool IsPartnerRole(tRootElement element) { return(element is tPartnerRole); }
public static bool IsProcess(tRootElement element) { return(element is tProcess); }
public static bool IsPartnerEntity(tRootElement element) { return(element is tPartnerEntity); }
public static bool IsMessage(tRootElement element) { return(element is tMessage); }
public static bool IsItemDefinition(tRootElement element) { return(element is tItemDefinition); }
public static bool IsEndPoint(tRootElement element) { return(element is tEndPoint); }
public static bool IsRootElement(tRootElement element) { return(element is tRootElement); }
public static bool IsError(tRootElement element) { return(element is tError); }
public static bool IsSignal(tRootElement element) { return(element is tSignal); }
public static bool IsEventDefinition(tRootElement element) { return(element is tEventDefinition); }
public static ItemElementType GetElementType(tRootElement element) { if (IsCategory(element)) { return(ItemElementType.Category); } else if (IsCollaboration(element)) { return(ItemElementType.Collaboration); } else if (IsCorrelationProperty(element)) { return(ItemElementType.CorrelationProperty); } else if (IsDataStore(element)) { return(ItemElementType.DataStore); } else if (IsEndPoint(element)) { return(ItemElementType.EndPoint); } else if (IsError(element)) { return(ItemElementType.Error); } else if (IsEscalation(element)) { return(ItemElementType.Escalation); } else if (IsEventDefinition(element)) { return(ItemElementType.EventDefinition); } else if (IsGlobalBusinessRuleTask(element)) { return(ItemElementType.GlobalBusinessRuleTask); } else if (IsGlobalManualTask(element)) { return(ItemElementType.GlobalManualTask); } else if (IsGlobalScriptTask(element)) { return(ItemElementType.GlobalScriptTask); } else if (IsGlobalTask(element)) { return(ItemElementType.GlobalTask); } else if (IsGlobalUserTask(element)) { return(ItemElementType.GlobalUserTask); } else if (IsInterface(element)) { return(ItemElementType.Interface); } else if (IsItemDefinition(element)) { return(ItemElementType.ItemDefinition); } else if (IsMessage(element)) { return(ItemElementType.Message); } else if (IsPartnerEntity(element)) { return(ItemElementType.PartnerEntity); } else if (IsPartnerRole(element)) { return(ItemElementType.PartnerRole); } else if (IsProcess(element)) { return(ItemElementType.Process); } else if (IsResource(element)) { return(ItemElementType.Resource); } else if (IsRootElement(element)) { return(ItemElementType.RootElement); } else if (IsSignal(element)) { return(ItemElementType.Signal); } else { throw new ArgumentException("Unknown Item Element Type of " + element.GetType().Name); } }
public static bool IsGlobalUserTask(tRootElement element) { return(element is tGlobalUserTask); }
public static bool IsCategory(tRootElement element) { return(element is tCategory); }
public ItemDefinitionType GetItemDefinitionType(string elementId) { tRootElement element = GetRootElement(elementId); if (BpmnRootElement.IsCategory(element)) { return(ItemDefinitionType.Category); } else if (BpmnRootElement.IsCollaboration(element)) { return(ItemDefinitionType.Collaboration); } else if (BpmnRootElement.IsCorrelationProperty(element)) { return(ItemDefinitionType.CorrelationProperty); } else if (BpmnRootElement.IsDataStore(element)) { return(ItemDefinitionType.DataStore); } else if (BpmnRootElement.IsEndPoint(element)) { return(ItemDefinitionType.EndPoint); } else if (BpmnRootElement.IsError(element)) { return(ItemDefinitionType.Error); } else if (BpmnRootElement.IsEscalation(element)) { return(ItemDefinitionType.Escalation); } else if (BpmnRootElement.IsEventDefinition(element)) { return(ItemDefinitionType.EventDefinition); } else if (BpmnRootElement.IsGlobalBusinessRuleTask(element)) { return(ItemDefinitionType.GlobalBusinessRuleTask); } else if (BpmnRootElement.IsGlobalManualTask(element)) { return(ItemDefinitionType.GlobalManualTask); } else if (BpmnRootElement.IsGlobalScriptTask(element)) { return(ItemDefinitionType.GlobalScriptTask); } else if (BpmnRootElement.IsGlobalTask(element)) { return(ItemDefinitionType.GlobalTask); } else if (BpmnRootElement.IsGlobalUserTask(element)) { return(ItemDefinitionType.GlobalUserTask); } else if (BpmnRootElement.IsInterface(element)) { return(ItemDefinitionType.Interface); } else if (BpmnRootElement.IsItemDefinition(element)) { return(ItemDefinitionType.ItemDefinition); } else if (BpmnRootElement.IsMessage(element)) { return(ItemDefinitionType.Message); } else if (BpmnRootElement.IsPartnerEntity(element)) { return(ItemDefinitionType.PartnerEntity); } else if (BpmnRootElement.IsPartnerRole(element)) { return(ItemDefinitionType.PartnerRole); } else if (BpmnRootElement.IsProcess(element)) { return(ItemDefinitionType.Process); } else if (BpmnRootElement.IsResource(element)) { return(ItemDefinitionType.Resource); } else if (BpmnRootElement.IsRootElement(element)) { return(ItemDefinitionType.RootElement); } else if (BpmnRootElement.IsSignal(element)) { return(ItemDefinitionType.Signal); } else { throw new System.NotImplementedException(NOT_IMPLEMENT + element.GetType().Name); } }
public static bool IsGlobalTask(tRootElement elm) { return(elm is tGlobalTask); }