@Test public void testOneMatchingObject() throws Exception { final AttributeAddress expectedAddress = new AttributeAddress(this.register.getClassId(), this.register.getObisCodeAsString(), this.register.getDefaultAttributeId(), null); final Optional<AttributeAddress> attributeAddress = this.service.findAttributeAddress(this.device422, DlmsObjectType.ACTIVE_ENERGY_IMPORT, null); AttributeAddressAssert.is(attributeAddress.get(), expectedAddress); }
public Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type, final Integer channel) { return this.findAttributeAddressForProfile(device, type, channel, null, null, null) .map(AttributeAddressForProfile::getAttributeAddress); }
DlmsObjectConfigService { public Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type, final Integer channel) { return this.findAttributeAddressForProfile(device, type, channel, null, null, null) .map(AttributeAddressForProfile::getAttributeAddress); } }
DlmsObjectConfigService { public Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type, final Integer channel) { return this.findAttributeAddressForProfile(device, type, channel, null, null, null) .map(AttributeAddressForProfile::getAttributeAddress); } @Autowired  DlmsObjectConfigService(final DlmsHelper dlmsHelper, final List<DlmsObjectConfig> dlmsObjectConfigs); }
DlmsObjectConfigService { public Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type, final Integer channel) { return this.findAttributeAddressForProfile(device, type, channel, null, null, null) .map(AttributeAddressForProfile::getAttributeAddress); } @Autowired  DlmsObjectConfigService(final DlmsHelper dlmsHelper, final List<DlmsObjectConfig> dlmsObjectConfigs); Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type,
                                                           final Integer channel); Optional<AttributeAddressForProfile> findAttributeAddressForProfile(final DlmsDevice device,
                                                                               final DlmsObjectType type, final Integer channel, final DateTime from, final DateTime to,
                                                                               final Medium filterMedium); Optional<DlmsObject> findDlmsObject(final Protocol protocol, final DlmsObjectType type,
                                               final Medium filterMedium); List<AttributeAddress> getAttributeAddressesForScalerUnit(final AttributeAddressForProfile attributeAddressForProfile,
                                                                     final Integer channel); }
DlmsObjectConfigService { public Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type, final Integer channel) { return this.findAttributeAddressForProfile(device, type, channel, null, null, null) .map(AttributeAddressForProfile::getAttributeAddress); } @Autowired  DlmsObjectConfigService(final DlmsHelper dlmsHelper, final List<DlmsObjectConfig> dlmsObjectConfigs); Optional<AttributeAddress> findAttributeAddress(final DlmsDevice device, final DlmsObjectType type,
                                                           final Integer channel); Optional<AttributeAddressForProfile> findAttributeAddressForProfile(final DlmsDevice device,
                                                                               final DlmsObjectType type, final Integer channel, final DateTime from, final DateTime to,
                                                                               final Medium filterMedium); Optional<DlmsObject> findDlmsObject(final Protocol protocol, final DlmsObjectType type,
                                               final Medium filterMedium); List<AttributeAddress> getAttributeAddressesForScalerUnit(final AttributeAddressForProfile attributeAddressForProfile,
                                                                     final Integer channel);  }