IOracleCustomType
is an interface for converting between a Custom Type and an Oracle Object or Collection Type.
// C# public interface IOracleCustomType
Provider | ODP.NET, Unmanaged Driver |
Assembly | Oracle.DataAccess.dll |
Namespace | Oracle.DataAccess.Types |
.NET Framework | 3.5, 4.0, 4.5 |
All public static methods are thread-safe, although instance methods do not guarantee thread safety.
See Also:
IOracleCustomType
members are listed in the following tables.
IOracleCustomType Interface Methods
IOracleCustomType
interface methods are listed in Table 16-22.
IOracleCustomType
Interface methods are listed in Table 16-23.
Table 16-23 IOracleCustomType Interface Methods
Interface Method | Description |
---|---|
Returns the values that set the Oracle Object attributes |
|
Provides the Oracle Object with the attribute values to set on the custom type |
See Also:
This interface method creates an Oracle Object or Collection by setting the attribute or element values respectively on the specified Oracle UDT.
// C# void FromCustomObject(OracleConnection con, IntPtr pUdt);
con
An OracleConnection
instance.
pUdt
An opaque pointer to the Oracle Object or Collection to be created.
The FromCustomObject
method is used to build an Oracle Object or Collection from a custom object by setting attribute or element values respectively through the OracleUdt.SetValue
method.
The OracleUdt.SetValue
method is invoked as follows:
Oracle Object Type
For a custom type that represents an Oracle Object Type, the OracleUdt.SetValue
method must be invoked for each non-NULL
attribute value that needs to be set.
Oracle Collection Type
For a custom type that represents an Oracle Collection Type, a single call to OracleUdt.SetValue
method specifies the collection element values.
This interface initializes a custom object using the specified Oracle UDT.
// C# void ToCustomObject (OracleConnection con, IntPtr pUdt);
con
An OracleConnection
instance.
pUdt
An opaque pointer to the Oracle UDT.
The ToCustomObject
method is used to initialize a custom object from the specified Oracle Object or Collection by retrieving attribute or element values respectively through the OracleUdt.GetValue
method.
The OracleUdt.GetValue
method is invoked as follows:
Oracle Object Type
For a custom type that represents an Oracle Object Type, the OracleUdt.GetValue
method must be invoked for each attribute value to be retrieved.
For a custom type that represents an Oracle Collection Type, a single call to OracleUdt.GetValue
method retrieves the collection element values.