Exemple #1
0
        public static void Search(ISocialNetworkService searcher)
        {
            var users        = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships  = searcher.GetFriendships(2, 10);
            var chatUsers    = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var jsons = new List <string>
            {
                JsonConvert.SerializeObject(users, Formatting.Indented),
                JsonConvert.SerializeObject(postsByUsers, Formatting.Indented),
                JsonConvert.SerializeObject(friendships, Formatting.Indented),
                JsonConvert.SerializeObject(chatUsers, Formatting.Indented)
            };

            for (int i = 1; i <= jsons.Count; i++)
            {
                var dir = new DirectoryInfo("../../../JSONResults");
                dir.Create();

                using (var writer = new StreamWriter(string.Format("../../../JSONResults/Result{0}.json", i)))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }
        }
Exemple #2
0
 public static void Search(ISocialNetworkService searcher)
 {
     var users = searcher.GetUsersAfterCertainDate(2013);
     var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
     var friendships = searcher.GetFriendships(2, 10);
     var chatUsers = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");
 }
Exemple #3
0
 public TeamMemberViewBuilder(HtmlHelper htmlHelper, TeamMemberView model)
     : base(htmlHelper, model)
 {
     teamMemberService    = Engine.Resolve <ITeamMemberService>();
     mediaStorageService  = Engine.Resolve <IMediaStorageService>();
     socialNetworkService = Engine.Resolve <ISocialNetworkService>();
 }
        public static void Search(ISocialNetworkService searcher)
        {
            var users = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships = searcher.GetFriendships(2, 10);
            var chatUsers = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var jsons = new List<string>
            {
                users.ToString(),
                postsByUsers.ToString(),
                friendships.ToString(),
                chatUsers.ToString()
            };


            for (int i = 1; i <= jsons.Count; i++)
            {
                using (var writer = new StreamWriter(string.Format("../../JsonFiles/Result{0}.json", i)))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }

            //SaveJsonToFile("Result1.json", users.ToString());
        }
Exemple #5
0
 public static void Search(ISocialNetworkService searcher)
 {
     var users        = searcher.GetUsersAfterCertainDate(2013);
     var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
     var friendships  = searcher.GetFriendships(2, 10);
     var chatUsers    = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");
 }
Exemple #6
0
 public TeamMemberController(ITeamMemberService _teamMemberService,
                             ISocialNetworkService _socialNetworkService,
                             IMediaStorageService _mediaStorageService)
 {
     teamMemberService    = _teamMemberService;
     socialNetworkService = _socialNetworkService;
     mediaStorageService  = _mediaStorageService;
 }
Exemple #7
0
 public WidgetsController(IFriendLinkService friendLinkService,
                          ISocialNetworkService socialNetworkService,
                          ITestimonialService testimonialService,
                          ICarouselService carouselService)
 {
     _friendLinkService    = friendLinkService;
     _socialNetworkService = socialNetworkService;
     _testimonialService   = testimonialService;
     _carouselService      = carouselService;
 }
Exemple #8
0
 public ProductController(IConfiguration configuration, IMemoryCache cache, IBrandService brandService,
                          IBranchContactService branchContactService,
                          IMenuService menuService, ISettingService settingService,
                          ISocialNetworkService socialNetworkService, ILanguageService languageService,
                          IProductService productService)
     : base(configuration, cache, brandService, branchContactService, menuService, settingService, socialNetworkService, languageService)
 {
     _configuration  = configuration;
     _cache          = cache;
     _productService = productService;
 }
 public PortfolioController(IPortfolioCategoryService _portfolioCategoryService,
                            IPortfolioService _portfolioService,
                            IUrlService _urlService,
                            IMediaStorageService _mediaStorageService,
                            ISocialNetworkService _socialNetworkService)
 {
     portfolioCategoryService = _portfolioCategoryService;
     portfolioService         = _portfolioService;
     urlService          = _urlService;
     mediaStorageService = _mediaStorageService;
 }
Exemple #10
0
 public BaseController(IConfiguration configuration, IMemoryCache cache, IBranchContactService branchContactService,
                       IMenuService menuService, ISettingService settingService, ISocialNetworkService socialNetworkService, ILanguageService languageService)
 {
     _configuration        = configuration;
     _cache                = cache;
     _settingService       = settingService;
     _socialNetworkService = socialNetworkService;
     _menuService          = menuService;
     _branchContactService = branchContactService;
     _languageService      = languageService;
 }
Exemple #11
0
 public ApplicationUserService(IUserStore <ApplicationUser> store,
                               ICacheManager _cacheManager,
                               IMediaStorageService _mediaStorageService,
                               ISocialNetworkService _socialNetworkService)
     : base(store)
 {
     userService          = store;
     cacheManager         = _cacheManager;
     mediaStorageService  = _mediaStorageService;
     socialNetworkService = _socialNetworkService;
 }
