Class WC_Shipping_Zone
Represents a single shipping zone
- WC_Data
-
WC_Legacy_Shipping_Zone
-
WC_Shipping_Zone
Category: Class
Author: WooCommerce
Version: 3.0.0
Since: 2.6.0
Class: WC_Shipping_Zone
Located at class-wc-shipping-zone.php
Methods summary
public
|
|
public
string
|
|
public
integer
|
|
public
array
|
|
public
string
|
#
get_formatted_location( integer $max = 10, string $context = 'view' )
Return a text string representing what this zone is for. |
public
array
|
|
public
|
|
public
|
|
public
|
|
public
integer
|
|
protected
string
|
|
public
boolean
|
|
public
|
|
public
|
#
clear_locations( array|string $types = array( 'postcode', 'state', 'country', 'continent' ) )
Clear all locations for this zone. |
public
|
|
public
integer
|
|
public
True
|
Methods inherited from WC_Legacy_Shipping_Zone
Methods inherited from WC_Data
__clone()
,
__sleep()
,
__toString()
,
__wakeup()
,
add_meta_data()
,
apply_changes()
,
delete()
,
delete_meta_data()
,
delete_meta_data_by_mid()
,
error()
,
filter_null_meta()
,
get_changes()
,
get_data()
,
get_data_keys()
,
get_data_store()
,
get_extra_data_keys()
,
get_hook_prefix()
,
get_id()
,
get_meta()
,
get_meta_data()
,
get_object_read()
,
get_prop()
,
is_internal_meta_key()
,
maybe_read_meta_data()
,
meta_exists()
,
read_meta_data()
,
save_meta_data()
,
set_date_prop()
,
set_defaults()
,
set_id()
,
set_meta_data()
,
set_object_read()
,
set_prop()
,
set_props()
,
update_meta_data()
Properties summary
protected
integer|null
|
$id
Zone ID |
#
null
|
protected
string
|
$object_type
This is the name of this object type. |
#
'shipping_zone'
|
protected
array
|
$data
Zone Data |
#
array(
'zone_name' => '',
'zone_order' => 0,
'zone_locations' => array(),
)
|
Properties inherited from WC_Data
$cache_group
,
$changes
,
$data_store
,
$default_data
,
$extra_data
,
$meta_data
,
$object_read