public CloneTableFieldDefInfo CreateTargetFAUTO(string lpszName, int nType, UInt32 versFrom = 0, UInt32 versDrop = 9999)
        {
            TableFieldDefInfo fieldInfo = TableDefInfo.CreateFAUTOInfo(lpszName, nType, versFrom, versDrop);

            CloneTableFieldDefInfo fieldClone = new CloneTableFieldDefInfo(null, fieldInfo);

            return(FieldInsertBeg(fieldClone));
        }
 public CloneTableFieldDefInfo(TableFieldDefInfo sourceField, TableFieldDefInfo targetField)
 {
     m_source = null;
     m_target = null;
     if (sourceField != null)
     {
         m_source = (TableFieldDefInfo)sourceField.Clone();
     }
     if (targetField != null)
     {
         m_target = (TableFieldDefInfo)targetField.Clone();
     }
 }
Esempio n. 3
0
        public QueryTableDefInfo AddColumn(NameInfo columnName)
        {
            QueryTableDefInfo other = (QueryTableDefInfo)this.MemberwiseClone();

            other.m_QueryTableInfo = this.m_QueryTableInfo;
            other.m_strName        = this.m_strName;
            other.m_strAliasName   = this.m_strAliasName;
            TableFieldDefInfo tabColumn = other.m_QueryTableInfo.FieldByName(columnName.Name);
            QueryFieldDefInfo addColumn = new QueryFieldDefInfo(tabColumn, columnName.Alias, columnName.Function);

            other.m_QueryFields = this.m_QueryFields.Concat(new List <QueryFieldDefInfo>()
            {
                addColumn
            }).ToList();

            return(other);
        }
Esempio n. 4
0
        public QueryTableDefInfo AddColumns(params NameInfo[] columnNames)
        {
            QueryTableDefInfo other = (QueryTableDefInfo)this.MemberwiseClone();

            other.m_QueryTableInfo = this.m_QueryTableInfo;
            other.m_strName        = this.m_strName;
            other.m_strAliasName   = this.m_strAliasName;

            IList <QueryFieldDefInfo> listQueryFields = this.m_QueryFields.ToList();

            foreach (var columnName in columnNames)
            {
                TableFieldDefInfo tabColumn = other.m_QueryTableInfo.FieldByName(columnName.Name);
                QueryFieldDefInfo addColumn = new QueryFieldDefInfo(tabColumn, columnName.Alias, columnName.Function);
                listQueryFields.Add(addColumn);
            }
            other.m_QueryFields = listQueryFields;
            return(other);
        }
        public object Clone()
        {
            TableFieldDefInfo other = (TableFieldDefInfo)this.MemberwiseClone();

            other.m_strName = this.m_strName;
            other.m_nType   = this.m_nType;

            other.m_lCollatingOrder   = this.m_lCollatingOrder;
            other.m_nOrdinalPosition  = this.m_nOrdinalPosition;
            other.m_strDefaultValue   = this.m_strDefaultValue;
            other.m_strValidationRule = this.m_strValidationRule;
            other.m_strValidationText = this.m_strValidationText;
            other.m_lAttributes       = this.m_lAttributes;
            other.m_lSize             = this.m_lSize;
            other.m_bRequired         = this.m_bRequired;
            other.m_bAllowZeroLength  = this.m_bAllowZeroLength;
            other.m_VersFrom          = this.m_VersFrom;
            other.m_VersDrop          = this.m_VersDrop;

            return(other);
        }
 public CloneTableFieldDefInfo(TableFieldDefInfo fieldInfo)
 {
     m_source = (TableFieldDefInfo)fieldInfo.Clone();
     m_target = (TableFieldDefInfo)fieldInfo.Clone();
 }