Exemple #12
0
 public SiteSettingController(ISiteSettingService siteSettingService, IMapper mapper, IFileService fileService, ITeamService teamService
                              , UserManager <AppUser> userManager, IUserService userService, ISocialNetworkService socialNetworkService, ISliderService sliderService)
 {
     this._sliderService        = sliderService;
     this._socialNetworkService = socialNetworkService;
     this._userManager          = userManager;
     this._userService          = userService;
     this._siteSettingService   = siteSettingService;
     this._mapper      = mapper;
     this._fileService = fileService;
     this._teamService = teamService;
 }
 public PhotosPageViewModel(
     ILog log,
     INavigationService navigationService,
     ISocialNetworkService socialNetworkService,
     IImagePicker imagePicker,
     INotificationsService notificationsService)
 {
     Log = log;
     NavigationService    = navigationService;
     SocialNetworkService = socialNetworkService;
     ImagePicker          = imagePicker;
     NotificationsService = notificationsService;
 }
 public ClientTestimonialsController(ISettingService _settingService,
                                     IUrlService _urlService,
                                     IClietTestimonialsService _testimonialsService,
                                     ISocialNetworkService _socialNetworkService,
                                     IMediaStorageService _mediaStorageService,
                                     ICacheManager _cacheManager)
 {
     settingService       = _settingService;
     urlService           = _urlService;
     testimonialsService  = _testimonialsService;
     socialNetworkService = _socialNetworkService;
     mediaStorageService  = _mediaStorageService;
     cacheManager         = _cacheManager;
 }
Exemple #15
0
 public UserProfilePageViewModel(
     ISocialNetworkService socialNetworkService,
     ILog log,
     INavigationService navigationService,
     INotificationsService notificationService,
     IInputService inputService)
 {
     Log = log;
     SocialNetworkService = socialNetworkService;
     NavigationService    = navigationService;
     NotificationService  = notificationService;
     InputService         = inputService;
     LoadData();
 }
Exemple #16
0
        public MainPageViewModel(
            INavigationService navigationService,
            ISocialNetworkService socialNetworkService,
            ILog log)
        {
            Log = log;
            NavigationService    = navigationService;
            SocialNetworkService = socialNetworkService;

            if (SocialNetworkService.IsLogged())
            {
                Login();
            }
        }
Exemple #17
0
 public JobService(IRepository <Job> _jobRepository,
                   ICacheManager _cacheManager,
                   IMediaStorageService _mediaStorageService,
                   IJobCategoryService _categoryService,
                   ApplicationUserService _userService,
                   ISocialNetworkService _socialNetworkService,
                   IUrlService _urlService,
                   IApplyJobService _applyJobService)
 {
     jobRepository   = _jobRepository;
     cacheManager    = _cacheManager;
     categoryService = _categoryService;
     urlService      = _urlService;
     applyJobService = _applyJobService;
 }
Exemple #18
0
        public static void Search(ISocialNetworkService searcher)
        {
            var users = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships = searcher.GetFriendships(2, 10);
            var chatUsers = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var jsons = new List<string>()
            {
                JsonConvert.SerializeObject(users, Formatting.Indented),
                JsonConvert.SerializeObject(postsByUsers, Formatting.Indented),
                JsonConvert.SerializeObject(friendships, Formatting.Indented),
                JsonConvert.SerializeObject(chatUsers, Formatting.Indented),

            };

            //foreach (var user in users)
            //{
            //    string json = JsonConvert.SerializeObject(user, Formatting.Indented);
            //    jsons.Add(json);
            //}

            //foreach (var post in postsByUsers)
            //{
            //    string json = JsonConvert.SerializeObject(post, Formatting.Indented);
            //    jsons.Add(json);
            //}

            //foreach (var friendship in friendships)
            //{
            //    string json = JsonConvert.SerializeObject(friendship, Formatting.Indented);
            //    jsons.Add(json);
            //}

            //foreach (var chatUser in chatUsers)
            //{
            //    string json = JsonConvert.SerializeObject(chatUser, Formatting.Indented);
            //    jsons.Add(json);
            //}

            for (int i = 1; i <= jsons.Count; i++)
            {
                using (var writer = new StreamWriter(string.Format("Result{0}.json", i)))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }
        }
        public ConsoleService(
            ILetterFrequencyService letterFrequencyService,
            ISerializationService serializationService,
            ISocialNetworkService socialNetworkService)
        {
            _letterFrequencyService = letterFrequencyService;
            _serializationService   = serializationService;
            _socialNetworkService   = socialNetworkService;

            _inputCaptcha = url =>
            {
                SysConsole.WriteLine(CAPTCHA_UNPUT_MESSAGE);
                SysConsole.WriteLine(url);
                return(SysConsole.ReadLine());
            };
        }
 public PortfolioService(IRepository <Portfolio> _portfolioRepository,
                         ICacheManager _cacheManager,
                         IMediaStorageService _mediaStorageService,
                         IPortfolioCategoryService _categoryService,
                         IUrlService _urlService,
                         ApplicationUserService _userService,
                         ISocialNetworkService _socialNetworkService)
 {
     portfolioRepository  = _portfolioRepository;
     cacheManager         = _cacheManager;
     mediaStorageService  = _mediaStorageService;
     categoryService      = _categoryService;
     urlService           = _urlService;
     userService          = _userService;
     socialNetworkService = _socialNetworkService;
 }
