private PpsDataColumnServerDefinition(PpsDataTableDefinition tableDefinition, PpsDataColumnServerDefinition clone) : base(tableDefinition, clone) { this.fieldName = clone.fieldName; this.metaInfo = new PpsDataColumnMetaCollectionServer(this, clone.metaInfo); this.fieldDescription = clone.fieldDescription; this.parentType = clone.parentType; this.parentRelationName = clone.parentRelationName; this.parentTableName = clone.parentTableName; this.parentColumnName = clone.parentColumnName; } // ctor
} // proc EndInit private static PpsRelationType GetClientRelationFromServerRelation(PpsDataColumnParentRelationType parentType) { switch (parentType) { case PpsDataColumnParentRelationType.None: return(PpsRelationType.None); case PpsDataColumnParentRelationType.Restricted: return(PpsRelationType.Restricted); case PpsDataColumnParentRelationType.SetNull: return(PpsRelationType.SetNull); default: return(PpsRelationType.Cascade); } } // func GetClientRelationFromServerRelation
} // ctor private PpsDataColumnServerDefinition(PpsDataTableDefinition tableDefinition, string fieldName, string columnName, bool isPrimaryKey, bool isIdentity, bool createRelationColumn, XElement config) : base(tableDefinition, columnName, isPrimaryKey, isIdentity) { this.fieldName = fieldName; // relation if (createRelationColumn) { this.parentRelationName = config.GetAttribute("relationName", (string)null); this.parentType = config.GetAttribute("parentType", PpsDataColumnParentRelationType.None); this.parentTableName = config.GetAttribute("parentTable", (string)null); this.parentColumnName = config.GetAttribute("parentColumn", (string)null); } else { this.parentRelationName = null; this.parentType = PpsDataColumnParentRelationType.None; this.parentTableName = null; this.parentColumnName = null; } this.metaInfo = new PpsDataColumnMetaCollectionServer(this, config); } // ctor