public void AssignCondition(GenericToken token) { AssignedTokens.Add(token); token.WhenAssigned(); Host.CallOnConditionIsAssigned(token.GetType()); }
public void AssignCondition(Type tokenType) { GenericToken token = (GenericToken)Activator.CreateInstance(tokenType, Host); AssignedTokens.Add(token); token.WhenAssigned(); Host.CallOnConditionIsAssigned(token.GetType()); }
private void FinalizeAssignToken(Action callback) { if (TokenToAssign == null) { callback(); return; } AssignedTokens.Add(TokenToAssign); TokenToAssign.WhenAssigned(); Host.CallOnTokenIsAssigned(TokenToAssign, callback); }