simplified MovingRule to only have public attributes

This commit is contained in:
Al0cam 2024-11-14 17:19:05 +01:00
parent bc398e0257
commit 4abc23113c

View file

@ -5,30 +5,15 @@ export class MovingRule {
* TODO: Maybe it should be turned into a RegExp object
* will try with string for now
*/
private _regex: string;
public regex: string;
/**
* This field is used for defining the folder to which the files will be moved
* It can use the previously defined groups to create folders with the same name
*/
private _folder: string;
public folder: string;
constructor(regex?: string, folder?: string) {
this._regex = regex || '';
this._folder = folder || '';
}
public get regex(): string {
return this._regex;
}
public set regex(value: string) {
this._regex = value;
}
public get folder(): string {
return this._folder;
}
public set folder(value: string) {
this._folder = value;
this.regex = regex || '';
this.folder = folder || '';
}
}