DatabaseRepository
class DatabaseRepository implements ConfigRepository
DB 에 자료를 입출력 하는 역할을 담당
Properties
protected string | $table | using DB table name | |
protected VirtualConnectionInterface | $conn | DB connection instance |
Methods
__construct(VirtualConnectionInterface $conn)
constructor
find(string $siteKey, string $name)
search getter
array
fetchAncestor(string $siteKey, string $name)
search ancestors getter
array
fetchDescendant(string $siteKey, string $name)
search descendants getter
void
void
remove(string $siteKey, string $name)
remove
void
void
createModel(array $attributes)
make new object
Details
at line 52
__construct(VirtualConnectionInterface $conn)
constructor
at line 65
ConfigEntity
find(string $siteKey, string $name)
search getter
at line 84
array
fetchAncestor(string $siteKey, string $name)
search ancestors getter
at line 107
array
fetchDescendant(string $siteKey, string $name)
search descendants getter
at line 129
ConfigEntity
save(ConfigEntity $config)
save
at line 147
void
clearLike(ConfigEntity $config, array $excepts = array())
clear all just descendants vars
at line 171
void
remove(string $siteKey, string $name)
remove
at line 188
protected ConfigEntity
insert(ConfigEntity $config)
insert
at line 202
protected ConfigEntity
update(ConfigEntity $config)
update
at line 224
void
foster(ConfigEntity $config, string|null $to = null)
Parent Changing with descendant
at line 252
void
affiliate(ConfigEntity $config, string|null $to = null)
affiliated to another config
at line 272
protected ConfigEntity
createModel(array $attributes)
make new object