Overview

Namespaces

  • Alchemy
    • core
      • query
      • schema
    • dialect
    • engine
    • orm
    • tests
    • util
      • promise
  • PHP

Classes

  • DataMapper
  • DDL
  • ManyToOne
  • OneToMany
  • OneToOne
  • ORMQuery
  • ORMTable
  • ORMTableRef
  • RelatedSet
  • Relationship
  • Session
  • SessionSelect
  • WorkQueue
  • Overview
  • Namespace
  • Class
  • Tree

Class OneToOne

Base class for defining the relationships between models Subclass this to create separate relationship types like OneToOne, OneToMany, etc.

Alchemy\core\Element implements Alchemy\core\IElement
Extended by Alchemy\orm\Relationship
Extended by Alchemy\orm\OneToOne
Namespace: Alchemy\orm
Located at alchemy/orm/schema/OneToOne.php
Methods summary
public boolean
# isParent( )

Return true if the origin of this relationship is the source of foreign key index. False if the source of the foreign key is the destination of this relationship

Return true if the origin of this relationship is the source of foreign key index. False if the source of the foreign key is the destination of this relationship

Returns

boolean

Overrides

Alchemy\orm\Relationship::isParent()
public array
# getRemoteColumnMap( mixed $origin )

Return a map of remote column names and their values according to this relationship, relative to $origin, for querying. Applies whether $origin is a table reference or a DataMapper. Must be implemented by all Relationship types.

Return a map of remote column names and their values according to this relationship, relative to $origin, for querying. Applies whether $origin is a table reference or a DataMapper. Must be implemented by all Relationship types.

Parameters

$origin
mixed
$origin

Returns

array
[Column => Value, ...]

Overrides

Alchemy\orm\Relationship::getRemoteColumnMap()
public
# set( mixed $origin, mixed $remote )
Methods inherited from Alchemy\orm\Relationship
__construct(), assertDestinationType(), createBackref(), findForeignKey(), findForeignKeyImpl(), getBackref(), getDestinationClass(), getForeignKey(), getInverse(), getName(), getOriginClass(), getRef(), isNullable(), isSingleObject()
Methods inherited from Alchemy\core\Element
__callStatic(), __clone(), addTag(), addTags(), copy(), define(), define_alias(), getDescription(), getID(), getTag(), getType(), get_definition(), listTags(), normalize_arg()
Properties inherited from Alchemy\orm\Relationship
$args, $destination, $foreignKey, $inverse, $name, $origin
Properties inherited from Alchemy\core\Element
$id, $tags, $type
API documentation generated by ApiGen 2.8.0