Exemple #21
0
 public HomeController(IConfiguration configuration, IMemoryCache cache,
                       INewsService newsService, IVideoService videoService, IBannerService bannerService,
                       IBrandService brandService, IBranchContactService branchContactService,
                       IMenuService menuService, ISettingService settingService,
                       ISocialNetworkService socialNetworkService, ILanguageService languageService,
                       IProductService productService, ICoreValueService coreValueService)
     : base(configuration, cache, brandService, branchContactService, menuService, settingService, socialNetworkService, languageService)
 {
     _configuration  = configuration;
     _newsService    = newsService;
     _cache          = cache;
     _videoService   = videoService;
     _menuService    = menuService;
     _bannerService  = bannerService;
     _productService = productService;
     _coreService    = coreValueService;
 }
 public BlogController(ICategoryService _categoryService,
                       IPostService _postService,
                       IUrlService _urlService,
                       IPostTagService _tagService,
                       ISettingService _settingService,
                       IMediaStorageService _mediaStorageService,
                       ISocialNetworkService _socialNetworkService,
                       ApplicationUserService _userService)
 {
     categoryService      = _categoryService;
     postService          = _postService;
     urlService           = _urlService;
     tagService           = _tagService;
     settingService       = _settingService;
     mediaStorageService  = _mediaStorageService;
     socialNetworkService = _socialNetworkService;
     userService          = _userService;
 }
Exemple #23
0
        public static void Search(ISocialNetworkService searcher)
        {
            var users        = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships  = searcher.GetFriendships(2, 10);
            var chatUsers    = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var jsons = new List <string>
            {
            };

            for (int i = 1; i <= jsons.Count; i++)
            {
                using (var writer = new StreamWriter(string.Format("Result{0}.json", i)))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }
        }
Exemple #24
0
 public RoleController(ISettingService _settingService,
                       IPostService _postService,
                       IPortfolioService _portfolioService,
                       ICategoryService _categoryService,
                       IPortfolioCategoryService _portfolioCategoryService,
                       IUrlService _urlService,
                       ITeamMemberService _teamMemberService,
                       IClietTestimonialsService _testimonialsService,
                       ISocialNetworkService _socialNetworkService,
                       IMediaStorageService _mediaStorageService,
                       IPostTagService _postTagService,
                       ICacheManager _cacheManager,
                       IJobService _jobService,
                       IJobCategoryService _jobCategoryService,
                       ISubscriberService _subscriberService,
                       IApplyJobService _applyJobService,
                       IContactService _contactService)
 {
     db = new DataContext();
 }
Exemple #25
0
        public UserController(ApplicationUserService _userService,
                              ISettingService _settingService,
                              IPostService _postService,
                              IPortfolioService _portfolioService,
                              IUrlService _urlService,
                              ISocialNetworkService _socialNetworkService,
                              IMediaStorageService _mediaStorageService,
                              ICacheManager _cacheManager)
        {
            userService          = _userService;
            settingService       = _settingService;
            portfolioService     = _portfolioService;
            postService          = _postService;
            urlService           = _urlService;
            socialNetworkService = _socialNetworkService;
            mediaStorageService  = _mediaStorageService;
            cacheManager         = _cacheManager;

            db = new DataContext();
        }
        public static void Search(ISocialNetworkService searcher)
        {
            var users = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships = searcher.GetFriendships(2, 10);
            var chatUsers = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            // todo : data parsed from DATABASE, Json Data not written, not enought time left!

            var jsons = new List<string>
            {
            };

            for (int i = 1; i <= jsons.Count; i++)
            {
                using (var writer = new StreamWriter(string.Format("Result{0}.json", i)))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }
        }
Exemple #27
0
        public static void Search(ISocialNetworkService searcher)
        {
            var users        = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships  = searcher.GetFriendships(2, 10);
            var chatUsers    = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var json = new List <string>
            {
                JsonConvert.SerializeObject(users, Formatting.Indented),
                JsonConvert.SerializeObject(postsByUsers, Formatting.Indented),
                JsonConvert.SerializeObject(friendships, Formatting.Indented),
                JsonConvert.SerializeObject(chatUsers, Formatting.Indented)
            };

            for (var i = 0; i < json.Count; i++)
            {
                using (var writer = new StreamWriter($"Jsons{i + 1}.json"))
                {
                    writer.WriteLine(json[i]);
                }
            }
        }
