forked from MapComplete/MapComplete
Add metadata in changeset with (binned) distance to changed feature
This commit is contained in:
parent
e8ce53d5eb
commit
8e66313ef1
21 changed files with 178 additions and 41 deletions
|
@ -8,6 +8,18 @@ import {ChangeDescription} from "./ChangeDescription";
|
|||
export default abstract class OsmChangeAction {
|
||||
|
||||
private isUsed = false
|
||||
public readonly trackStatistics: boolean;
|
||||
/**
|
||||
* The ID of the object that is the center of this change.
|
||||
* Null if the action creates a new object
|
||||
* Undefined if such an id does not make sense
|
||||
*/
|
||||
public readonly mainObjectId: string;
|
||||
|
||||
constructor(mainObjectId: string, trackStatistics: boolean = true) {
|
||||
this.trackStatistics = trackStatistics;
|
||||
this.mainObjectId = mainObjectId
|
||||
}
|
||||
|
||||
public Perform(changes: Changes) {
|
||||
if (this.isUsed) {
|
||||
|
@ -18,6 +30,4 @@ export default abstract class OsmChangeAction {
|
|||
}
|
||||
|
||||
protected abstract CreateChangeDescriptions(changes: Changes): Promise<ChangeDescription[]>
|
||||
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue