Class VHTOperation
- java.lang.Object
-
- com.facebook.openwifi.cloudsdk.ies.VHTOperation
-
public class VHTOperation extends Object
Very High Throughput (VHT) Operation Element, which is potentially present in wifiscan entries. Introduced in 802.11ac (2013). Refer to the 802.11 specification (section 9.4.2.158)
-
-
Field Summary
Fields Modifier and Type Field Description short
channel1
If the channel is 20 MHz, 40 MHz, or 80 MHz wide, this parameter is the channel number.short
channel2
This should be zero unless the channel is 160MHz or 80+80 MHz wide.byte
channelWidth
This field is 0 if the channel width is 20 MHz or 40 MHz, and 1 otherwise.static int
TYPE
Defined in 802.11 table 9-92byte[]
vhtMcsForNss
An 8-element array where each element is between 0 and 4 inclusive.
-
Constructor Summary
Constructors Constructor Description VHTOperation(byte channelWidth, short channel1, short channel2, byte[] vhtMcsForNss)
Constructs anHTOperationElement
using the given field values.VHTOperation(String vhtOper)
Constructs aVHTOperationElement
by decodingvhtOper
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
int
hashCode()
boolean
matchesForAggregation(VHTOperation other)
Determine whetherthis
andother
"match" for the purpose of aggregating statistics.static boolean
matchesVhtForAggregation(String vhtOper1, String vhtOper2)
Determines whether two VHT operation elements should have their statistics aggregated.
-
-
-
Field Detail
-
TYPE
public static final int TYPE
Defined in 802.11 table 9-92- See Also:
- Constant Field Values
-
channelWidth
public final byte channelWidth
This field is 0 if the channel width is 20 MHz or 40 MHz, and 1 otherwise. Values of 2 and 3 are deprecated.
-
channel1
public final short channel1
If the channel is 20 MHz, 40 MHz, or 80 MHz wide, this parameter is the channel number. E.g., the channel centered at 5180 MHz is channel 36. For a 160 MHz wide channel, this parameter is the channel number of the 80MHz channel that contains the primary channel. For a 80+80 MHz wide channel, this parameter is the channel number of the primary channel.This field is an unsigned byte in the specification (i.e., with values between 0 and 255). But because Java only supports signed bytes, a short data type is used to store the value.
-
channel2
public final short channel2
This should be zero unless the channel is 160MHz or 80+80 MHz wide. If the channel is 160 MHz wide, this parameter is the channel number of the 160 MHz wide channel. If the channel is 80+80 MHz wide, this parameter is the channel index of the secondary 80 MHz wide channel.This field is an unsigned byte in the specification (i.e., with values between 0 and 255). But because Java only supports signed bytes, a short data type is used to store the value.
-
vhtMcsForNss
public final byte[] vhtMcsForNss
An 8-element array where each element is between 0 and 4 inclusive. MCS means Modulation and Coding Scheme. NSS means Number of Spatial Streams. There can be 1, 2, ..., or 8 spatial streams. For each NSS, the corresponding element in the array should specify which MCSs are supported for that NSS in the following manner: 0 indicates support for VHT-MCS 0-7, 1 indicates support for VHT-MCS 0-8, 2 indicates support for VHT-MCS 0-9, and 3 indicates that no VHT-MCS is supported for that NSS. For the specifics of what each VHT-MCS is, see IEEE 802.11-2020, Table "21-29" through Table "21-60".
-
-
Constructor Detail
-
VHTOperation
public VHTOperation(String vhtOper)
Constructs aVHTOperationElement
by decodingvhtOper
.- Parameters:
vhtOper
- a base64 encoded properly formatted VHT operation element (see 802.11 standard)
-
VHTOperation
public VHTOperation(byte channelWidth, short channel1, short channel2, byte[] vhtMcsForNss)
Constructs anHTOperationElement
using the given field values. See 802.11 for more details.For details about the parameters, see the javadocs for the corresponding member variables.
-
-
Method Detail
-
matchesForAggregation
public boolean matchesForAggregation(VHTOperation other)
Determine whetherthis
andother
"match" for the purpose of aggregating statistics.- Parameters:
other
- another VHT operation element- Returns:
- true if the the operation elements "match" for the purpose of aggregating statistics; false otherwise.
-
matchesVhtForAggregation
public static boolean matchesVhtForAggregation(String vhtOper1, String vhtOper2)
Determines whether two VHT operation elements should have their statistics aggregated.- Parameters:
vhtOper1
- a base64 encoded properly formatted VHT operation element (see 802.11 standard)vhtOper2
- a base64 encoded properly formatted VHT operation element (see 802.11 standard)- Returns:
- true if the two inputs should have their statistics aggregated; false otherwise.
-
-