Ejemplo n.º 1
0
        internal Field(Model.Field modelField, PropertyMatcherViewModel viewModel, ConnectionDirection direction)
        {
            ModelField = modelField;
            ViewModel  = viewModel;
            Direction  = direction;

            _selectionStatus = SelectionStatus.NotSelected;
            Disconnect       = new DisconnectCommand(this);
        }
        private static ObservableCollection <ViewModel.Field> GetViewModelFields(
            Model.Table fieldCollection,
            PropertyMatcherViewModel viewModel,
            Field.ConnectionDirection direction)
        {
            var fieldEnumerable = fieldCollection.Fields.Select(p => new Field(p, viewModel, direction));

            return(new ObservableCollection <Field>(fieldEnumerable));
        }