@Override protected WriteAttributeResults handleUnhandledAttributes ( final WriteAttributeResults initialResults, final Map<String, Variant> attributes ) { // check for null WriteAttributeResults writeAttributeResults = initialResults; if ( writeAttributeResults == null ) { writeAttributeResults = new WriteAttributeResults (); } // gather the list of open requests final Map<String, Variant> requests = new HashMap<String, Variant> ( 0 ); for ( final Map.Entry<String, Variant> entry : attributes.entrySet () ) { if ( !writeAttributeResults.containsKey ( entry.getKey () ) ) { requests.put ( entry.getKey (), entry.getValue () ); } } writeAttributeResults.putAll ( this.variable.handleAttributes ( requests ) ); // default for the rest return super.handleUnhandledAttributes ( writeAttributeResults, attributes ); }
@Override protected WriteAttributeResults handleUnhandledAttributes ( final WriteAttributeResults writeAttributeResults, final Map<String, Variant> attributes ) { final Map<String, Variant> addAttributes = new HashMap<String, Variant> (); testFlag ( attributes, addAttributes, "test.error", "test.error" ); testFlag ( attributes, addAttributes, "test.alarm", "test.alarm" ); testFlag ( attributes, addAttributes, "test.warning", "warning" ); testFlag ( attributes, addAttributes, "test.manual", "manual" ); updateData ( null, addAttributes, AttributeMode.UPDATE ); return super.handleUnhandledAttributes ( writeAttributeResults, attributes ); }