PATH:
home
/
ajwellnessmassag
/
angelictravels.online
/
wp-content
/
plugins
/
gravityforms
/
includes
<?php namespace Gravity_Forms\Gravity_Forms; /** * Class GF_Service_Container * * A simple Service Container used to collect and organize Services used by the application and its modules. * * @since 2.5 * * @package Gravity_Forms\Gravity_Forms */ class GF_Service_Container { private $services = array(); private $providers = array(); /** * Add a service to the container. * * @since 2.5 * * @param string $name The service Name * @param mixed $service The service to add */ public function add( $name, $service, $defer = false ) { if ( empty( $name ) ) { $name = get_class( $service ); } if ( ! $defer && is_callable( $service ) ) { $service = $service(); } $this->services[ $name ] = $service; } /** * Remove a service from the container. * * @since 2.5 * * @param string $name The service name. */ public function remove( $name ) { unset( $this->services[ $name ] ); } /** * Get a service from the container by name. * * @since 2.5 * * @param string $name The service name. * * @return mixed|null */ public function get( $name ) { if ( ! isset( $this->services[ $name ] ) ) { return null; } if ( is_callable( $this->services[ $name ] ) ) { $called = $this->services[ $name ](); $this->services[ $name ] = $called; } return $this->services[ $name ]; } /** * Add a service provider to the container and register each of its services. * * @since 2.5 * * @param GF_Service_Provider $provider */ public function add_provider( GF_Service_Provider $provider ) { $provider_name = get_class( $provider ); // Only add providers a single time. if ( isset( $this->providers[ $provider_name ] ) ) { return; } $this->providers[ $provider_name ] = $provider; $provider->set_container( $this ); $provider->register( $this ); $provider->init( $this ); } }
[+]
duplicate-submissions
[+]
theme-layers
[-] index.php
[edit]
[+]
addon
[+]
setup-wizard
[+]
post-custom-field-select
[+]
blocks
[+]
merge-tags
[-] class-gravity-api.php
[edit]
[+]
config
[+]
author-select
[-] class-gf-service-container.php
[edit]
[+]
logging
[-] class-gf-background-upgrader.php
[edit]
[+]
license
[+]
messages
[+]
wizard
[-] class-confirmation.php
[edit]
[+]
transients
[+]
form-switcher
[+]
external-api
[+]
assets
[+]
phpqrcode
[+]
webapi
[+]
save-form
[-] class-gf-upgrade.php
[edit]
[+]
async
[+]
legacy
[-] upload.php
[edit]
[+]
form-editor
[-] class-gf-service-provider.php
[edit]
[+]
orders
[+]
form-display
[+]
telemetry
[-] class-personal-data.php
[edit]
[+]
..
[+]
settings
[+]
environment-config
[-] class-gf-osdxp.php
[edit]
[-] api.php
[edit]
[+]
system-status
[+]
libraries
[+]
editor-button
[+]
honeypot
[+]
templates
[+]
util
[+]
embed-form
[+]
fields
[+]
splash-page
[+]
template-library
[-] class-translationspress-updater.php
[edit]
[+]
query
[-] trait-redirects-on-save.php
[edit]
[+]
ajax
[+]
updates
[-] class-gf-download.php
[edit]
[+]
locking