WC_Shipping_Rate::__get( string $key )

Magic methods to support direct access to props.


Description Description


Parameters Parameters

$key

(Required) Key.


Top ↑

Return Return

(mixed)


Top ↑

Source Source

File: includes/class-wc-shipping-rate.php

	public function __get( $key ) {
		if ( is_callable( array( $this, "get_{$key}" ) ) ) {
			return $this->{"get_{$key}"}();
		} elseif ( isset( $this->data[ $key ] ) ) {
			return $this->data[ $key ];
		} else {
			return '';
		}
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.2.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.