WC_Order_Item_Fee::offsetGet()publicWC 1.0ReturnTypeWillChange

OffsetGet for ArrayAccess/Backwards compatibility.

Method of the class: WC_Order_Item_Fee{}

No Hooks.

Return

Mixed.

Usage

$WC_Order_Item_Fee = new WC_Order_Item_Fee();
$WC_Order_Item_Fee->offsetGet( $offset );
$offset(string) (required)
Offset.

WC_Order_Item_Fee::offsetGet() code WC 7.7.0

public function offsetGet( $offset ) {
	if ( 'line_total' === $offset ) {
		$offset = 'total';
	} elseif ( 'line_tax' === $offset ) {
		$offset = 'total_tax';
	} elseif ( 'line_tax_data' === $offset ) {
		$offset = 'taxes';
	}
	return parent::offsetGet( $offset );
}