# Attributes

    struct Attributes

Attributes for the `https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html`.
- `


  ### [attributeList](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV13attributeListSays6UInt32VGSgvp)


  ` A list of the attribute IDs of the attributes supported by the cluster instance.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var attributeList: [UInt32]? { get }

- `


  ### [powerMode](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV9powerModeAE0fK4EnumOSgvp)


  ` The current mode of the server.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var powerMode: https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/PowerModeEnum.html? { get }

- `


  ### [numberOfMeasurementTypes](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV08numberOfgC0s5UInt8VSgvp)


  ` Maximum number of measurement types the server is capable of reporting.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var numberOfMeasurementTypes: UInt8? { get }

- `


  ### [accuracy](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV8accuracySayAE0G14AccuracyStructVGSgvp)


  ` List of accuracy specifications for the measurement types supported by the server.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var accuracy: [https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/MeasurementAccuracyStruct.html]? { get }

- `


  ### [ranges](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV6rangesSayAE0G11RangeStructVGSgvp)


  ` The measured ranges for different measurement types. Each measurement type is limited to one
  entry in this list, which represents the range of measurements in the most recent
  measurement period.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var ranges: [https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/MeasurementRangeStruct.html]? { get }

- `


  ### [voltage](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV7voltages5Int64VSgvp)


  ` Voltage in millivolts (mV).
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var voltage: Int64? { get }

- `


  ### [activeCurrent](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV13activeCurrents5Int64VSgvp)


  ` The most recent current reading in milliamps (mA). A positive value means that current is
  flowing into the server, and a negative value means that current is flowing out of the
  server.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var activeCurrent: Int64? { get }

- `


  ### [reactiveCurrent](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV15reactiveCurrents5Int64VSgvp)


  ` The most recent `reactiveCurrent` reading in milliamps (mA). A positive value means that
  current is flowing into the server, and a negative value means that current is flowing out
  of the server.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var reactiveCurrent: Int64? { get }

- `


  ### [apparentCurrent](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV15apparentCurrents5Int64VSgvp)


  ` The most recent `apparentCurrent` (square root sum of the squares of active and reactive
  currents) reading in milliamps (mA).
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var apparentCurrent: Int64? { get }

- `


  ### [activePower](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV06activeF0s5Int64VSgvp)


  ` The most recent power reading in milliwatts (mW). A positive value means that power is being
  imported, and a negative value means that power is being exported.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var activePower: Int64? { get }

- `


  ### [reactivePower](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV08reactiveF0s5Int64VSgvp)


  ` The most recent `reactivePower` reading in millivolt-amps reactive (mVAR). A positive value
  denotes power imported, and a negative value denotes power exported.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var reactivePower: Int64? { get }

- `


  ### [apparentPower](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV08apparentF0s5Int64VSgvp)


  ` The most recent `apparentPower` reading in millivolt-amps (mVA). A positive value denotes
  power imported, and a negative value denotes power exported.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var apparentPower: Int64? { get }

- `


  ### [rmsVoltage](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV10rmsVoltages5Int64VSgvp)


  ` Root mean squared voltage in millivolts (mV).
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var rmsVoltage: Int64? { get }

- `


  ### [rmsCurrent](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV10rmsCurrents5Int64VSgvp)


  ` Root mean squared current in milliamps (mA). A positive value means that current is flowing
  into the server, and a negative value means that current is flowing out of the server.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var rmsCurrent: Int64? { get }

- `


  ### [rmsPower](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV03rmsF0s5Int64VSgvp)


  ` Root mean squared power in milliwatts (mW). A positive value means that power is being
  imported, and a negative value means that power is being exported.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var rmsPower: Int64? { get }

- `


  ### [frequency](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV9frequencys5Int64VSgvp)


  ` The most recent frequency reading in millihertz (mHz).
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var frequency: Int64? { get }

- `


  ### [harmonicCurrents](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV16harmonicCurrentsSayAE08HarmonicG6StructVGSgvp)


  ` A list of `https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/HarmonicMeasurementStruct.html` values, where each value represents the harmonic
  current reading for the harmonic order as specified by `order`.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var harmonicCurrents: [https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/HarmonicMeasurementStruct.html]? { get }

