Ejemplo n.º 1
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="origin"></param>
 public void Update(Origin origin)
 {
    if (origin == null)
         throw new ArgumentNullException("origin");
    _dataContext.SubmitChanges();
         
 }
Ejemplo n.º 2
0
        public OriginViewModel(Origin origin, OriginService originService)
        {
            if (origin == null)
                throw new ArgumentNullException("origin");

            if (originService == null)
                throw new ArgumentNullException("originService");

            _origin = origin;
            _originService = originService;
           // _customerType = Strings.CustomerViewModel_CustomerTypeOption_NotSpecified;
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Places the specified origin into the repository.
        /// If the origin is already in the repository, an
        /// exception is not thrown.
        /// </summary>
        public void Insert(Origin origin)
        {
            if (origin == null)
                throw new ArgumentNullException("origin");

            if (!_origins.Contains(origin))
            {
                _origins.Add(origin);
                _dataContext.Origins.InsertOnSubmit(origin);
                _dataContext.SubmitChanges();
                if (this.OriginAdded != null)
                    this.OriginAdded(this, new EntityAddedEventArgs<Origin>(origin));
            }
        }
Ejemplo n.º 4
0
  public OriginViewModel(Origin origin, OriginService originService, ObservableCollection<WorkspaceViewModel> parent):this(origin,originService)
 {
     parentWorkSpaces = parent;
 }
Ejemplo n.º 5
0
        /// <summary>
        /// Returns true if the specified origin exists in the
        /// repository, or false if it is not.
        /// </summary>
        public bool ContainsOrigin(Origin origin)
        {
            if (origin == null)
                throw new ArgumentNullException("origin");

            return _origins.Contains(origin);
        }
Ejemplo n.º 6
0
        /// <summary>
        /// 
        /// </summary>
        /// <param name="origin"></param>
        public void Delete(Origin origin)
        {

        }