|
|
@ -2,7 +2,6 @@ package com.fr.plugin.demo; |
|
|
|
|
|
|
|
|
|
|
|
import com.fr.extended.chart.AbstractDataConfig; |
|
|
|
import com.fr.extended.chart.AbstractDataConfig; |
|
|
|
import com.fr.extended.chart.ExtendedField; |
|
|
|
import com.fr.extended.chart.ExtendedField; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
|
|
|
|
import com.fr.stable.AssistUtils; |
|
|
|
import com.fr.stable.AssistUtils; |
|
|
|
import com.fr.stable.xml.XMLPrintWriter; |
|
|
|
import com.fr.stable.xml.XMLPrintWriter; |
|
|
|
import com.fr.stable.xml.XMLableReader; |
|
|
|
import com.fr.stable.xml.XMLableReader; |
|
|
@ -13,6 +12,7 @@ import com.fr.stable.xml.XMLableReader; |
|
|
|
public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
|
|
|
|
|
|
|
|
private ExtendedField x = new ExtendedField(); |
|
|
|
private ExtendedField x = new ExtendedField(); |
|
|
|
|
|
|
|
private String targetName; |
|
|
|
private ExtendedField y = new ExtendedField(); |
|
|
|
private ExtendedField y = new ExtendedField(); |
|
|
|
private ExtendedField z = new ExtendedField(); |
|
|
|
private ExtendedField z = new ExtendedField(); |
|
|
|
|
|
|
|
|
|
|
@ -40,9 +40,18 @@ public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
this.z = z; |
|
|
|
this.z = z; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public String getTargetName() { |
|
|
|
|
|
|
|
return targetName; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void setTargetName(String targetName) { |
|
|
|
|
|
|
|
this.targetName = targetName; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
protected void readAttr(XMLableReader reader) { |
|
|
|
protected void readAttr(XMLableReader reader) { |
|
|
|
readExtendedField(x, "x", reader); |
|
|
|
readExtendedField(x, "x", reader); |
|
|
|
|
|
|
|
this.setTargetName(reader.getAttrAsString("targetName", "")); |
|
|
|
readExtendedField(y, "y", reader); |
|
|
|
readExtendedField(y, "y", reader); |
|
|
|
readExtendedField(z, "z", reader); |
|
|
|
readExtendedField(z, "z", reader); |
|
|
|
} |
|
|
|
} |
|
|
@ -50,6 +59,7 @@ public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
protected void writeAttr(XMLPrintWriter writer) { |
|
|
|
protected void writeAttr(XMLPrintWriter writer) { |
|
|
|
writeExtendedField(x, "x", writer); |
|
|
|
writeExtendedField(x, "x", writer); |
|
|
|
|
|
|
|
writer.attr("targetName", this.getTargetName()); |
|
|
|
writeExtendedField(y, "y", writer); |
|
|
|
writeExtendedField(y, "y", writer); |
|
|
|
writeExtendedField(z, "z", writer); |
|
|
|
writeExtendedField(z, "z", writer); |
|
|
|
} |
|
|
|
} |
|
|
@ -67,6 +77,7 @@ public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
public DemoDataConfig clone() throws CloneNotSupportedException { |
|
|
|
public DemoDataConfig clone() throws CloneNotSupportedException { |
|
|
|
DemoDataConfig result = new DemoDataConfig(); |
|
|
|
DemoDataConfig result = new DemoDataConfig(); |
|
|
|
result.setX(this.getX().clone()); |
|
|
|
result.setX(this.getX().clone()); |
|
|
|
|
|
|
|
result.setTargetName(this.getTargetName()); |
|
|
|
result.setY(this.getY().clone()); |
|
|
|
result.setY(this.getY().clone()); |
|
|
|
result.setZ(this.getZ().clone()); |
|
|
|
result.setZ(this.getZ().clone()); |
|
|
|
return result; |
|
|
|
return result; |
|
|
@ -74,13 +85,14 @@ public class DemoDataConfig extends AbstractDataConfig { |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public int hashCode() { |
|
|
|
public int hashCode() { |
|
|
|
return super.hashCode() + AssistUtils.hashCode(this.getX(), this.getY(), this.getZ()); |
|
|
|
return super.hashCode() + AssistUtils.hashCode(this.getX(), this.getY(), this.getZ(), this.getTargetName()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public boolean equals(Object obj) { |
|
|
|
public boolean equals(Object obj) { |
|
|
|
return obj instanceof DemoDataConfig |
|
|
|
return obj instanceof DemoDataConfig |
|
|
|
&& AssistUtils.equals(this.getX(), ((DemoDataConfig) obj).getX()) |
|
|
|
&& AssistUtils.equals(this.getX(), ((DemoDataConfig) obj).getX()) |
|
|
|
|
|
|
|
&& AssistUtils.equals(this.getTargetName(), ((DemoDataConfig) obj).getTargetName()) |
|
|
|
&& AssistUtils.equals(this.getY(), ((DemoDataConfig) obj).getY()) |
|
|
|
&& AssistUtils.equals(this.getY(), ((DemoDataConfig) obj).getY()) |
|
|
|
&& AssistUtils.equals(this.getZ(), ((DemoDataConfig) obj).getZ()) |
|
|
|
&& AssistUtils.equals(this.getZ(), ((DemoDataConfig) obj).getZ()) |
|
|
|
; |
|
|
|
; |
|
|
|