Ejemplo n.º 1
0
 public override void Load(VenueDocument document)
 {
     address = Address.Parse(document.Address);
     contact = Contact.Parse(document.VenueContact);
     map     = new VenueMap(new Uri(document.VenueMap));
     name    = new VenueName(document.VenueName);
 }
Ejemplo n.º 2
0
 public Venue(Id id, Version version, VenueName name, Address address, VenueMap map, Contact contact) : base(id, version)
 {
     this.address = address;
     this.contact = contact;
     this.map     = map;
     this.name    = name;
 }
Ejemplo n.º 3
0
 public AddVenueCommand(string venueName, string address, string mapURN, string contact) : base(Guid.NewGuid())
 {
     Address = Address.Parse(address);
     Contact = Contact.Parse(contact);
     VenueMap = new VenueMap(new Uri(mapURN != null ? mapURN : "http://maps.google.co.uk"));
     VenueName = new VenueName(venueName);
     Version = new Version(1);
 }
Ejemplo n.º 4
0
 public UpdateVenueCommand(Guid id, string venueName, string address, string mapURN, string contact, int version)
 {
     Id = new Id(id);
     Address = Address.Parse(address);
     Contact = Contact.Parse(contact);
     VenueMap = new VenueMap(new Uri(mapURN != null ? mapURN : "http://maps.google.co.uk"));
     VenueName = new VenueName(venueName);
     Version = new Version(version);
 }
Ejemplo n.º 5
0
 public VenueDocument(Id id, Version version, VenueName venueName, Address address, VenueMap venueMap, Contact contact)
 {
     Id = (Guid)id;
     Version = (int) version;
     VenueName = (string) venueName;
     Address = (string) address;
     VenueMap = (string) venueMap;
     VenueContact = (string) contact;
 }
Ejemplo n.º 6
0
        public void Update(VenueName venueName, Address address, Contact contact, VenueMap venueMap)
        {
            this.name    = venueName;
            this.address = address;
            this.contact = contact;
            this.map     = venueMap;

            version = version++;
        }
Ejemplo n.º 7
0
 public VenueDocument(Id id, Version version, VenueName venueName, Address address, VenueMap venueMap, Contact contact)
 {
     Id           = (Guid)id;
     Version      = (int)version;
     VenueName    = (string)venueName;
     Address      = (string)address;
     VenueMap     = (string)venueMap;
     VenueContact = (string)contact;
 }
Ejemplo n.º 8
0
 public Venue(Version version, VenueName name, Address address, VenueMap map, Contact contact)
     : this(new Id(), version, name, address, map, contact)
 {
 }