PluginProbe ʕ •ᴥ•ʔ
TaxCloud for WooCommerce / 8.4.11
TaxCloud for WooCommerce v8.4.11
8.4.11 8.4.10 8.4.9 trunk 6.0.11 6.0.12 6.0.13 6.0.14 6.1.0 6.1.1 6.1.2 6.2.0 6.2.1 6.2.2 6.2.3 6.2.4 6.2.5 6.2.6 6.3.0 6.3.1 6.3.10 6.3.11 6.3.12 6.3.13 6.3.2 6.3.3 6.3.4 6.3.5 6.3.6 6.3.7 6.3.8 6.3.9 7.0.0 7.0.1 7.0.10 7.0.11 7.0.12 7.0.13 7.0.2 7.0.3 7.0.4 7.0.5 7.0.6 7.0.7 7.0.8 7.0.9 8.0.0 8.0.1 8.0.10 8.0.11 8.0.12 8.0.13 8.0.14 8.0.15 8.0.16 8.0.17 8.0.2 8.0.3 8.0.4 8.0.5 8.0.6 8.0.7 8.0.8 8.0.9 8.1.0 8.1.1 8.2.0 8.2.1 8.2.2 8.2.3 8.2.4 8.3.0 8.3.1 8.3.2 8.3.3 8.3.4 8.3.5 8.3.6 8.3.7 8.3.8 8.4.0 8.4.1 8.4.2 8.4.3 8.4.4 8.4.5 8.4.6 8.4.7 8.4.8
simple-sales-tax / includes / class-sst-origin-address.php
simple-sales-tax / includes Last commit date
abstracts 3 months ago admin 3 months ago frontend 1 month ago integrations 1 month ago v3 3 months ago vendor 6 days ago views 8 months ago class-simplesalestax.php 6 days ago class-sst-addresses.php 1 month ago class-sst-ajax.php 3 months ago class-sst-assets.php 6 months ago class-sst-blocks-integration.php 1 month ago class-sst-blocks.php 1 year ago class-sst-certificates.php 6 days ago class-sst-install.php 6 months ago class-sst-logger.php 5 months ago class-sst-marketplaces.php 6 months ago class-sst-order-controller.php 3 months ago class-sst-order.php 1 month ago class-sst-origin-address.php 8 months ago class-sst-product.php 3 months ago class-sst-rate-limit.php 5 months ago class-sst-settings.php 3 months ago class-sst-shipping.php 3 years ago class-sst-taxcloud-v3-api.php 3 months ago class-sst-taxcloud-v3.php 3 months ago class-sst-tic.php 2 years ago class-sst-updater.php 3 years ago sst-compatibility-functions.php 4 months ago sst-functions.php 6 days ago sst-message-functions.php 3 years ago sst-update-functions.php 11 months ago
class-sst-origin-address.php
116 lines
1 <?php
2
3 if ( ! defined( 'ABSPATH' ) ) {
4 exit; // Exit if accessed directly.
5 }
6
7 use TaxCloud\Address;
8
9 /**
10 * Origin Address.
11 *
12 * Represents an origin address.
13 *
14 * @author Simple Sales Tax
15 * @package SST
16 * @since 5.0
17 */
18 class SST_Origin_Address extends Address {
19
20 /**
21 * Address ID.
22 *
23 * @var string
24 */
25 protected $ID;
26
27 /**
28 * Is this a default address?
29 *
30 * @var bool
31 */
32 protected $Default;
33
34 /**
35 * Constructor.
36 *
37 * @param string $ID Address ID.
38 * @param bool $Default Whether this is a default address.
39 * @param string $Address1 Street address 1.
40 * @param string $Address2 Street address 2.
41 * @param string $City City.
42 * @param string $State State.
43 * @param string $Zip5 5 digit component of ZIP code.
44 * @param string $Zip4 Optional 4 digit component of ZIP code.
45 *
46 * @since 5.0
47 */
48 public function __construct( $ID, $Default, $Address1, $Address2, $City, $State, $Zip5, $Zip4 = null ) {
49 $this->setID( $ID );
50 $this->setDefault( $Default );
51
52 parent::__construct( $Address1, $Address2, $City, $State, $Zip5, $Zip4 );
53 }
54
55 /**
56 * Set ID.
57 *
58 * @param string $ID Address ID.
59 *
60 * @since 5.0
61 */
62 public function setID( $ID ) {
63 $this->ID = $ID;
64 }
65
66 /**
67 * Get ID.
68 *
69 * @return string
70 * @since 5.0
71 */
72 public function getID() {
73 return $this->ID;
74 }
75
76 /**
77 * Set Default.
78 *
79 * @param bool $Default Whether the address is a default origin address.
80 *
81 * @since 5.0
82 */
83 public function setDefault( $Default ) {
84 $this->Default = $Default;
85 }
86
87 /**
88 * Get Default.
89 *
90 * @return bool
91 * @since 5.0
92 */
93 public function getDefault() {
94 return $this->Default;
95 }
96
97 /**
98 * Set Zip5.
99 *
100 * @param string $Zip5 5 digit ZIP code.
101 */
102 public function setZip5( $Zip5 ) {
103 $this->Zip5 = substr( $Zip5, 0, 5 );
104 }
105
106 /**
107 * Set Zip4.
108 *
109 * @param string $Zip4 4 digit component of ZIP code.
110 */
111 public function setZip4( $Zip4 ) {
112 $this->Zip4 = substr( (string) $Zip4, 0, 4 );
113 }
114
115 }
116