Beispiel #1
0
        /// <summary>
        /// Copies member variables
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(TableValuedFunction old)
        {
            this.ObjectType = old.ObjectType;

            this.columns    = new LazyProperty <ConcurrentDictionary <string, Column> >(LoadColumns);
            this.parameters = new LazyProperty <ConcurrentDictionary <string, Parameter> >(LoadParameters);
        }
Beispiel #2
0
        private void InitializeMembers(StreamingContext context)
        {
            this.ObjectType = DatabaseObjectType.TableValuedFunction;

            this.columns    = new LazyProperty <ConcurrentDictionary <string, Column> >(LoadColumns);
            this.parameters = new LazyProperty <ConcurrentDictionary <string, Parameter> >(LoadParameters);
        }
Beispiel #3
0
        /// <summary>
        /// Copies member variables
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(TableOrView old)
        {
            this.ObjectType = old.ObjectType;

            this.columns    = new LazyProperty <ConcurrentDictionary <string, Column> >(LoadColumns);
            this.indexes    = new LazyProperty <ConcurrentDictionary <string, Index> >(LoadIndexes);
            this.statistics = new LazyProperty <TableStatistics>(LoadStatistics);
        }
Beispiel #4
0
        private void InitializeMembers(StreamingContext context)
        {
            this.ObjectType = DatabaseObjectType.Unknown;

            this.columns    = new LazyProperty <ConcurrentDictionary <string, Column> >(LoadColumns);
            this.indexes    = new LazyProperty <ConcurrentDictionary <string, Index> >(LoadIndexes);
            this.statistics = new LazyProperty <TableStatistics>(LoadStatistics);
        }
Beispiel #5
0
 private void InitializeMembers(StreamingContext context)
 {
     this.parent   = null;
     this.id       = -1;
     this.name     = String.Empty;
     this.dataType = null;
     this.metadata = new LazyProperty <VariableMetadata>(LoadMetadata);
 }
Beispiel #6
0
 private void CopyMembers(Variable old)
 {
     this.parent   = old.parent;
     this.id       = old.id;
     this.name     = old.name;
     this.dataType = old.dataType;
     this.metadata = new LazyProperty <VariableMetadata>(LoadMetadata);
 }
        /// <summary>
        /// Copies member variable from an existing object
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(DatabaseObject old)
        {
            this.cachedVersion = DateTime.Now.Ticks;
            this.objectType    = old.objectType;
            this.dataset       = old.dataset;
            this.databaseName  = old.databaseName;
            this.schemaName    = old.schemaName;
            this.objectName    = old.objectName;

            this.metadata = new LazyProperty <DatabaseObjectMetadata>(LoadMetadata);
        }
        private void InitializeMembers(StreamingContext context)
        {
            this.cachedVersion = DateTime.Now.Ticks;
            this.objectType    = DatabaseObjectType.Unknown;
            this.dataset       = null;
            this.databaseName  = null;
            this.schemaName    = null;
            this.objectName    = null;

            this.metadata = new LazyProperty <DatabaseObjectMetadata>(LoadMetadata);
        }
Beispiel #9
0
        private void InitializeMembers(StreamingContext context)
        {
            this.cachedVersion = DateTime.Now.Ticks;

            this.isCacheable       = false;
            this.name              = String.Empty;
            this.defaultSchemaName = String.Empty;

            this.connectionString = null;

            this.tables = new DatabaseObjectCollection <Table>(this);
            this.views  = new DatabaseObjectCollection <View>(this);
            this.tableValuedFunctions = new DatabaseObjectCollection <TableValuedFunction>(this);
            this.scalarFunctions      = new DatabaseObjectCollection <ScalarFunction>(this);
            this.storedProcedures     = new DatabaseObjectCollection <StoredProcedure>(this);

            this.statistics = new LazyProperty <DatasetStatistics>(LoadDatasetStatistics);
            this.metadata   = new LazyProperty <DatasetMetadata>(LoadDatasetMetadata);

            InitializeEventHandlers();
        }
Beispiel #10
0
        /// <summary>
        /// Copies member variables
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(DatasetBase old)
        {
            this.cachedVersion = DateTime.Now.Ticks;

            this.isCacheable       = old.isCacheable;
            this.name              = old.name;
            this.defaultSchemaName = old.defaultSchemaName;

            this.connectionString = old.connectionString;

            // No deep copy here
            this.tables = new DatabaseObjectCollection <Table>(this);
            this.views  = new DatabaseObjectCollection <View>(this);
            this.tableValuedFunctions = new DatabaseObjectCollection <TableValuedFunction>(this);
            this.scalarFunctions      = new DatabaseObjectCollection <ScalarFunction>(this);
            this.storedProcedures     = new DatabaseObjectCollection <StoredProcedure>(this);

            this.statistics = new LazyProperty <DatasetStatistics>(LoadDatasetStatistics);
            this.metadata   = new LazyProperty <DatasetMetadata>(LoadDatasetMetadata);

            InitializeEventHandlers();
        }
