PHP マニュアル
前のページ |  | 次のページ

# SDO_DAS_DataFactory::addPropertyToType

(no version information, might be only in CVS)

SDO_DAS_DataFactory::addPropertyToType -- Adds a property to a type

## 説明

void SDO_DAS_DataFactory::addPropertyToType ( string parentNamespaceURI, string parentTypeName, string propertyName, string propertyNamespaceURI, string propertyTypeName [, array options] )

警告
この関数は、 実験的 なものです。この関数の動作・ 名前・その他ドキュメントに書かれている事項は、予告なく、将来的な PHP のリリースにおいて変更される可能性があります。 この関数は自己責任で使用してください。

Adds a property to a type. The type must already be known to the SDO_DAS_DataFactory (i.e. have been added using addType()). The property becomes a property of the type. This is how the graph model for the structure of an SDO_DataObject is built.

## パラメータ

parentNamespaceURI

  The namespace URI for the parent type.

parentTypeName

  The type name for the parent type.

propertyName

  The name by which the property will be known in the parent type.

propertyNamespaceURI

  The namespace URI for the type of the property.

propertyTypeName

  The type name for the type of the property

options

  This array holds one or more key=>value pairs to set attribute values for the property. The optional keywords are:

  many

    A flag to say whether the property is many-valued. A value of 'true' adds the property as a many-valued property (default is 'false').

  readOnly

    A flag to say whether the property is read-only. A value of 'true' means the property value cannot be modified through the SDO application APIs (default is 'false').

  containment

    A flag to say whether the property is contained by the parent. A value of 'true' means the property is contained by the parent. A value of 'false' results in a non-containment reference (default is 'true'). This flag is only interpreted when adding properties which are data object types, otherwise it is ignored.

  default

    A default value for the property. Omitting this key means that the property does not have a default value. A property can only have a default value if it is a single-valued data type (primitive).

## 返り値

None.

## 変更履歴

バージョン | 説明
--- | ---
0.5.2 | Optional parameters many, readOnly, and containment deprecated in favour of the options array.

## 例

例 1. A SDO_DAS_DataFactory::addPropertyToType() example

The following adds an 'addressline' property to a Person type. The person type is identified by its namespace, 'PersonNS', and type name, 'PersonType'. The type of the 'addressline' property is a many-valued SDO data type (primitive) with namespace 'commonj.sdo' and type name 'String'.

`<?php $df->addPropertyToType('PersonNS', 'PersonType', 'addressline', 'commonj.sdo', 'String', array('many'=>true)); ?>`

前のページ | ホーム | 次のページ
SDO_DAS_ChangeSummary::isLogging | 上に戻る | SDO_DAS_DataFactory::addType