BlogPostSort
extends SortableEnum
in package
This is the sort blog post value enumerate.
Tags
Table of Contents
DISLIKES | = 'DISLIKES' | |
---|---|---|
HITS | = 'HITS' | |
ID | = 'ID' | |
LIKES | = 'LIKES' | |
PUBLICATIONDATE | = 'PUBLICATIONDATE' | |
RATE | = 'RATE' | |
SORT_DIRECTION_ASC | = 'ASC' | |
SORT_DIRECTION_DESC | = 'DESC' | |
VOTES | = 'VOTES' | |
areValid() | Check if the given values is a valid sortable value for the called enumerate. | : bool |
getValues() | : array<string|int, mixed> | |
isValid() | Check if the given value is inside the called enumerate. | : bool |
Constants
DISLIKES
public
mixed
DISLIKES
= 'DISLIKES'
HITS
public
mixed
HITS
= 'HITS'
ID
public
mixed
ID
= 'ID'
LIKES
public
mixed
LIKES
= 'LIKES'
PUBLICATIONDATE
public
mixed
PUBLICATIONDATE
= 'PUBLICATIONDATE'
RATE
public
mixed
RATE
= 'RATE'
SORT_DIRECTION_ASC
public
mixed
SORT_DIRECTION_ASC
= 'ASC'
SORT_DIRECTION_DESC
public
mixed
SORT_DIRECTION_DESC
= 'DESC'
VOTES
public
mixed
VOTES
= 'VOTES'
Methods
areValid()
Check if the given values is a valid sortable value for the called enumerate.
public
static areValid(array<string|int, mixed> $values) : bool
Parameters
- $values : array<string|int, mixed>
-
Array that contains all the values to check
Return values
bool —getValues()
public
static getValues() : array<string|int, mixed>
Return values
array<string|int, mixed> —isValid()
Check if the given value is inside the called enumerate.
public
static isValid(string $value) : bool
Parameters
- $value : string
-
value to check