2017-03-08 21:49:41 +00:00
|
|
|
import { ParagraphProperties } from "../paragraph/properties";
|
|
|
|
import { RunProperties } from "../run/properties";
|
|
|
|
import { XmlComponent } from "./";
|
2016-05-20 00:40:31 +01:00
|
|
|
|
|
|
|
export class ParagraphPropertyXmlComponent extends XmlComponent {
|
|
|
|
private paragraphProperties: ParagraphProperties;
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
constructor(rootKey: string) {
|
2016-05-20 00:40:31 +01:00
|
|
|
super(rootKey);
|
|
|
|
this.paragraphProperties = new ParagraphProperties();
|
|
|
|
this.root.push(this.paragraphProperties);
|
|
|
|
}
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
public clearVariables(): void {
|
2016-05-20 00:40:31 +01:00
|
|
|
this.paragraphProperties.clearVariables();
|
|
|
|
|
|
|
|
delete this.paragraphProperties;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export class RunPropertyXmlComponent extends XmlComponent {
|
|
|
|
private runProperties: RunProperties;
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
constructor(rootKey: string) {
|
2016-05-20 00:40:31 +01:00
|
|
|
super(rootKey);
|
|
|
|
this.runProperties = new RunProperties();
|
|
|
|
this.root.push(this.runProperties);
|
|
|
|
}
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
public clearVariables(): void {
|
2016-05-20 00:40:31 +01:00
|
|
|
this.runProperties.clearVariables();
|
|
|
|
|
|
|
|
delete this.runProperties;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export class MultiPropertyXmlComponent extends XmlComponent {
|
|
|
|
private runProperties: RunProperties;
|
|
|
|
private paragraphProperties: ParagraphProperties;
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
constructor(rootKey: string) {
|
2016-05-20 00:40:31 +01:00
|
|
|
super(rootKey);
|
|
|
|
this.runProperties = new RunProperties();
|
|
|
|
this.root.push(this.runProperties);
|
2016-05-26 15:08:34 +01:00
|
|
|
|
2016-05-20 00:40:31 +01:00
|
|
|
this.paragraphProperties = new ParagraphProperties();
|
|
|
|
this.root.push(this.paragraphProperties);
|
|
|
|
}
|
|
|
|
|
2017-03-08 21:49:41 +00:00
|
|
|
public clearVariables(): void {
|
2016-05-20 00:40:31 +01:00
|
|
|
this.runProperties.clearVariables();
|
|
|
|
this.paragraphProperties.clearVariables();
|
|
|
|
|
|
|
|
delete this.runProperties;
|
|
|
|
delete this.paragraphProperties;
|
|
|
|
}
|
2017-03-08 21:49:41 +00:00
|
|
|
}
|