gw.UplinkRxInfoLegacy */ class UplinkRxInfoLegacy extends \Google\Protobuf\Internal\Message { /** * Gateway ID. * * Generated from protobuf field bytes gateway_id = 1; */ protected $gateway_id = ''; /** * RX time (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Timestamp time = 2; */ protected $time = null; /** * RX time since GPS epoch (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 3; */ protected $time_since_gps_epoch = null; /** * RSSI. * * Generated from protobuf field int32 rssi = 5; */ protected $rssi = 0; /** * LoRa SNR. * * Generated from protobuf field double lora_snr = 6; */ protected $lora_snr = 0.0; /** * Channel. * * Generated from protobuf field uint32 channel = 7; */ protected $channel = 0; /** * RF Chain. * * Generated from protobuf field uint32 rf_chain = 8; */ protected $rf_chain = 0; /** * Board. * * Generated from protobuf field uint32 board = 9; */ protected $board = 0; /** * Antenna. * * Generated from protobuf field uint32 antenna = 10; */ protected $antenna = 0; /** * Location. * * Generated from protobuf field .common.Location location = 11; */ protected $location = null; /** * Fine-timestamp type. * * Generated from protobuf field .gw.FineTimestampType fine_timestamp_type = 12; */ protected $fine_timestamp_type = 0; /** * Gateway specific context. * * Generated from protobuf field bytes context = 15; */ protected $context = ''; /** * Uplink ID (UUID bytes). * Unique and random ID which can be used to correlate the uplink across * multiple logs. * * Generated from protobuf field bytes uplink_id = 16; */ protected $uplink_id = ''; /** * CRC status. * * Generated from protobuf field .gw.CRCStatus crc_status = 17; */ protected $crc_status = 0; /** * Optional meta-data map. * * Generated from protobuf field map metadata = 18; */ private $metadata; protected $fine_timestamp; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $gateway_id * Gateway ID. * @type \Google\Protobuf\Timestamp $time * RX time (only set when the gateway has a GPS module). * @type \Google\Protobuf\Duration $time_since_gps_epoch * RX time since GPS epoch (only set when the gateway has a GPS module). * @type int $rssi * RSSI. * @type float $lora_snr * LoRa SNR. * @type int $channel * Channel. * @type int $rf_chain * RF Chain. * @type int $board * Board. * @type int $antenna * Antenna. * @type \Chirpstack\Common\Location $location * Location. * @type int $fine_timestamp_type * Fine-timestamp type. * @type \Chirpstack\Gateway\EncryptedFineTimestamp $encrypted_fine_timestamp * Encrypted fine-timestamp data. * @type \Chirpstack\Gateway\PlainFineTimestamp $plain_fine_timestamp * Plain fine-timestamp data. * @type string $context * Gateway specific context. * @type string $uplink_id * Uplink ID (UUID bytes). * Unique and random ID which can be used to correlate the uplink across * multiple logs. * @type int $crc_status * CRC status. * @type array|\Google\Protobuf\Internal\MapField $metadata * Optional meta-data map. * } */ public function __construct($data = NULL) { \GPBMetadata\Chirpstack\Gateway\Gw::initOnce(); parent::__construct($data); } /** * Gateway ID. * * Generated from protobuf field bytes gateway_id = 1; * @return string */ public function getGatewayId() { return $this->gateway_id; } /** * Gateway ID. * * Generated from protobuf field bytes gateway_id = 1; * @param string $var * @return $this */ public function setGatewayId($var) { GPBUtil::checkString($var, False); $this->gateway_id = $var; return $this; } /** * RX time (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Timestamp time = 2; * @return \Google\Protobuf\Timestamp|null */ public function getTime() { return $this->time; } public function hasTime() { return isset($this->time); } public function clearTime() { unset($this->time); } /** * RX time (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Timestamp time = 2; * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setTime($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->time = $var; return $this; } /** * RX time since GPS epoch (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 3; * @return \Google\Protobuf\Duration|null */ public function getTimeSinceGpsEpoch() { return $this->time_since_gps_epoch; } public function hasTimeSinceGpsEpoch() { return isset($this->time_since_gps_epoch); } public function clearTimeSinceGpsEpoch() { unset($this->time_since_gps_epoch); } /** * RX time since GPS epoch (only set when the gateway has a GPS module). * * Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 3; * @param \Google\Protobuf\Duration $var * @return $this */ public function setTimeSinceGpsEpoch($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); $this->time_since_gps_epoch = $var; return $this; } /** * RSSI. * * Generated from protobuf field int32 rssi = 5; * @return int */ public function getRssi() { return $this->rssi; } /** * RSSI. * * Generated from protobuf field int32 rssi = 5; * @param int $var * @return $this */ public function setRssi($var) { GPBUtil::checkInt32($var); $this->rssi = $var; return $this; } /** * LoRa SNR. * * Generated from protobuf field double lora_snr = 6; * @return float */ public function getLoraSnr() { return $this->lora_snr; } /** * LoRa SNR. * * Generated from protobuf field double lora_snr = 6; * @param float $var * @return $this */ public function setLoraSnr($var) { GPBUtil::checkDouble($var); $this->lora_snr = $var; return $this; } /** * Channel. * * Generated from protobuf field uint32 channel = 7; * @return int */ public function getChannel() { return $this->channel; } /** * Channel. * * Generated from protobuf field uint32 channel = 7; * @param int $var * @return $this */ public function setChannel($var) { GPBUtil::checkUint32($var); $this->channel = $var; return $this; } /** * RF Chain. * * Generated from protobuf field uint32 rf_chain = 8; * @return int */ public function getRfChain() { return $this->rf_chain; } /** * RF Chain. * * Generated from protobuf field uint32 rf_chain = 8; * @param int $var * @return $this */ public function setRfChain($var) { GPBUtil::checkUint32($var); $this->rf_chain = $var; return $this; } /** * Board. * * Generated from protobuf field uint32 board = 9; * @return int */ public function getBoard() { return $this->board; } /** * Board. * * Generated from protobuf field uint32 board = 9; * @param int $var * @return $this */ public function setBoard($var) { GPBUtil::checkUint32($var); $this->board = $var; return $this; } /** * Antenna. * * Generated from protobuf field uint32 antenna = 10; * @return int */ public function getAntenna() { return $this->antenna; } /** * Antenna. * * Generated from protobuf field uint32 antenna = 10; * @param int $var * @return $this */ public function setAntenna($var) { GPBUtil::checkUint32($var); $this->antenna = $var; return $this; } /** * Location. * * Generated from protobuf field .common.Location location = 11; * @return \Chirpstack\Common\Location|null */ public function getLocation() { return $this->location; } public function hasLocation() { return isset($this->location); } public function clearLocation() { unset($this->location); } /** * Location. * * Generated from protobuf field .common.Location location = 11; * @param \Chirpstack\Common\Location $var * @return $this */ public function setLocation($var) { GPBUtil::checkMessage($var, \Chirpstack\Common\Location::class); $this->location = $var; return $this; } /** * Fine-timestamp type. * * Generated from protobuf field .gw.FineTimestampType fine_timestamp_type = 12; * @return int */ public function getFineTimestampType() { return $this->fine_timestamp_type; } /** * Fine-timestamp type. * * Generated from protobuf field .gw.FineTimestampType fine_timestamp_type = 12; * @param int $var * @return $this */ public function setFineTimestampType($var) { GPBUtil::checkEnum($var, \Chirpstack\Gateway\FineTimestampType::class); $this->fine_timestamp_type = $var; return $this; } /** * Encrypted fine-timestamp data. * * Generated from protobuf field .gw.EncryptedFineTimestamp encrypted_fine_timestamp = 13; * @return \Chirpstack\Gateway\EncryptedFineTimestamp|null */ public function getEncryptedFineTimestamp() { return $this->readOneof(13); } public function hasEncryptedFineTimestamp() { return $this->hasOneof(13); } /** * Encrypted fine-timestamp data. * * Generated from protobuf field .gw.EncryptedFineTimestamp encrypted_fine_timestamp = 13; * @param \Chirpstack\Gateway\EncryptedFineTimestamp $var * @return $this */ public function setEncryptedFineTimestamp($var) { GPBUtil::checkMessage($var, \Chirpstack\Gateway\EncryptedFineTimestamp::class); $this->writeOneof(13, $var); return $this; } /** * Plain fine-timestamp data. * * Generated from protobuf field .gw.PlainFineTimestamp plain_fine_timestamp = 14; * @return \Chirpstack\Gateway\PlainFineTimestamp|null */ public function getPlainFineTimestamp() { return $this->readOneof(14); } public function hasPlainFineTimestamp() { return $this->hasOneof(14); } /** * Plain fine-timestamp data. * * Generated from protobuf field .gw.PlainFineTimestamp plain_fine_timestamp = 14; * @param \Chirpstack\Gateway\PlainFineTimestamp $var * @return $this */ public function setPlainFineTimestamp($var) { GPBUtil::checkMessage($var, \Chirpstack\Gateway\PlainFineTimestamp::class); $this->writeOneof(14, $var); return $this; } /** * Gateway specific context. * * Generated from protobuf field bytes context = 15; * @return string */ public function getContext() { return $this->context; } /** * Gateway specific context. * * Generated from protobuf field bytes context = 15; * @param string $var * @return $this */ public function setContext($var) { GPBUtil::checkString($var, False); $this->context = $var; return $this; } /** * Uplink ID (UUID bytes). * Unique and random ID which can be used to correlate the uplink across * multiple logs. * * Generated from protobuf field bytes uplink_id = 16; * @return string */ public function getUplinkId() { return $this->uplink_id; } /** * Uplink ID (UUID bytes). * Unique and random ID which can be used to correlate the uplink across * multiple logs. * * Generated from protobuf field bytes uplink_id = 16; * @param string $var * @return $this */ public function setUplinkId($var) { GPBUtil::checkString($var, False); $this->uplink_id = $var; return $this; } /** * CRC status. * * Generated from protobuf field .gw.CRCStatus crc_status = 17; * @return int */ public function getCrcStatus() { return $this->crc_status; } /** * CRC status. * * Generated from protobuf field .gw.CRCStatus crc_status = 17; * @param int $var * @return $this */ public function setCrcStatus($var) { GPBUtil::checkEnum($var, \Chirpstack\Gateway\CRCStatus::class); $this->crc_status = $var; return $this; } /** * Optional meta-data map. * * Generated from protobuf field map metadata = 18; * @return \Google\Protobuf\Internal\MapField */ public function getMetadata() { return $this->metadata; } /** * Optional meta-data map. * * Generated from protobuf field map metadata = 18; * @param array|\Google\Protobuf\Internal\MapField $var * @return $this */ public function setMetadata($var) { $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); $this->metadata = $arr; return $this; } /** * @return string */ public function getFineTimestamp() { return $this->whichOneof("fine_timestamp"); } }