Ejemplo n.º 1
0
 public SendNotificationObject(string senderUserName, NotificationData notificationData, NotificationType.NotificationTypes notificationType)
 {
     SenderUserName   = senderUserName;
     NotificationData = notificationData;
     NotificationName = NotificationResolver.ResolveNotification(notificationType);
     NotificationType = notificationType;
 }
        public Models.PaginatedCollection <Models.FlatOffer> Get(Models.FlatOffersSearchParams query)
        {
            var offers = _getFlatOffers.Get(new GetFlatOffersQuery {
                FlatType      = query.FlatType?.ToEnum <FlatType>(),
                MaxPrice      = query.MaxPrice,
                MinFlatSize   = query.MinFlatSize,
                NumberOfRooms = query.RoomCount,
                Pagination    = new Common.ValueTypes.QueryPagination(query.PageNumber, query.PageSize)
            });

            return(new Models.PaginatedCollection <Models.FlatOffer>
            {
                Results = offers.Results.Select(x => new Models.FlatOffer
                {
                    Id = x.Id.Value,
                    Address = x.Address,
                    NumberOfRooms = x.NumberOfRooms,
                    FlatSize = x.FlatSize,
                    FlatType = x.FlatType.ToString(),
                    Price = x.Price,
                    NotificationType = NotificationResolver.ResolveNotification(x.Notifications),
                    Url = x.Links.First().Url
                }),
                PageNumber = offers.PageNumber,
                PageCount = offers.PageCount
            });
        }
Ejemplo n.º 3
0
        public DirectXUi(IGame game, WorldContainer worldContainer)
        {
#if GPU_DEBUG
            SharpDX.Configuration.EnableObjectTracking = true;
#endif
            _game                 = game;
            _worldContainer       = worldContainer;
            _timer                = new Toolkit.Timer();
            _notificationResolver = new NotificationResolver();
        }
Ejemplo n.º 4
0
 public Context(RenderForm form, Dx11 directX, IGame game, WorldContainer worldContainer, IUiManager uiManager, IInput input, Camera camera, NotificationResolver notificationResolver, DataLock datalock)
 {
     _worldContainer      = worldContainer;
     NotificationResolver = notificationResolver;
     Form           = form;
     DirectX        = directX;
     Game           = game;
     TextureManager = new TextureManager(DirectX.Device);
     TextManager    = new TextManager(this);
     Shaders        = new ShaderManager(DirectX.Device);
     Camera         = camera;
     UiManager      = uiManager;
     Input          = input;
     DataLock       = datalock;
 }