Beispiel #1
0
        private void TryAddUser(Profiler.User user)
        {
            if (UserKey.IsInvalid(user))
            {
                return;
            }

            User.Add(new UserKey(user));
        }
Beispiel #2
0
        private Entity.tUser TryGetUser(Profiler.User user)
        {
            if (UserKey.IsInvalid(user))
            {
                return(null);
            }

            var result = _baseData.User[new UserKey(user)];

            return(result);
        }
Beispiel #3
0
        private void FillUserHashFromEvents(IEnumerable <Profiler.Event> events)
        {
            if (events == null)
            {
                return;
            }

            var valid = events.Where(IsNotNull);

            foreach (var anEvent in valid)
            {
                var user = anEvent.User;

                if (UserKey.IsInvalid(user))
                {
                    throw new ArgumentNullException(nameof(user), "An event has no user assigned.");
                }

                User.Add(new UserKey(user));
            }
        }