Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2988959
PhabricatorAuthChallengeQuery.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
PhabricatorAuthChallengeQuery.php
View Options
<?php
final
class
PhabricatorAuthChallengeQuery
extends
PhabricatorCursorPagedPolicyAwareQuery
{
private
$ids
;
private
$phids
;
private
$userPHIDs
;
private
$factorPHIDs
;
private
$challengeTTLMin
;
private
$challengeTTLMax
;
public
function
withIDs
(
array
$ids
)
{
$this
->
ids
=
$ids
;
return
$this
;
}
public
function
withPHIDs
(
array
$phids
)
{
$this
->
phids
=
$phids
;
return
$this
;
}
public
function
withUserPHIDs
(
array
$user_phids
)
{
$this
->
userPHIDs
=
$user_phids
;
return
$this
;
}
public
function
withFactorPHIDs
(
array
$factor_phids
)
{
$this
->
factorPHIDs
=
$factor_phids
;
return
$this
;
}
public
function
withChallengeTTLBetween
(
$challenge_min
,
$challenge_max
)
{
$this
->
challengeTTLMin
=
$challenge_min
;
$this
->
challengeTTLMax
=
$challenge_max
;
return
$this
;
}
public
function
newResultObject
(
)
{
return
new
PhabricatorAuthChallenge
(
)
;
}
protected
function
buildWhereClauseParts
(
AphrontDatabaseConnection
$conn
)
{
$where
=
parent
::
buildWhereClauseParts
(
$conn
)
;
if
(
$this
->
ids
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'id IN (%Ld)'
,
$this
->
ids
)
;
}
if
(
$this
->
phids
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'phid IN (%Ls)'
,
$this
->
phids
)
;
}
if
(
$this
->
userPHIDs
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'userPHID IN (%Ls)'
,
$this
->
userPHIDs
)
;
}
if
(
$this
->
factorPHIDs
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'factorPHID IN (%Ls)'
,
$this
->
factorPHIDs
)
;
}
if
(
$this
->
challengeTTLMin
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'challengeTTL >= %d'
,
$this
->
challengeTTLMin
)
;
}
if
(
$this
->
challengeTTLMax
!==
null
)
{
$where
[
]
=
qsprintf
(
$conn
,
'challengeTTL <= %d'
,
$this
->
challengeTTLMax
)
;
}
return
$where
;
}
public
function
getQueryApplicationClass
(
)
{
return
PhabricatorAuthApplication
::
class
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, Feb 22, 16:51 (10 h, 50 m ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1163206
Default Alt Text
PhabricatorAuthChallengeQuery.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment