Knetik.KnetikClient.GetRelationships C# (CSharp) Method

GetRelationships() public method

public GetRelationships ( int ancestorDepth, int descendantDepth, bool includeSiblings, Action cb = null ) : KnetikApiResponse
ancestorDepth int
descendantDepth int
includeSiblings bool
cb Action
return KnetikApiResponse
        public KnetikApiResponse GetRelationships(int ancestorDepth, int descendantDepth, bool includeSiblings, Action<KnetikApiResponse> cb = null)
        {
            JSONObject j = new JSONObject (JSONObject.Type.OBJECT);
            j.AddField ("ancestorDepth", ancestorDepth);
            j.AddField ("descendantDepth", descendantDepth);
            j.AddField ("includeSiblings", includeSiblings);
            String body = j.Print ();

            KnetikRequest req = CreateRequest(UserGetRelationshipsEndpoint, body);
            KnetikApiResponse res = new KnetikApiResponse(this, req, cb);
            return res;
        }