Beispiel #1
0
        public virtual Comment CreateComment(string message, AgentLoginData loginData)
        {
            ParamIs.NotNullOrEmpty(() => message);
            ParamIs.NotNull(() => loginData);

            var comment = new UserComment(this, message, loginData);

            Comments.Add(comment);

            return(comment);
        }
Beispiel #2
0
        public virtual bool Equals(UserComment another)
        {
            if (another == null)
                return false;

            if (ReferenceEquals(this, another))
                return true;

            if (Id == 0)
                return false;

            return this.Id == another.Id;
        }
Beispiel #3
0
        public virtual bool Equals(UserComment another)
        {
            if (another == null)
            {
                return(false);
            }

            if (ReferenceEquals(this, another))
            {
                return(true);
            }

            if (Id == 0)
            {
                return(false);
            }

            return(this.Id == another.Id);
        }