Beispiel #11
0
        protected override void InitializeValues()
        {
            description_ =
                new LazyProperty <object>(this
                                          , "Description"
                                          , () => Activity.DescriptionProperty.RawValue
                                          , (x) => Activity.DescriptionProperty.Value = x
                                          , (x) => x != Activity.DescriptionProperty.RawValue
                                          , (x) => NotifyPropertyChanged(new PropertyChangedEventArgs("Description")));

            from_ =
                new LazyProperty <object>(this
                                          , "From"
                                          , () => Activity.FromProperty.RawValue
                                          , (x) => Activity.FromProperty.Value = x
                                          , (x) => x != Activity.FromProperty.RawValue
                                          , (x) => NotifyPropertyChanged(new PropertyChangedEventArgs("From")));

            to_ =
                new LazyProperty <object>(this
                                          , "To"
                                          , () => Activity.ToProperty.RawValue
                                          , (x) => Activity.ToProperty.Value = x
                                          , (x) => x != Activity.ToProperty.RawValue
                                          , (x) => NotifyPropertyChanged(new PropertyChangedEventArgs("To")));

            incurred_ =
                new LazyValue <ItemObjectViewList <Expense, ExpenseView> >(() =>
            {
                var list = new ItemObjectViewList <Expense, ExpenseView>
                               (Activity.Incurred.GetItemObjectCollection(null, null, null)
                               , (x) => new ExpenseView(x, false, false));
                list.ListChanged += (object sender, EventArgs e) => NotifyPropertyChanged(new PropertyChangedEventArgs("Incurred"));
                return(list);
            });
            OnInitialize();
        }
Beispiel #12
0
 private void InitializeMembers()
 {
     this.parent = null;
     this.id = -1;
     this.name = String.Empty;
     this.dataType = null;
     this.metadata = new LazyProperty<VariableMetadata>(LoadMetadata);
 }
Beispiel #13
0
 private void CopyMembers(Variable old)
 {
     this.parent = old.parent;
     this.id = old.id;
     this.name = old.name;
     this.dataType = old.dataType;
     this.metadata = new LazyProperty<VariableMetadata>(LoadMetadata);
 }
Beispiel #14
0
 /// <summary>
 /// Initializes member variables
 /// </summary>
 private void InitializeMembers()
 {
     this.ObjectType = DatabaseObjectType.ScalarFunction;
     this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
 }
Beispiel #15
0
 /// <summary>
 /// Copies member variables
 /// </summary>
 /// <param name="old"></param>
 private void CopyMembers(ScalarFunction old)
 {
     this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
 }
Beispiel #16
0
 private void InitializeMembers(StreamingContext context)
 {
     this.ObjectType = DatabaseObjectType.ScalarFunction;
     this.parameters = new LazyProperty <ConcurrentDictionary <string, Parameter> >(LoadParameters);
 }
Beispiel #17
0
 /// <summary>
 /// Copies member variables
 /// </summary>
 /// <param name="old"></param>
 private void CopyMembers(ScalarFunction old)
 {
     this.parameters = new LazyProperty <ConcurrentDictionary <string, Parameter> >(LoadParameters);
 }
Beispiel #18
0
        private void InitializeMembers(StreamingContext context)
        {
            this.cachedVersion = DateTime.Now.Ticks;
            this.objectType = DatabaseObjectType.Unknown;
            this.dataset = null;
            this.databaseName = null;
            this.schemaName = null;
            this.objectName = null;

            this.metadata = new LazyProperty<DatabaseObjectMetadata>(LoadMetadata);
        }
Beispiel #19
0
 /// <summary>
 /// Copies member variables.
 /// </summary>
 /// <param name="old"></param>
 private void CopyMembers(StoredProcedure old)
 {
     this.ObjectType = old.ObjectType;
     this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
 }
Beispiel #20
0
        /// <summary>
        /// Copies member variables
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(TableOrView old)
        {
            this.ObjectType = old.ObjectType;

            this.columns = new LazyProperty<ConcurrentDictionary<string, Column>>(LoadColumns);
            this.indexes = new LazyProperty<ConcurrentDictionary<string, Index>>(LoadIndexes);
            this.statistics = new LazyProperty<TableStatistics>(LoadStatistics);
        }
Beispiel #21
0
 /// <summary>
 /// Copies member variables.
 /// </summary>
 /// <param name="old"></param>
 private void CopyMembers(StoredProcedure old)
 {
     this.ObjectType = old.ObjectType;
     this.parameters = new LazyProperty <ConcurrentDictionary <string, Parameter> >(LoadParameters);
 }
        /// <summary>
        /// Copies member variables
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(TableValuedFunction old)
        {
            this.ObjectType = old.ObjectType;

            this.columns = new LazyProperty<ConcurrentDictionary<string, Column>>(LoadColumns);
            this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
        }
Beispiel #23
0
        /// <summary>
        /// Copies member variable from an existing object
        /// </summary>
        /// <param name="old"></param>
        private void CopyMembers(DatabaseObject old)
        {
            this.cachedVersion = DateTime.Now.Ticks;
            this.objectType = old.objectType;
            this.dataset = old.dataset;
            this.databaseName = old.databaseName;
            this.schemaName = old.schemaName;
            this.objectName = old.objectName;

            this.metadata = new LazyProperty<DatabaseObjectMetadata>(LoadMetadata);
        }
Beispiel #24
0
        /// <summary>
        /// Initializes member variables to their default values
        /// </summary>
        private void InitializeMembers()
        {
            this.ObjectType = DatabaseObjectType.Unknown;

            this.columns = new LazyProperty<ConcurrentDictionary<string, Column>>(LoadColumns);
            this.indexes = new LazyProperty<ConcurrentDictionary<string, Index>>(LoadIndexes);
            this.statistics = new LazyProperty<TableStatistics>(LoadStatistics);
        }
        private void InitializeMembers(StreamingContext context)
        {
            this.ObjectType = DatabaseObjectType.TableValuedFunction;

            this.columns = new LazyProperty<ConcurrentDictionary<string, Column>>(LoadColumns);
            this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
        }
Beispiel #26
0
 private void InitializeMembers(StreamingContext context)
 {
     this.ObjectType = DatabaseObjectType.StoredProcedure;
     this.parameters = new LazyProperty<ConcurrentDictionary<string, Parameter>>(LoadParameters);
 }