Пример #1
0
 private void CreateRelationship(JsonApiData json, string name, bool isEnum, bool isInclude, Func <bool, object> resultData)
 {
     if (isInclude)
     {
         json.AddRelationship(name, resultData(this._modeExtand));
         if (isEnum)
         {
             foreach (IJsonApiObject item in (List <IJsonApiObject>)resultData(true))
             {
                 this.AddInclude(item);
             }
         }
         else
         {
             this.AddInclude((IJsonApiObject)resultData(true));
         }
     }
 }