ILIAS  release_8 Revision v8.19-1-g4e8f2f9140c
All Data Structures Namespaces Files Functions Variables Modules Pages
ilBiblFieldFilterFactory Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for ilBiblFieldFilterFactory:
+ Collaboration diagram for ilBiblFieldFilterFactory:

Public Member Functions

 findById (int $id)
 
 findByFieldId (int $id)
 
 getAllForObjectId (int $obj_id)
 
 filterItemsForTable (int $obj_id, ilBiblTableQueryInfoInterface $info)
 
 getByObjectIdAndField (ilBiblFieldInterface $field, int $object_id)
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class ilBiblFieldFilterFactory

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 24 of file class.ilBiblFieldFilterFactory.php.

Member Function Documentation

◆ filterItemsForTable()

ilBiblFieldFilterFactory::filterItemsForTable ( int  $obj_id,
ilBiblTableQueryInfoInterface  $info 
)

Implements ilBiblFieldFilterFactoryInterface.

Definition at line 58 of file class.ilBiblFieldFilterFactory.php.

References ilBiblTableQueryInfoInterface\getLimit(), ilBiblTableQueryInfoInterface\getOffset(), ilBiblTableQueryInfoInterface\getSortingColumn(), ilBiblTableQueryInfoInterface\getSortingDirection(), and ActiveRecord\where().

58  : array
59  {
60  $list = ilBiblFieldFilter::where(['object_id' => $obj_id])
61  ->limit($info->getOffset(), $info->getLimit())
62  ->orderBy($info->getSortingColumn(), $info->getSortingDirection());
63 
64  return $list->getArray();
65  }
static where($where, $operator=null)
+ Here is the call graph for this function:

◆ findByFieldId()

ilBiblFieldFilterFactory::findByFieldId ( int  $id)

PhpIncompatibleReturnTypeInspection

Definition at line 39 of file class.ilBiblFieldFilterFactory.php.

References ActiveRecord\where().

40  {
42  return ilBiblFieldFilter::where(['field_id' => $id])->first();
43  }
static where($where, $operator=null)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
+ Here is the call graph for this function:

◆ findById()

ilBiblFieldFilterFactory::findById ( int  $id)

PhpIncompatibleReturnTypeInspection

Implements ilBiblFieldFilterFactoryInterface.

Definition at line 29 of file class.ilBiblFieldFilterFactory.php.

References ActiveRecord\findOrFail().

30  {
33  }
static findOrFail($primary_key, array $add_constructor_args=array())
Tries to find the object and throws an Exception if object is not found, instead of returning null...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
+ Here is the call graph for this function:

◆ getAllForObjectId()

ilBiblFieldFilterFactory::getAllForObjectId ( int  $obj_id)

Implements ilBiblFieldFilterFactoryInterface.

Definition at line 49 of file class.ilBiblFieldFilterFactory.php.

References ActiveRecord\where().

49  : array
50  {
51  return ilBiblFieldFilter::where(['object_id' => $obj_id])->get();
52  }
static where($where, $operator=null)
+ Here is the call graph for this function:

◆ getByObjectIdAndField()

ilBiblFieldFilterFactory::getByObjectIdAndField ( ilBiblFieldInterface  $field,
int  $object_id 
)

PhpIncompatibleReturnTypeInspection

Implements ilBiblFieldFilterFactoryInterface.

Definition at line 71 of file class.ilBiblFieldFilterFactory.php.

References ilBiblFieldInterface\getId(), and ActiveRecord\where().

72  {
73  $list = ilBiblFieldFilter::where([
74  'object_id' => $object_id,
75  'field_id' => $field->getId(),
76  ])->first();
77  if ($list === null) {
78  throw new LogicException("filter not found");
79  }
80 
82  return $list;
83  }
static where($where, $operator=null)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
+ Here is the call graph for this function:

The documentation for this class was generated from the following file: