Close - Maple Help

Online Help

All Products    Maple    MapleSim


Driver

  

Close

  

closes the Driver Module

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

driver:-Close()

Parameters

driver

-

Driver module

Description

• 

Close frees the resources associated with driver.  This also happens when the resources are freed via garbage collection; however, you can call Close to release the resources immediately.

• 

Any descendant modules of driver are closed when driver is closed.  (A module is a descendant of driver if it is returned by one of driver's exports or is a descendant of one of driver's descendants.)

Examples

Load the JDBC driver and open a connection to the database.

driverDatabaseLoadDriverdriver=com.database.Driver,classpath=/path/to/jar/jdbc.jar:

conndriver:-OpenConnectionjdbc:dbdriver://localhost/DBName,user1,passwd,isolation=serializable:

Close the driver.

driver:-Close

Try to use the connection.

conn:-ExecuteQuerySELECT * FROM datatable

 Error, (in ExecuteQuery) this object has been closed, no further operations are possible

Try to use the driver.

conndriver:-OpenConnectionjdbc:dbdriver://localhost/DBName,user1,passwd,isolation=serializable

 Error, (in ExecuteQuery) this object has been closed, no further operations are possible

See Also

Database

Database[Connection]

Database[Connection][SetOptions]

Database[Driver]

Database[JDBC]

Database[usage]