/// <summary> /// Posts an Ad. /// </summary> /// <remarks> /// To successfully post an Ad, ad argument must contain a valid User that posted the ad, and userPassword argument must match that User's password in DB. /// </remarks> /// <param name="ad">Ad to post.</param> /// <returns>The Book ad that was posted.</returns> /// public BookAd PostAd(BookAd ad) { ad.Id = ++bookAdCount; bookAds.Add(ad); return(ad); }
/// <summary> /// Posts an Ad. /// </summary> /// <remarks> /// To successfully post an Ad, ad argument must contain a valid User that posted the ad, and userPassword argument must match that User's password in DB. /// </remarks> /// <param name="ad">Ad to post.</param> /// <returns>The Book ad that was posted.</returns> /// public BookAd PostAd(BookAd ad) { ad.Id = ++bookAdCount; bookAds.Add(ad); return ad; }