Changeset 292:f6ac5e3ea02c in finroc_tools_finstruct-java


Ignore:
Timestamp:
16.02.2021 13:08:43 (2 months ago)
Author:
Max Reichardt <max.reichardt@…>
Branch:
default
Phase:
public
Tags:
tip
Message:

Makes FinrocComponentFactory Property Editor XML adapater suitable for more data types

File:
1 edited

Legend:

Unmodified
Added
Removed
  • propertyeditor/FinrocComponentFactory.java

    r288 r292  
    231231        public void set(XML s) throws Exception { 
    232232            BinarySerializable buffer = (BinarySerializable)dataType.createInstance(); 
     233            if (buffer instanceof Copyable) { 
     234                ((Copyable)buffer).copyFrom(wrapped.get()); 
     235            } 
    233236            XMLDocument d = new XMLDocument(new InputSource(new StringReader(s.toString())), false); 
    234237            ((XMLSerializable)buffer).deserialize(d.getRootNode()); 
Note: See TracChangeset for help on using the changeset viewer.