- `


  ### [harmonicPhases](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV14harmonicPhasesSayAE08HarmonicG6StructVGSgvp)


  ` A list of `https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/HarmonicMeasurementStruct.html` values, where each value represents the harmonic phase
  reading for the harmonic order as specified by `order`.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var harmonicPhases: [https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/HarmonicMeasurementStruct.html]? { get }

- `


  ### [powerFactor](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV11powerFactors5Int64VSgvp)


  ` The power factor ratio in +/- 1/100ths of a percent.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var powerFactor: Int64? { get }

- `


  ### [neutralCurrent](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV14neutralCurrents5Int64VSgvp)


  ` The most recent `neutralCurrent` reading in milliamps (mA). Typically, this is the magnitude
  of the vector sum of the phase currents. A positive value represents an imbalance between
  the phase currents when power is imported. A negative value represents an imbalance between
  the phase currents when power is exported.
  Nullable: true.

  #### Declaration

  Swift

      @TraitAttribute
      var neutralCurrent: Int64? { get }

- `


  ### [generatedCommandList](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV20generatedCommandListSays6UInt32VGSgvp)


  ` A list of server-generated commands (server to client) which are supported by this
  cluster server instance.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var generatedCommandList: [UInt32]? { get }

- `


  ### [acceptedCommandList](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV19acceptedCommandListSays6UInt32VGSgvp)


  ` A list of client-generated commands which are supported by this cluster server instance.

  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var acceptedCommandList: [UInt32]? { get }

- `


  ### [featureMap](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV10featureMapAE7FeatureVSgvp)


  ` Whether the server supports zero or more optional cluster features. A cluster feature
  is a set of cluster elements that are mandatory or optional for a defined feature of the
  cluster. If a cluster feature is supported by the cluster instance, then the corresponding
  bit is set to 1, otherwise the bit is set to 0 (zero).
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var featureMap: https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Feature.html? { get }

- `


  ### [clusterRevision](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV15clusterRevisions6UInt16VSgvp)


  ` The revision of the server cluster specification supported by the cluster instance.
  Nullable: false.

  #### Declaration

  Swift

      @TraitAttribute
      var clusterRevision: UInt16? { get }

- `


  ### [identifier](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV10identifierSSvpZ)


  ` The trait identifier.

  #### Declaration

  Swift

      static var identifier: String { get }

- `


  ### [encode(with:)](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV6encode4withy0aB3SDK0H7EncoderC_tKF)


  ` Writes this object to the given `TraitEncoder`.
  Throws `HomeError.encodingFailed` if the data could not be encoded.

  #### Declaration

  Swift

      func encode(with encoder: TraitEncoder) throws

- `


  ### [==(_:_:)](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV2eeoiySbAG_AGtFZ)


  ` Returns a Boolean value indicating whether two values are equal.

  Equality is the inverse of inequality. For any values `a` and `b`,
  `a == b` implies that `a != b` is `false`.

  #### Declaration

  Swift

      static func == (lhs: https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.Attributes, rhs: https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter.html.https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait.html.Attributes) -> Bool

  #### Parameters

  |---|---|
  | ` lhs ` | A value to compare. |
  | ` rhs ` | Another value to compare. |

- `


  ### [hash(into:)](https://developers.home.google.com/reference/swift/GoogleHomeTypes/Enums/Matter/ElectricalPowerMeasurementTrait/Attributes#/s:15GoogleHomeTypes6MatterO31ElectricalPowerMeasurementTraitV10AttributesV4hash4intoys6HasherVz_tF)


  ` Hashes the essential components of this value by feeding them into the
  given hasher.

  Implement this method to conform to the `Hashable` protocol. The
  components used for hashing must be the same as the components compared
  in your type's `==` operator implementation. Call `hasher.combine(_:)`
  with each of these components.
  Important

  In your implementation of `hash(into:)`,
  don't call `finalize()` on the `hasher` instance provided,
  or replace it with a different instance.
  Doing so may become a compile-time error in the future.

  #### Declaration

  Swift

      func hash(into hasher: inout Hasher)