Example #1
0
 /// <summary>Indicates if the instance contains the data required for it to be sent as part of a request body in a <c>POST</c> HTTP method</summary>
 /// <returns><c>true</c> if the instance is in a fit state to be <c>POSTed</c>, otherwise <c>false</c></returns>
 internal bool IsPostable()
 {
     return((!string.IsNullOrEmpty(Title) && Year.HasValue) || (Ids != null && Ids.HasAnyValuesSet()));
 }
Example #2
0
 /// <summary>Indicates if the instance contains the data required for it to be sent as part of a request body in a <c>POST</c> HTTP method</summary>
 /// <param name="show">A <see cref="TraktShow"/> instance that would be <c>POSTed</c> alongside the episode</param>
 /// <returns><c>true</c> if the instance is in a fit state to be <c>POSTed</c>, otherwise <c>false</c></returns>
 internal bool IsPostable(TraktShow show = null)
 {
     return((Ids != null && Ids.HasAnyValuesSet()) || (show != null && !string.IsNullOrEmpty(show.Title) && SeasonNumber > 0 && EpisodeNumber > 0));
 }