Class: OCI8::Metadata::List
Overview
internal use only.
Instance Method Summary collapse
-
#ltype ⇒ Object
Table 6-15 List Attributes.
-
#to_a ⇒ Object
convert to array.
Methods inherited from Base
#obj_id, #obj_link, #obj_name, #obj_schema
Instance Method Details
#ltype ⇒ Object
Table 6-15 List Attributes
1664 1665 1666 |
# File 'lib/oci8/metadata.rb', line 1664 def ltype attr_get_ub2(OCI_ATTR_LTYPE) end |
#to_a ⇒ Object
convert to array
1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 |
# File 'lib/oci8/metadata.rb', line 1669 def to_a # Table 6-15 List Attributes case ltype when OCI_LTYPE_COLUMN; offset = 1 when OCI_LTYPE_ARG_PROC; offset = 1 when OCI_LTYPE_ARG_FUNC; offset = 0 when OCI_LTYPE_SUBPRG; offset = 0 when OCI_LTYPE_TYPE_ATTR; offset = 1 when OCI_LTYPE_TYPE_METHOD; offset = 1 when OCI_LTYPE_TYPE_ARG_PROC; offset = 0 when OCI_LTYPE_TYPE_ARG_FUNC; offset = 1 when OCI_LTYPE_SCH_OBJ; offset = 0 when OCI_LTYPE_DB_SCH; offset = 0 #when OCI_LTYPE_TYPE_SUBTYPE; offset = ? #when OCI_LTYPE_TABLE_ALIAS; offset = ? #when OCI_LTYPE_VARIABLE_TYPE; offset = ? #when OCI_LTYPE_NAME_VALUE; offset = ? when 15; offset = 0 # OCI_LTYPE_PACKAGE_TYPE else raise NotImplementedError, "unsupported list type #{ltype}" end ary = [] 0.upto(num_params - 1) do |i| ary << __param_at(i + offset) end ary end |