Nhib.pdf code parsing-sqltypes

Source: Internet
Author: User
NHibernate-1.2.0.Beta3-debug

The classes under this directory encapsulate the database data types.

1. sqltype

All Database Data Types in nhib.pdf are encapsulated by sqltype or its subclass. Sqltype is actually a simple packaging of dbtype and Expansion
Show three attributes: length, scale, and precision. Function: dbtype is an enumeration, which is convenient after being encapsulated into a class.ProgramUse, and only one dbtype has no information
Fully, extends three attributes through the sqltype class.
2. binarysqltype, stringsqltype...
These classes inherited from sqltype have little effect, just to further define these types with length attributes.
3. sqltypefactory

Sqltype has little effect in nhib.pdf.
Sqltype is used when an idbparameter object is created and set in the driver class. Most drivers only use sqltype to obtain the dbtype attribute. Only sqlclientdriver uses the length, scale, and precision attributes.
Dialect is mainly used to generate dB Schema Based on entity attributes and configurations. sqltype is used in some methods of these classes.

in the XML Object configuration file, the column node has an SQL-type attribute, which is irrelevant to the sqltype class.
sqltype is only a representation class of the database data type. It is based on dbtype. It does not need to process data type conversion between different databases. This task is handled by the
ADO. Net
provider of various databases. For example, for the corresponding dbtype enumeration, MySQL has a mysqldbtype, And the mysqlparameter class has two attributes: dbtype and
mysqldbtype. If any of these attributes is set, the conversion is automatically completed and another attribute is set. This process can be viewed from mysql. Net
provider Source Code or reflector.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.