C# 클래스 Azavea.Open.DAO.ClassMapping

Represents a mapping of a class onto a database table.
파일 보기 프로젝트 열기: azavea/net-dao 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
AllDataColsByObjAttrs string>.IDictionary
AllDataColsByObjMemberInfo string>.IDictionary
AllDataColsInOrder IList
AllObjAttrsByDataCol string>.IDictionary
AllObjMemberInfosByDataCol MemberInfo>.IDictionary
AllObjMemberInfosByObjAttr MemberInfo>.IDictionary
ClassType System.Type
Constructor System.Reflection.ConstructorInfo
DataColTypesByDataCol Type>.IDictionary
DataColTypesByObjAttr Type>.IDictionary
IdDataColsByObjAttrs string>.IDictionary
IdDataColsByObjMemberInfo string>.IDictionary
IdGeneratorsByDataCol GeneratorType>.IDictionary
IdSequencesByDataCol string>.IDictionary
NonIdDataColsByObjAttrs string>.IDictionary
NonIdDataColsByObjMemberInfo string>.IDictionary
Table string
TypeName string

공개 메소드들

메소드 설명
ClassMapping ( XmlNode hibConfNode ) : System

Construct it from an NHibernate config's "class" node. Will not include foreign keys by default.

ClassMapping ( XmlNode hibConfNode, bool reflect ) : System

Construct it from an NHibernate config's "class" node. This allows you to skip using reflection to populate the class info, if for example your Dao doesn't use it for some reason. Will not include foreign keys by default.

ClassMapping ( XmlNode hibConfNode, bool reflect, bool includeForeignKeys ) : System

Construct it from an NHibernate config's "class" node. This allows you to skip using reflection to populate the class info, if for example your Dao doesn't use it for some reason. This also allows you to specify whether to include many-to-one and one-to-one links as properties (may break FastDAO since the type of the attribute on the object will need to be the foreign key type (I.E. int) rather than the real object type of the relationship, which is what NHibernate expects).

ClassMapping ( string typeName, string tableName, IEnumerable colDefinitions ) : System

A constructor that allows you to explicitly declare the type, table name, and column mappings, without using an XML mapping string. (e.g. if you want to store mapping info in a database)

ClassMapping ( string typeName, string tableName, IEnumerable colDefinitions, bool reflect ) : System

A constructor that allows you to explicitly declare the type, table name, and column mappings, without using an XML mapping string. (e.g. if you want to store mapping info in a database)

ToString ( ) : string

Returns the class mapping type name and table name.

비공개 메소드들

메소드 설명
ParseColumnType ( string input ) : Type
ParseNHibernateXML ( XmlNode hibConfNode, bool includeForeignKeys ) : void
ReflectOnTypeInfo ( ) : void

메소드 상세

ClassMapping() 공개 메소드

Construct it from an NHibernate config's "class" node. Will not include foreign keys by default.
public ClassMapping ( XmlNode hibConfNode ) : System
hibConfNode System.Xml.XmlNode The XML configuration.
리턴 System

ClassMapping() 공개 메소드

Construct it from an NHibernate config's "class" node. This allows you to skip using reflection to populate the class info, if for example your Dao doesn't use it for some reason. Will not include foreign keys by default.
public ClassMapping ( XmlNode hibConfNode, bool reflect ) : System
hibConfNode System.Xml.XmlNode The XML configuration.
reflect bool Whether or not to use reflection to populate all the class info.
리턴 System

ClassMapping() 공개 메소드

Construct it from an NHibernate config's "class" node. This allows you to skip using reflection to populate the class info, if for example your Dao doesn't use it for some reason. This also allows you to specify whether to include many-to-one and one-to-one links as properties (may break FastDAO since the type of the attribute on the object will need to be the foreign key type (I.E. int) rather than the real object type of the relationship, which is what NHibernate expects).
public ClassMapping ( XmlNode hibConfNode, bool reflect, bool includeForeignKeys ) : System
hibConfNode System.Xml.XmlNode The XML configuration.
reflect bool Whether or not to use reflection to populate all the class info.
includeForeignKeys bool If true, many-to-one and one-to-one /// links will be included as properties.
리턴 System

ClassMapping() 공개 메소드

A constructor that allows you to explicitly declare the type, table name, and column mappings, without using an XML mapping string. (e.g. if you want to store mapping info in a database)
public ClassMapping ( string typeName, string tableName, IEnumerable colDefinitions ) : System
typeName string The fully-qualified Class,Assembly type name for the object.
tableName string The data source table name.
colDefinitions IEnumerable List of column mappings.
리턴 System

ClassMapping() 공개 메소드

A constructor that allows you to explicitly declare the type, table name, and column mappings, without using an XML mapping string. (e.g. if you want to store mapping info in a database)
public ClassMapping ( string typeName, string tableName, IEnumerable colDefinitions, bool reflect ) : System
typeName string The fully-qualified Class,Assembly type name for the object.
tableName string The data source table name.
colDefinitions IEnumerable List of column mappings.
reflect bool Whether or not to use reflection to populate all the class info.
리턴 System

ToString() 공개 메소드

Returns the class mapping type name and table name.
public ToString ( ) : string
리턴 string

프로퍼티 상세

AllDataColsByObjAttrs 공개적으로 프로퍼티

IDCols + PropertyCols together. Key: Class Property/Attribute Name Value: DB Column name
public IDictionary AllDataColsByObjAttrs
리턴 string>.IDictionary

AllDataColsByObjMemberInfo 공개적으로 프로퍼티

IDCols + PropertyCols together. Key: Class Property/Attribute MemberInfo Value: DB Column name
public IDictionary AllDataColsByObjMemberInfo
리턴 string>.IDictionary

AllDataColsInOrder 공개적으로 프로퍼티

The DB column names in the order they appeared in the mapping file.
public IList AllDataColsInOrder
리턴 IList

AllObjAttrsByDataCol 공개적으로 프로퍼티

The class attribute names keyed by the column name (case insensitive since column names read from the data source may or may not be in the expected case). Key: DB Column name Value: Class Property/Attribute Name
public IDictionary AllObjAttrsByDataCol
리턴 string>.IDictionary

AllObjMemberInfosByDataCol 공개적으로 프로퍼티

The MemberInfos keyed by the column name (case insensitive since column names read from the data source may or may not be in the expected case). Key: DB Column name Value: Class Property/Attribute MemberInfo
public IDictionary AllObjMemberInfosByDataCol
리턴 MemberInfo>.IDictionary

AllObjMemberInfosByObjAttr 공개적으로 프로퍼티

The MemberInfos keyed by the column name. Key: Class Property/Attribute Name Value: Class Property/Attribute MemberInfo
public IDictionary AllObjMemberInfosByObjAttr
리턴 MemberInfo>.IDictionary

ClassType 공개적으로 프로퍼티

The class that is being mapped.
public Type,System ClassType
리턴 System.Type

Constructor 공개적으로 프로퍼티

The constructor that takes no parameters.
public ConstructorInfo,System.Reflection Constructor
리턴 System.Reflection.ConstructorInfo

DataColTypesByDataCol 공개적으로 프로퍼티

Column types, if specified in the mapping file. Key: Column name (case insensitive since column names read from the data source may or may not be in the expected case) Value: Type string from the mapping file, or null if none was specified.
public IDictionary DataColTypesByDataCol
리턴 Type>.IDictionary

DataColTypesByObjAttr 공개적으로 프로퍼티

Column types, if specified in the mapping file. Key: Class Property/Attribute Name Value: Type string from the mapping file, or null if none was specified.
public IDictionary DataColTypesByObjAttr
리턴 Type>.IDictionary

IdDataColsByObjAttrs 공개적으로 프로퍼티

The columns that comprise the ID. Key: Class Property/Attribute Value: DB Column
public IDictionary IdDataColsByObjAttrs
리턴 string>.IDictionary

IdDataColsByObjMemberInfo 공개적으로 프로퍼티

The columns that comprise the ID. Key: Class Property/Attribute MemberInfo Value: DB Column name
public IDictionary IdDataColsByObjMemberInfo
리턴 string>.IDictionary

IdGeneratorsByDataCol 공개적으로 프로퍼티

For each ID column, what type of generator do we use (case insensitive since column names read from the data source may or may not be in the expected case). Key: Column name Value: Generator type.
public IDictionary IdGeneratorsByDataCol
리턴 GeneratorType>.IDictionary

IdSequencesByDataCol 공개적으로 프로퍼티

For each ID column, what sequence (if any) do we use. Only populated for IDs with GeneratorType SEQUENCE. Key: Column name (case insensitive since column names read from the data source may or may not be in the expected case) Value: Sequence name.
public IDictionary IdSequencesByDataCol
리턴 string>.IDictionary

NonIdDataColsByObjAttrs 공개적으로 프로퍼티

All the columns that aren't part of the ID. Key: Class Property/Attribute Value: DB Column name
public IDictionary NonIdDataColsByObjAttrs
리턴 string>.IDictionary

NonIdDataColsByObjMemberInfo 공개적으로 프로퍼티

All the columns that aren't part of the ID. Key: Class Property/Attribute MemberInfo Value: DB Column name
public IDictionary NonIdDataColsByObjMemberInfo
리턴 string>.IDictionary

Table 공개적으로 프로퍼티

The table it is being mapped to.
public string Table
리턴 string

TypeName 공개적으로 프로퍼티

The class name that is being mapped.
public string TypeName
리턴 string