コード例 #1
0
ファイル: ModificaDatiViewModel.cs プロジェクト: Dr-Dd/RentIT
 public ModificaDatiViewModel(INavService navService, UserService userService, FotoService fotoService) : base(navService)
 {
     _userService = userService;
     _fotoService = fotoService;
     Immagine     = new Image();
     ListaCitta   = MiscCostants.tutteCitta;
 }
コード例 #2
0
 public AnnunciUtenteViewModel(INavService navService, AnnuncioService annuncioService, FotoService fotoService) : base(navService)
 {
     _annuncioService    = annuncioService;
     _fotoService        = fotoService;
     AnnunciPrenotati    = new ObservableCollection <Ad>();
     AnnunciNonPrenotati = new ObservableCollection <Ad>();
 }
コード例 #3
0
 public MainViewModel(FotoService service)
 {
     this.service             = service;
     GetAlbenCommand          = new RelayCommand(GetAllAlben);
     GetFotosFromAlbumCommand = new RelayCommand(GetFotosFromAlbum);
     SearchtextChangedCommand = new RelayCommand(FilterAlbum);
 }
コード例 #4
0
 public AggiungiAnnuncioViewModel(INavService navService, FotoService fotoService, AnnuncioService annuncioService) : base(navService)
 {
     _fotoService          = fotoService;
     _annuncioService      = annuncioService;
     Immagini              = new ObservableCollection <Image>();
     listaImmaginiInBase64 = new List <string>();
 }
コード例 #5
0
 public UtentePageViewModel(INavService navService, AuthenticationService authService, UserService userService, FotoService fotoService, AnnuncioService annuncioService) : base(navService)
 {
     _authService     = authService;
     _userService     = userService;
     _fotoService     = fotoService;
     _annuncioService = annuncioService;
     Immagine         = new Image();
 }
コード例 #6
0
ファイル: RentITCoreModule.cs プロジェクト: Dr-Dd/RentIT
        public override void Load()
        {
            // Carico i ViewModels
            Bind <LoginPageViewModel>().ToSelf();
            Bind <SearchPageViewModel>().ToSelf();
            Bind <SubmitPageViewModel>().ToSelf();
            Bind <AnnunciPageViewModel>().ToSelf();
            Bind <UtentePageViewModel>().ToSelf();
            Bind <DettaglioAnnuncioViewModel>().ToSelf();
            Bind <AggiungiAnnuncioViewModel>().ToSelf();
            Bind <ModificaDatiViewModel>().ToSelf();
            Bind <AnnunciUtenteViewModel>().ToSelf();
            Bind <GestioneAnnuncioViewModel>().ToSelf();
            Bind <InfoUtenteViewModel>().ToSelf();
            Bind <AnnunciQueryViewModel>().ToSelf();

            // E' importante fare il binding di tutti i servizi che
            // non servono in quantità molteplice nelle injection

            // Qui crei le istanze
            var requestService = new RequestService();
            var authService    = new AuthenticationService(requestService);
            var userService    = new UserService(requestService);
            var fotoService    = new FotoService(requestService);

            // Qui gli fai il binding come singoletto
            Bind <IRequestService>().
            ToMethod(x => requestService)
            .InSingletonScope();

            // ***
            Bind <IAuthenticationService>()
            .ToMethod(x => authService)
            .InSingletonScope();

            // ***
            Bind <IUserService>()
            .ToMethod(x => userService)
            .InSingletonScope();

            // ***
            Bind <IFotoService>()
            .ToMethod(x => fotoService)
            .InSingletonScope();
        }
コード例 #7
0
 public LoginController()
 {
     uS = new UsuarioServiceImp();
     fS = new FotoServiceImp();
 }
コード例 #8
0
 public DettaglioAnnuncioViewModel(INavService navService, FotoService fotoService, UserService userService) : base(navService)
 {
     _fotoService = fotoService;
     _userService = userService;
     Immagini     = new List <Image>();
 }
コード例 #9
0
 public FotoController()
 {
     fS = new FotoServiceImp();
     uS = new UsuarioServiceImp();
 }
コード例 #10
0
 public InfoUtenteViewModel(INavService navService, AnnuncioService annuncioService, FotoService fotoService, UserService utenteService) : base(navService)
 {
     _annuncioService = annuncioService;
     _fotoService     = fotoService;
     _utenteService   = utenteService;
 }
コード例 #11
0
ファイル: AnnunciPageViewModel.cs プロジェクト: Dr-Dd/RentIT
 public AnnunciPageViewModel(INavService navService, AnnuncioService annuncioService, FotoService fotoService) : base(navService)
 {
     _annuncioService = annuncioService;
     _fotoService     = fotoService;
     Annunci          = new ObservableCollection <Ad>();
 }
コード例 #12
0
 public GestioneAnnuncioViewModel(INavService navService, AnnuncioService annuncioService, FotoService fotoService) : base(navService)
 {
     _annuncioService = annuncioService;
     _fotoService     = fotoService;
     Immagini         = new List <Image>();
 }