\RedBeanPHP\UtilFeature

Feature Utility

The Feature Utility class provides an easy way to turn on or off features. This allows us to introduce new features without accidentally breaking backward compatibility.

Summary

Methods
Properties
Constants
feature()
No public properties found
C_FEATURE_NOVICE_LATEST
C_FEATURE_LATEST
C_FEATURE_NOVICE_5_5
C_FEATURE_5_5
C_FEATURE_NOVICE_5_4
C_FEATURE_5_4
C_FEATURE_NOVICE_5_3
C_FEATURE_5_3
C_FEATURE_ORIGINAL
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Constants

C_FEATURE_NOVICE_LATEST

C_FEATURE_NOVICE_LATEST

C_FEATURE_LATEST

C_FEATURE_LATEST

C_FEATURE_NOVICE_5_5

C_FEATURE_NOVICE_5_5

C_FEATURE_5_5

C_FEATURE_5_5

C_FEATURE_NOVICE_5_4

C_FEATURE_NOVICE_5_4

C_FEATURE_5_4

C_FEATURE_5_4

C_FEATURE_NOVICE_5_3

C_FEATURE_NOVICE_5_3

C_FEATURE_5_3

C_FEATURE_5_3

C_FEATURE_ORIGINAL

C_FEATURE_ORIGINAL

Methods

feature()

feature(string  $label) : void

Selects the feature set you want as specified by the label.

Available labels:

novice/latest:

  • forbid R::nuke()
  • enable automatic relation resolver based on foreign keys
  • forbid R::store(All)( $bean, TRUE ) (Hybrid mode)
  • use IS-NULL conditions in findLike() etc

latest:

  • allow R::nuke()
  • enable auto resolve
  • allow hybrid mode
  • use IS-NULL conditions in findLike() etc

novice/X or X:

  • keep everything as it was in version X

Usage:

R::useFeatureSet( 'novice/latest' );

Parameters

string $label

label