1: <?php
2:
3: namespace ShippoClient\Entity;
4:
5: use TurmericSpice\Container;
6: use TurmericSpice\ReadableAttributes;
7:
8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19:
20: class Rate extends ObjectInformation
21: {
22: use ReadableAttributes {
23: mayHaveAsString as public getShipment;
24: mayHaveAsArray as public getAttributes;
25: mayHaveAsFloat as public getAmountLocal;
26: mayHaveAsString as public getCurrencyLocal;
27: mayHaveAsFloat as public getAmount;
28: mayHaveAsString as public getCurrency;
29: mayHaveAsString as public getProvider;
30: mayHaveAsString as public getServicelevelName;
31: mayHaveAsString as public getServicelevelTerms;
32: mayHaveAsInt as public getDays;
33: mayHaveAsBoolean as public getTrackable;
34: mayHaveAsBoolean as public getInsurance;
35: mayHaveAsFloat as public getInsuranceAmountLocal;
36: mayHaveAsString as public getInsuranceCurrencyLocal;
37: mayHaveAsFloat as public getInsuranceAmount;
38: mayHaveAsString as public getInsuranceCurrency;
39: mayHaveAsString as public getCarrierAccount;
40: mayHaveAsString as public getDurationTerms;
41: mayHaveAsArray as public getMessages;
42: mayHaveAsString as public getProviderImage_75;
43: mayHaveAsString as public getProviderImage_200;
44: }
45:
46: 47: 48: 49: 50:
51: public function getAvailableShippo()
52: {
53: return $this->attributes->mayHave('available_shippo')->value();
54: }
55:
56: 57: 58: 59: 60:
61: public function getOutboundEndpoint()
62: {
63: return $this->attributes->mayHave('outbound_endpoint')->value();
64: }
65:
66: 67: 68: 69: 70:
71: public function getInboundEndpoint()
72: {
73: return $this->attributes->mayHave('inbound_endpoint')->value();
74: }
75:
76: 77: 78: 79: 80:
81: public function getArrivesBy()
82: {
83: return $this->attributes->mayHave('arrives_by')->value();
84: }
85:
86: 87: 88: 89: 90:
91: public function getDeliveryAttempts()
92: {
93: return $this->attributes->mayHave('delivery_attempts')->value();
94: }
95: }
96: