src/main/java/de/blau/android/osm/StorageDelegator.java
/**
     * Create relation with a list of RelationMembers as members
     * 
     * @param members RelationMembers to add
     * @return the new relation
     */
Create relation with a list of RelationMembers as members

@param members RelationMembers to add
@return the new relation
Create relation with a list of RelationMembers as members @param members RelationMembers to add @return the new relation
@NonNull
    public Relation createAndInsertRelationFromMembers(@NonNull List<RelationMember> members) {
        dirty = true;
        Relation relation = factory.createRelationWithNewId();
        insertElementUnsafe(relation);
        for (RelationMember member : members) {
            if (member.downloaded()) {
                OsmElement e = member.getElement();
                undo.save(e);
                relation.addMember(member);
                e.addParentRelation(relation);
                onParentRelationChanged(e);
            } else {
                relation.addMember(member);
            }
        }
        return relation;
    }
@ NonNull public Relation createAndInsertRelationFromMembers ( @ NonNull List < RelationMember > members ) { dirty = true ; Relation relation = factory . createRelationWithNewId ( ) ; insertElementUnsafe ( relation ) ; for ( RelationMember member : members ) { if ( member . downloaded ( ) ) { OsmElement e = member . getElement ( ) ; undo . save ( e ) ; relation . addMember ( member ) ; e . addParentRelation ( relation ) ; onParentRelationChanged ( e ) ; } else { relation . addMember ( member ) ; } } return relation ; }
Create relation with a list of RelationMembers as members
Create relation with a list of RelationMembers as members
// undo - nothing done here, relation gets saved/marked on insert