コード例 #1
0
        public ScheduleSlotViewModel(Time time, Individual individual, Schedule schedule, SelectionModel selection)
        {
            _time = time;
            _individual = individual;
            _schedule = schedule;
            _selection = selection;

            _sessionPlace = new Dependent<SessionPlace>(() => SessionPlace);
        }
コード例 #2
0
 public ScheduleTimeViewModel(
     Time time,
     Individual individual,
     SelectionModel selection,
     Func<Time, Schedule, ScheduleSlotViewModel> newScheduleSlot)
 {
     _time = time;
     _individual = individual;
     _selection = selection;
     _newScheduleSlot = newScheduleSlot;
 }
コード例 #3
0
ファイル: Conference.cs プロジェクト: michaellperry/MyCon
 public void NewGeneralSessionPlace(string sessionName, Time time, string roomNumber, string imageUrl)
 {
     Speaker speaker = Community.AddFact(new Speaker(this, string.Empty));
     if (speaker.ImageUrl.Value != imageUrl)
         speaker.ImageUrl = imageUrl;
     Session session = Community.AddFact(new Session(this, speaker, null));
     if (session.Name.Value != sessionName)
         session.Name = sessionName;
     Room room = GetRoom(roomNumber);
     Place place = Community.AddFact(new Place(time, room));
     Community.AddFact(new SessionPlace(session, place, new List<SessionPlace>()));
 }
コード例 #4
0
ファイル: Container.cs プロジェクト: michaellperry/MyCon
        public static AvailableSessionsViewModel CreateViewModel(
            Time time,
            Individual individual,
            SelectionModel selectionModel)
        {
            Frame frame = null;
            if (Window.Current != null)
                frame = Window.Current.Content as Frame;

            Action showSession = () =>
            {
                if (frame != null)
                    frame.Navigate(typeof(SessionView));
            };

            Func<SessionPlace, SessionHeaderViewModel> newSessionHeaderViewModel = sessionPlace =>
                new SessionHeaderViewModel(sessionPlace, individual, selectionModel, showSession);

            return new AvailableSessionsViewModel(time, newSessionHeaderViewModel);
        }
コード例 #5
0
 public ScheduleSlotViewModel(Attendee attendee, Time time, ImageCache imageCache)
 {
     _attendee = attendee;
     _time = time;
     _imageCache = imageCache;
 }
コード例 #6
0
 public TimeDetailsViewModel(Time time)
 {
     _time = time;
 }
コード例 #7
0
 // Fields
 // Results
 // Business constructor
 public TimeDelete(
     Time deleted
     )
 {
     _unique = Guid.NewGuid();
     InitializeResults();
     _deleted = new PredecessorObj<Time>(this, GetRoleDeleted(), deleted);
 }
コード例 #8
0
            public CorrespondenceFact CreateFact(FactMemento memento)
            {
                Time newFact = new Time(memento);

                // Create a memory stream from the memento data.
                using (MemoryStream data = new MemoryStream(memento.Data))
                {
                    using (BinaryReader output = new BinaryReader(data))
                    {
                        newFact._start = (DateTime)_fieldSerializerByType[typeof(DateTime)].ReadData(output);
                    }
                }

                return newFact;
            }
コード例 #9
0
 public AvailableSessionsViewModel(Time time, Func<SessionPlace, SessionHeaderViewModel> newSessionHeaderViewModel)
 {
     _time = time;
     _newSessionHeaderViewModel = newSessionHeaderViewModel;
 }
コード例 #10
0
 // Business constructor
 public Place(
     Time placeTime
     ,Room room
     )
 {
     InitializeResults();
     _placeTime = new PredecessorObj<Time>(this, GetRolePlaceTime(), placeTime);
     _room = new PredecessorObj<Room>(this, GetRoleRoom(), room);
 }
コード例 #11
0
 public ScheduleColumnHeaderViewModel(Time time)
 {
     _time = time;
 }
コード例 #12
0
ファイル: Session.cs プロジェクト: michaellperry/MyCon
 public void SetSessionPlace(Time time, string roomNumber)
 {
     Room room = Conference.GetRoom(roomNumber);
     Place place = Community.AddFact(new Place(time, room));
     SetPlace(place);
 }
コード例 #13
0
 // Results
 // Business constructor
 public Time__startTime(
     Time time
     ,IEnumerable<Time__startTime> prior
     ,DateTime value
     )
 {
     InitializeResults();
     _time = new PredecessorObj<Time>(this, GetRoleTime(), time);
     _prior = new PredecessorList<Time__startTime>(this, GetRolePrior(), prior);
     _value = value;
 }
コード例 #14
0
 // Fields
 // Results
 // Business constructor
 public Slot(
     Time slotTime
     ,Room room
     )
 {
     InitializeResults();
     _slotTime = new PredecessorObj<Time>(this, GetRoleSlotTime(), slotTime);
     _room = new PredecessorObj<Room>(this, GetRoleRoom(), room);
 }
コード例 #15
0
ファイル: Attendee.cs プロジェクト: michaellperry/MyCon
 public Task<Slot> NewSlot(Time time)
 {
     return Community.AddFactAsync(new Slot(this, time));
 }
コード例 #16
0
 // Business constructor
 public Slot(
     Attendee attendee
     ,Time slotTime
     )
 {
     InitializeResults();
     _attendee = new PredecessorObj<Attendee>(this, GetRoleAttendee(), attendee);
     _slotTime = new PredecessorObj<Time>(this, GetRoleSlotTime(), slotTime);
 }
コード例 #17
0
ファイル: SlotViewModel.cs プロジェクト: michaellperry/MyCon
 public SlotViewModel(Time time, ImageCache imageCache)
 {
     _time = time;
     _imageCache = imageCache;
 }
コード例 #18
0
ファイル: TimeViewModel.cs プロジェクト: michaellperry/MyCon
 public TimeViewModel(Time time)
 {
     _time = time;
 }