Exemple #28
0
        public static void Search(ISocialNetworkService searcher)
        {
            var users = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships = searcher.GetFriendships(2, 10);
            var chatUsers = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var json = new List<string>
            {
                JsonConvert.SerializeObject(users,Formatting.Indented),
                JsonConvert.SerializeObject(postsByUsers,Formatting.Indented),
                JsonConvert.SerializeObject(friendships,Formatting.Indented),
                JsonConvert.SerializeObject(chatUsers,Formatting.Indented)
            };

            for (var i = 0; i < json.Count; i++)
            {
                using (var writer = new StreamWriter($"Jsons{i + 1}.json"))
                {
                    writer.WriteLine(json[i]);
                }
            }
        }
Exemple #29
0
        public static void Search(ISocialNetworkService searcher)
        {
            if (!Directory.Exists(JsonResultFiles))
            {
                Directory.CreateDirectory(JsonResultFiles);
            }

            var users        = searcher.GetUsersAfterCertainDate(2013);
            var postsByUsers = searcher.GetPostsByUser("ZtlKYHVN7h8SwMmaJs");
            var friendships  = searcher.GetFriendships(2, 10);
            var chatUsers    = searcher.GetChatUsers("ZtlKYHVN7h8SwMmaJs");

            var usersJson        = JsonConvert.SerializeObject(users, Formatting.Indented);
            var postsByUsersJson = JsonConvert.SerializeObject(postsByUsers, Formatting.Indented);
            var chatUsersJson    = JsonConvert.SerializeObject(chatUsers, Formatting.Indented);
            var friendshipsJson  = JsonConvert.SerializeObject(friendships, Formatting.Indented);


            var jsons = new List <string>
            {
                usersJson,
                postsByUsersJson,
                chatUsersJson,
                friendshipsJson
            };

            Console.WriteLine("Generating query results into /JsonResults");
            for (int i = 1; i <= jsons.Count; i++)
            {
                var filePath = Path.Combine(JsonResultFiles, string.Format("Result{0}.json", i));

                using (var writer = new StreamWriter(filePath))
                {
                    writer.WriteLine(jsons[i - 1]);
                }
            }
        }
Exemple #30
0
 public PortfolioController(ISettingService _settingService,
                            IPostService _postService,
                            IPortfolioService _portfolioService,
                            ICategoryService _categoryService,
                            IPortfolioCategoryService _portfolioCategoryService,
                            IUrlService _urlService,
                            ITeamMemberService _teamMemberService,
                            IClietTestimonialsService _testimonialsService,
                            ISocialNetworkService _socialNetworkService,
                            IMediaStorageService _mediaStorageService,
                            IPostTagService _postTagService,
                            ICacheManager _cacheManager,
                            IJobService _jobService,
                            IJobCategoryService _jobCategoryService,
                            ISubscriberService _subscriberService,
                            IApplyJobService _applyJobService,
                            IContactService _contactService)
 {
     settingService           = _settingService;
     portfolioService         = _portfolioService;
     postService              = _postService;
     categoryService          = _categoryService;
     urlService               = _urlService;
     teamMemberService        = _teamMemberService;
     testimonialsService      = _testimonialsService;
     socialNetworkService     = _socialNetworkService;
     mediaStorageService      = _mediaStorageService;
     postTagService           = _postTagService;
     portfolioCategoryService = _portfolioCategoryService;
     cacheManager             = _cacheManager;
     jobService               = _jobService;
     jobCategoryService       = _jobCategoryService;
     subscriberService        = _subscriberService;
     applyJobService          = _applyJobService;
     contactService           = _contactService;
 }
Exemple #31
0
 public HomePageSocialNetworkViewComponent(ISocialNetworkService socialNetworkService)
 {
     this._socialNetworkService = socialNetworkService;
 }
Exemple #32
0
 public AccountController(IAngoraUserService userService, ISocialNetworkService mediaPullService)
 {
     _userService      = userService;
     _mediaPullService = mediaPullService;
 }
 public CreateSocialNetworkViewComponent(ISocialNetworkService socialNetworkService)
 {
     this._socialNetworkService = socialNetworkService;
 }
 private ISocialNetworkService GetService(string token)
 {
   return _socialService ?? (_socialService = new FacebookService(token));
 }
 public SocialNetworksController(ISocialNetworkService socialNetworkService)
 {
     _socialNetworkService = socialNetworkService;
 }
Exemple #36
0
 public DataSearcher(ISocialNetworkService socialService)
 {
     this.service = socialService;
 }