Documentation

Auditor
in package

Auditor class

Tags
category

Pop

author

Nick Sagona, III dev@nolainteractive.com

copyright

Copyright (c) 2009-2023 NOLA Interactive, LLC. (http://www.nolainteractive.com)

license

http://www.popphp.org/license New BSD License

version
1.3.0

Table of Contents

$adapter  : AdapterInterface
Auditor adapter
__construct()  : mixed
Constructor
adapter()  : mixed
Get the adapter
addMetadata()  : Auditor
Add to the metadata
hasDiff()  : bool
Check if the model states are different
resolveDiff()  : self
Resolve the differences in values between the model states
send()  : mixed
Send the results of the audit
setDiff()  : self
Set the differences in values between the model states (that have already been processed)
setDomain()  : Auditor
Set domain, route and method
setMetadata()  : Auditor
Set the metadata
setModel()  : Auditor
Set user
setUser()  : Auditor
Set user

Properties

Methods

adapter()

Get the adapter

public adapter() : mixed
Return values
mixed

addMetadata()

Add to the metadata

public addMetadata(string $name, mixed $value) : Auditor
Parameters
$name : string
$value : mixed
Return values
Auditor

hasDiff()

Check if the model states are different

public hasDiff() : bool
Return values
bool

resolveDiff()

Resolve the differences in values between the model states

public resolveDiff([array<string|int, mixed> $old = [] ][, array<string|int, mixed> $new = [] ]) : self
Parameters
$old : array<string|int, mixed> = []
$new : array<string|int, mixed> = []
Return values
self

send()

Send the results of the audit

public send([array<string|int, mixed> $old = null ][, array<string|int, mixed> $new = null ]) : mixed
Parameters
$old : array<string|int, mixed> = null
$new : array<string|int, mixed> = null
Return values
mixed

setDiff()

Set the differences in values between the model states (that have already been processed)

public setDiff([array<string|int, mixed> $old = [] ][, array<string|int, mixed> $new = [] ]) : self
Parameters
$old : array<string|int, mixed> = []
$new : array<string|int, mixed> = []
Return values
self

setDomain()

Set domain, route and method

public setDomain([string $domain = null ][, string $route = null ][, string $method = null ]) : Auditor
Parameters
$domain : string = null
$route : string = null
$method : string = null
Return values
Auditor

setMetadata()

Set the metadata

public setMetadata(array<string|int, mixed> $metadata) : Auditor
Parameters
$metadata : array<string|int, mixed>
Return values
Auditor

setModel()

Set user

public setModel([string $model = null ][, int $modelId = null ]) : Auditor
Parameters
$model : string = null
$modelId : int = null
Return values
Auditor

setUser()

Set user

public setUser([string $username = null ][, int $userId = null ]) : Auditor
Parameters
$username : string = null
$userId : int = null
Return values
Auditor

Search results