1C-Bitrix
25.700.0
Toggle main menu visibility
Титульная страница
Пространства имен
Пространства имен
Члены пространств имен
Указатель
$
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
Функции
_
a
c
d
e
f
g
h
i
k
l
m
o
p
r
s
t
u
v
w
Переменные
$
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
v
w
Перечисления
a
b
c
d
e
f
g
l
m
n
o
p
r
s
t
u
v
w
Элементы перечислений
a
b
c
d
e
f
g
i
l
m
n
o
p
r
s
t
u
v
w
Структуры данных
Структуры данных
Алфавитный указатель структур данных
Иерархия классов
Поля структур
Указатель
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Функции
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Переменные
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Перечисления
Элементы перечислений
Файлы
Файлы
Список членов всех файлов
Указатель
$
(
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
y
б
в
к
л
о
п
с
т
ю
Функции
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Переменные
$
(
_
a
b
c
d
e
f
g
h
i
j
l
m
n
o
p
q
r
s
t
u
v
w
y
б
в
к
л
о
п
с
т
ю
Блог
Хостинг
1C-Bitrix
Пространства имен
Структуры данных
Файлы
Файлы
bitrix
modules
abtest
advertising
b24connector
bitrixcloud
bizproc
bizprocdesigner
blog
calendar
catalog
clouds
cluster
conversion
currency
eshopapp
fileman
form
forum
highloadblock
iblock
idea
im
landing
ldap
learning
lists
location
mail
main
classes
cli
include
interface
lib
access
analytics
authentication
cli
Command
component
composite
config
context
controller
copy
data
db
di
diag
discount
engine
Entity
eventlog
File
FileUploader
filter
grid
html
io
License
localization
mail
Messenger
numerator
orm
annotations
data
fields
relations
cascadepolicy.php
manytomany.php
onetomany.php
reference.php
relation.php
validators
arrayfield.php
booleanfield.php
cryptofield.php
datefield.php
datetimefield.php
decimalfield.php
enumfield.php
expressionfield.php
field.php
fielderror.php
fieldtypemask.php
floatfield.php
integerfield.php
ireadable.php
istorable.php
itypehintable.php
objectfield.php
scalarfield.php
secretfield.php
stringfield.php
textfield.php
usertypefield.php
usertypeutsmultiplefield.php
objectify
query
entity.php
entityerror.php
event.php
eventmanager.php
eventresult.php
loader.php
page
phonenumber
Provider
rating
Repository
rest
routing
search
security
service
session
SidePanel
sms
test
text
type
ui
update
UpdateSystem
urlpreview
userconsent
userfield
Validation
web
AccessDeniedException.php
application.php
ArgumentException.php
ArgumentNullException.php
ArgumentOutOfRangeException.php
ArgumentTypeException.php
ClassLocator.php
context.php
DecodingException.php
environment.php
error.php
errorable.php
errorableimplementation.php
errorcollection.php
event.php
eventmanager.php
eventresult.php
file.php
finderdest.php
group.php
grouptask.php
httpapplication.php
httpcontext.php
httprequest.php
httpresponse.php
InvalidOperationException.php
license.php
loader.php
modulemanager.php
moduletable.php
NotImplementedException.php
NotSupportedException.php
ObjectException.php
ObjectNotFoundException.php
ObjectPropertyException.php
operation.php
request.php
response.php
result.php
senderconnector.php
server.php
site.php
sitedomain.php
sitetemplate.php
SystemException.php
task.php
taskoperation.php
urlrewriter.php
UrlRewriterRuleMaker.php
user.php
useraccess.php
userauthaction.php
usercounter.php
userfield.php
userfieldconfirm.php
userfieldlangtable.php
usergroup.php
userindex.php
userphoneauth.php
userprofilehistory.php
userprofilerecord.php
userutils.php
UuidGenerator.php
xmlwriter.php
meta
public
services
tools
.settings.php
admin_tools.php
ajax_tools.php
bx_root.php
checklist_structure.php
countries.php
default_option.php
filter_tools.php
img.php
include.php
jscore.php
option_triggers.php
options.php
prolog.php
spread.php
start.php
tools.php
messageservice
mobileapp
perfmon
photogallery
pull
report
rest
sale
scale
search
security
sender
seo
socialnetwork
socialservices
statistic
storeassist
subscribe
support
translate
ui
vote
webservice
wiki
workflow
Список членов всех файлов
Примеры
•
Указатель
Структуры данных
Пространства имен
Файлы
Функции
Переменные
Перечисления
Элементы перечислений
Страницы
Загрузка...
Поиск...
Не найдено
relation.php
См. документацию.
1
<?php
8
9
namespace
Bitrix\Main\ORM\Fields\Relations;
10
11
use Bitrix\Main\ArgumentException;
12
use Bitrix\Main\ORM\Fields\ITypeHintable;
13
use Bitrix\Main\SystemException;
14
use Bitrix\Main\ORM\Entity;
15
use Bitrix\Main\ORM\Fields\Field;
16
use Bitrix\Main\ORM\Objectify\EntityObject;
17
use Bitrix\Main\ORM\Query\Join;
18
25
abstract
class
Relation
extends
Field
implements
ITypeHintable
26
{
28
protected
$refEntityName
;
29
31
protected
$refEntity
;
32
34
protected
$joinType
=
null
;
35
37
protected
$cascadeSavePolicy
;
38
40
protected
$cascadeDeletePolicy
;
41
47
public
function
configureCascadeSavePolicy
(
$cascadeSavePolicy
)
48
{
49
$this->cascadeSavePolicy =
$cascadeSavePolicy
;
50
51
return
$this;
52
}
47
public
function
configureCascadeSavePolicy
(
$cascadeSavePolicy
) {
…
}
53
59
public
function
configureCascadeDeletePolicy
(
$cascadeDeletePolicy
)
60
{
61
$this->cascadeDeletePolicy =
$cascadeDeletePolicy
;
62
63
return
$this;
64
}
59
public
function
configureCascadeDeletePolicy
(
$cascadeDeletePolicy
) {
…
}
65
71
public
function
getRefEntity()
72
{
73
if
($this->refEntity ===
null
)
74
{
75
// refEntityName could be an object or a data class
76
if
(class_exists($this->refEntityName) && is_subclass_of($this->refEntityName, EntityObject::class))
77
{
79
$refObjectClass =
$this->refEntityName
;
80
$this->refEntityName = $refObjectClass::$dataClass;
81
}
82
83
$this->refEntity =
Entity::getInstance
($this->refEntityName);
84
}
85
86
return
$this->refEntity
;
87
}
88
92
public
function
getRefEntityName
()
93
{
94
return
$this->refEntityName
;
95
}
92
public
function
getRefEntityName
() {
…
}
96
103
public
function
configureJoinType
(
$type
)
104
{
105
$type
= strtoupper(
$type
);
106
107
if
(!in_array(
$type
, Join::getTypes(),
true
))
108
{
109
throw
new
ArgumentException
(sprintf(
110
'Unknown join type `%s` in reference `%s` of `%s` entity'
,
111
$type
, $this->name, $this->entity->getDataClass()
112
));
113
}
114
115
$this->joinType =
$type
;
116
117
return
$this;
118
}
103
public
function
configureJoinType
(
$type
) {
…
}
119
123
public
function
getJoinType
()
124
{
125
return
$this->joinType
;
126
}
123
public
function
getJoinType
() {
…
}
127
131
public
function
getCascadeSavePolicy
()
132
{
133
return
$this->cascadeSavePolicy
;
134
}
131
public
function
getCascadeSavePolicy
() {
…
}
135
139
public
function
getCascadeDeletePolicy
()
140
{
141
return
$this->cascadeDeletePolicy
;
142
}
139
public
function
getCascadeDeletePolicy
() {
…
}
143
149
public
function
getGetterTypeHint
()
150
{
151
return
$this->getRefEntity()->getObjectClass();
152
}
149
public
function
getGetterTypeHint
() {
…
}
153
159
public
function
getSetterTypeHint
()
160
{
161
return
$this->getRefEntity()->getObjectClass();
162
}
159
public
function
getSetterTypeHint
() {
…
}
163
}
25
abstract
class
Relation
extends
Field
implements
ITypeHintable
{
…
};
$type
$type
Определения
options.php:106
Bitrix\Main\ArgumentException
Определения
ArgumentException.php:9
Bitrix\Main\ORM\Entity\getInstance
static getInstance($entityName)
Определения
entity.php:104
Bitrix\Main\ORM\Fields\Field
Определения
field.php:25
Bitrix\Main\ORM\Fields\Relations\Relation
Определения
relation.php:26
Bitrix\Main\ORM\Fields\Relations\Relation\$cascadeDeletePolicy
$cascadeDeletePolicy
Определения
relation.php:40
Bitrix\Main\ORM\Fields\Relations\Relation\$joinType
$joinType
Определения
relation.php:34
Bitrix\Main\ORM\Fields\Relations\Relation\getSetterTypeHint
getSetterTypeHint()
Определения
relation.php:159
Bitrix\Main\ORM\Fields\Relations\Relation\$cascadeSavePolicy
$cascadeSavePolicy
Определения
relation.php:37
Bitrix\Main\ORM\Fields\Relations\Relation\getJoinType
getJoinType()
Определения
relation.php:123
Bitrix\Main\ORM\Fields\Relations\Relation\configureCascadeSavePolicy
configureCascadeSavePolicy($cascadeSavePolicy)
Определения
relation.php:47
Bitrix\Main\ORM\Fields\Relations\Relation\configureCascadeDeletePolicy
configureCascadeDeletePolicy($cascadeDeletePolicy)
Определения
relation.php:59
Bitrix\Main\ORM\Fields\Relations\Relation\getRefEntityName
getRefEntityName()
Определения
relation.php:92
Bitrix\Main\ORM\Fields\Relations\Relation\getGetterTypeHint
getGetterTypeHint()
Определения
relation.php:149
Bitrix\Main\ORM\Fields\Relations\Relation\getCascadeDeletePolicy
getCascadeDeletePolicy()
Определения
relation.php:139
Bitrix\Main\ORM\Fields\Relations\Relation\$refEntityName
$refEntityName
Определения
relation.php:28
Bitrix\Main\ORM\Fields\Relations\Relation\$refEntity
$refEntity
Определения
relation.php:31
Bitrix\Main\ORM\Fields\Relations\Relation\configureJoinType
configureJoinType($type)
Определения
relation.php:103
Bitrix\Main\ORM\Fields\Relations\Relation\getCascadeSavePolicy
getCascadeSavePolicy()
Определения
relation.php:131
Bitrix\Main\ORM\Fields\ITypeHintable
Определения
itypehintable.php:14
bitrix
modules
main
lib
orm
fields
relations
relation.php
Создано системой
1.14.0