public static ApplicationRefObject fromDynamic(dynamic apprefData)
        {
            ApplicationRefObject appref = new ApplicationRefObject()
            {
                Name        = apprefData.name,
                Description = apprefData.description,
                Homepage    = apprefData.homepage,
                IsDeleted   = apprefData.deleted,
                Icon        = apprefData.icon.normal
            };

            return(appref);
        }
        public static ApplicationRefObject fromDynamic(dynamic apprefData)
        {
            ApplicationRefObject appref = new ApplicationRefObject()
            {
                Name = apprefData.name,
                Description = apprefData.description,
                Homepage = apprefData.homepage,
                IsDeleted = apprefData.deleted,
                Icon = apprefData.icon.normal
            };

            return appref;
        }
Ejemplo n.º 3
0
        public static CommentObject fromDynamic(dynamic comData)
        {
            CommentObject comment = new CommentObject()
            {
                Id          = comData.id,
                Comment     = comData.comment,
                Smiles      = comData.smiles,
                Answer      = AnswerObject.fromDynamic(comData.answer),
                User        = UserObject.fromDynamicSlim(comData.user),
                CreatedWith = ApplicationRefObject.fromDynamic(comData.created_with),
                CreatedAt   = comData.created_at
            };

            return(comment);
        }
        public static QuestionObject fromDynamic(dynamic quData)
        {
            QuestionObject question = new QuestionObject()
            {
                Id          = quData.id,
                Question    = quData.question,
                AnswerCount = quData.answer_count,
                IsAnonymous = quData.anonymous,
                Questioner  = UserObject.fromDynamicSlim(quData.user),
                CreatedWith = ApplicationRefObject.fromDynamic(quData.created_with),
                CreatedAt   = quData.created_at
            };

            return(question);
        }
Ejemplo n.º 5
0
        public static AnswerObject fromDynamic(dynamic ansData)
        {
            AnswerObject answer = new AnswerObject()
            {
                Id           = ansData.id,
                Answer       = ansData.answer,
                CommentCount = ansData.comment_count,
                SmileCount   = ansData.smile_count,
                Answerer     = UserObject.fromDynamicSlim(ansData.user),
                Question     = QuestionObject.fromDynamic(ansData.question),
                CreatedWith  = ApplicationRefObject.fromDynamic(ansData.created_with),
                CreatedAt    = ansData.created_at
            };

            return(answer);
        }