Second version of JMX
This commit is contained in:
parent
a69315adc0
commit
a3f58468f5
32 changed files with 272 additions and 107 deletions
|
|
@ -33,7 +33,7 @@ public enum Base2Terminator implements BãßBȍőnEnumInstanceʸᴰ<Base2Termina
|
|||
public BãßBȍőnCoffinʸᴰ<BãßBȍőnGlyphSetKeyʸᴰ> GET_BBC() { return BBC; }
|
||||
|
||||
private Base2Terminator() {
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public int Bãß2ReadTong(InputStream input, List<V072Tong> output) throws IOException {
|
||||
|
|
|
|||
|
|
@ -85,6 +85,6 @@ public enum BaseGlyphSet implements BãßBȍőnGlyphSetʸᴰ<BaseGlyphSet> {
|
|||
BBC.PUT_OBJ(BãßBȍőnGlyphSetKeyʸᴰ.NUMBERS, numbers);
|
||||
BBC.PUT_OBJ(BãßBȍőnGlyphSetKeyʸᴰ.HEXIMALS, hex);
|
||||
BBC.PUT_OBJ(BãßBȍőnGlyphSetKeyʸᴰ.GEMATRIA, gematria);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,6 +21,6 @@ public enum T02PartBinary implements BãßBȍőnPartʸᴰ<T02PartBinary> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.DIAL_TONE, dialTone);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,6 +22,6 @@ public enum T03PartTrit implements BãßBȍőnPartʸᴰ<T03PartTrit> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.DIAL_TONE, dialTone);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ public enum T04PartQuad implements BãßBȍőnPartAlt1ʸᴰ<T04PartQuad> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public T02PartBinary splitPartBinary(T02PartBinary part) {
|
||||
|
|
|
|||
|
|
@ -28,6 +28,6 @@ public enum T05PartPental implements BãßBȍőnPartAlt2ʸᴰ<T05PartPental> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_2_VALUE, alt2Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ public enum T06PartSeximal implements BãßBȍőnPartAlt1ʸᴰ<T06PartSeximal> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public T02PartBinary splitPartBinary() {
|
||||
|
|
|
|||
|
|
@ -28,6 +28,6 @@ public enum T07PartPlanIt implements BãßBȍőnPartAlt1ʸᴰ<T07PartPlanIt> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ public enum T08PartOctal implements BãßBȍőnPartʸᴰ<T08PartOctal>,BãßBȍ
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.SHIFT_BITS, Integer.valueOf(shiftBits));
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public static T08PartOctal indexOf(T08PartOctal group, int value) {
|
||||
|
|
|
|||
|
|
@ -28,6 +28,6 @@ public enum T09PartNonary implements BãßBȍőnPartʸᴰ<T09PartNonary> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.DIAL_TONE, dialTone);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,6 +33,6 @@ public enum T10PartDecimal implements BãßBȍőnPartAlt2ʸᴰ<T10PartDecimal> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_2_VALUE, alt2Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,6 +32,6 @@ public enum T11PartUndecimal implements BãßBȍőnPartAlt1ʸᴰ<T11PartUndecima
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,6 +33,6 @@ public enum T12PartUncial implements BãßBȍőnPartAlt1ʸᴰ<T12PartUncial> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public enum T16PartHex implements BãßBȍőnPartAlt1ʸᴰ<T16PartHex> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_1_VALUE, alt1Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public T02PartBinary splitPartBinary(T04PartQuad part) {
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ public enum T20PartScore implements BãßBȍőnPartAlt4ʸᴰ<T20PartScore> {
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_2_VALUE, alt2Value);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_3_VALUE, alt3Value);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.ALT_4_VALUE, alt4Value);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
|
||||
public T20PartScore BãßValueOfOpenLC(String openLCKey) {
|
||||
|
|
|
|||
|
|
@ -79,6 +79,6 @@ public enum T60PartSexagesimal implements BãßBȍőnPartʸᴰ<T60PartSexagesima
|
|||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.DIAL_TONE, dialTone);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_KEY, chinaKey);
|
||||
BBC.PUT_OBJ(BãßBȍőnPartKeyʸᴰ.CHINA_VALUE, chinaValue);
|
||||
BBC.INIT_BOON(this);
|
||||
BBC.BOON_INIT(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,35 +8,47 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnClassInfoʸᴰ;
|
|||
import love.distributedrebirth.bassboonyd.BãßBȍőnCoffinOpenʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnCoffinʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnEnumInstanceʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnEnumJmxKeyʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnEnumJmxʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnPackageInfoʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.jmx.BooleanAttributeᴶᴹˣ;
|
||||
import love.distributedrebirth.bassboonyd.jmx.MBeanStoreKeyᴶᴹˣ;
|
||||
import love.distributedrebirth.bassboonyd.jmx.BãßBȍőnEnumJmxʸᴰ;
|
||||
import love.distributedrebirth.bassboonyd.jmx.GuageCounterᴶᴹˣ;
|
||||
import love.distributedrebirth.bassboonyd.jmx.StringAttributeᴶᴹˣ;
|
||||
import love.distributedrebirth.numberxd.base2t.BasePartFactory;
|
||||
import love.distributedrebirth.numberxd.base2t.part.BãßBȍőnPartKeyʸᴰ;
|
||||
import love.distributedrebirth.numberxd.base2t.part.BãßBȍőnPartʸᴰ;
|
||||
|
||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
@BãßBȍőnClassInfoʸᴰ(name = "TOSWarpCore", purpose = "The warpcore writer and armor manager.")
|
||||
public enum TOSWarpCore implements BãßBȍőnEnumInstanceʸᴰ<TOSWarpCore>,BãßBȍőnEnumJmxʸᴰ<TOSWarpCore,BãßBȍőnEnumJmxKeyʸᴰ> {
|
||||
@BãßBȍőnPackageInfoʸᴰ(name = "love.distributedrebirth.numberxd")
|
||||
public enum TOSWarpCore implements BãßBȍőnEnumInstanceʸᴰ<TOSWarpCore>,BãßBȍőnEnumJmxʸᴰ<TOSWarpCore,MBeanStoreKeyᴶᴹˣ> {
|
||||
|
||||
INSTANCE;
|
||||
|
||||
private final BãßBȍőnCoffinOpenʸᴰ<BãßBȍőnEnumJmxKeyʸᴰ> BBC = BãßBȍőnCoffinOpenʸᴰ.newInstance();
|
||||
public BãßBȍőnCoffinʸᴰ<BãßBȍőnEnumJmxKeyʸᴰ> GET_BBC() { return BBC; }
|
||||
private final BãßBȍőnCoffinOpenʸᴰ<MBeanStoreKeyᴶᴹˣ> BBC = BãßBȍőnCoffinOpenʸᴰ.newInstance();
|
||||
public BãßBȍőnCoffinʸᴰ<MBeanStoreKeyᴶᴹˣ> GET_BBC() { return BBC; }
|
||||
|
||||
private String armedWarpCipherName;
|
||||
private String armedWarpCipherDescription;
|
||||
|
||||
private final GuageCounter readCounter;
|
||||
private final GuageCounter writeCounter;
|
||||
private final BooleanAttributeᴶᴹˣ armedWarpCipherLock;
|
||||
private final StringAttributeᴶᴹˣ armedWarpWaterName;
|
||||
private final StringAttributeᴶᴹˣ armedWarpWaterDesc;
|
||||
private final GuageCounterᴶᴹˣ warpCoreReads;
|
||||
private final GuageCounterᴶᴹˣ warpCoreWrites;
|
||||
|
||||
private TOSWarpCore() {
|
||||
BBC.INIT_BOON(this);
|
||||
initJmx(BãßBȍőnEnumJmxKeyʸᴰ.JMX);
|
||||
readCounter = BȍőnInitGuage(BãßBȍőnEnumJmxKeyʸᴰ.JMX, "reads", "The amount of warpcore reads.");
|
||||
writeCounter = BȍőnInitGuage(BãßBȍőnEnumJmxKeyʸᴰ.JMX, "writes", "The amount of warpcore writes.");
|
||||
BBC.BOON_INIT(this);
|
||||
BȍőnJmxInit(MBeanStoreKeyᴶᴹˣ.JMX);
|
||||
warpCoreReads = BȍőnJmxInitGuageCounter(MBeanStoreKeyᴶᴹˣ.JMX, "warpCoreReads", "The amount of warpcore reads.");
|
||||
warpCoreWrites = BȍőnJmxInitGuageCounter(MBeanStoreKeyᴶᴹˣ.JMX, "warpCoreWrites", "The amount of warpcore writes.");
|
||||
armedWarpWaterName = BȍőnJmxInitStringAttribute(MBeanStoreKeyᴶᴹˣ.JMX, "armedWarpWaterName", "The armed water cipher name.");
|
||||
armedWarpWaterName.setValueString("default");
|
||||
armedWarpWaterDesc = BȍőnJmxInitStringAttribute(MBeanStoreKeyᴶᴹˣ.JMX, "armedWarpWaterDesc", "The armed water cipher description.");
|
||||
armedWarpWaterDesc.setValueString("Current active cipher.");
|
||||
armedWarpCipherLock = BȍőnJmxInitBooleanAttribute(MBeanStoreKeyᴶᴹˣ.JMX, "armedWarpCipherLock", "Is the water cipher locked.");
|
||||
armedWarpCipherLock.setValueBoolean(false);
|
||||
}
|
||||
|
||||
public void BãßLockWarpCipher() {
|
||||
armedWarpCipherLock.setValueBoolean(true);
|
||||
for (int base:BasePartFactory.INSTANCE.BãßBases()) {
|
||||
for (BãßBȍőnPartʸᴰ<?> part:BasePartFactory.INSTANCE.BãßBuildPartsByBase(base)) {
|
||||
BãßBȍőnCoffinOpenʸᴰ.class.cast(part.GET_BBC()).LOCK_COFFIN();
|
||||
|
|
@ -45,18 +57,10 @@ public enum TOSWarpCore implements BãßBȍőnEnumInstanceʸᴰ<TOSWarpCore>,Bã
|
|||
}
|
||||
|
||||
public WaterBucket BãßCurrentWarpCore() {
|
||||
readCounter.increment();
|
||||
warpCoreReads.increment();
|
||||
WaterCipher warpCipher = new WaterCipher();
|
||||
if (armedWarpCipherName == null) {
|
||||
warpCipher.setName("default");
|
||||
} else {
|
||||
warpCipher.setName(armedWarpCipherName);
|
||||
}
|
||||
if (armedWarpCipherDescription == null) {
|
||||
warpCipher.setName("Current active cipher.");
|
||||
} else {
|
||||
warpCipher.setDescription(armedWarpCipherDescription);
|
||||
}
|
||||
warpCipher.setName(armedWarpWaterName.getValueString());
|
||||
warpCipher.setDescription(armedWarpWaterDesc.getValueString());
|
||||
for (int base:BasePartFactory.INSTANCE.BãßBases()) {
|
||||
WaterCipherHeart heart = new WaterCipherHeart();
|
||||
BãßBȍőnPartʸᴰ<?>[] bases = BasePartFactory.INSTANCE.BãßBuildPartsByBase(base);
|
||||
|
|
@ -77,9 +81,9 @@ public enum TOSWarpCore implements BãßBȍőnEnumInstanceʸᴰ<TOSWarpCore>,Bã
|
|||
}
|
||||
|
||||
public void BãßArmWarpCore(WaterBucket warpBucket) {
|
||||
writeCounter.increment();
|
||||
armedWarpCipherName = warpBucket.theWater().getName();
|
||||
armedWarpCipherDescription = warpBucket.theWater().getDescription();
|
||||
warpCoreWrites.increment();
|
||||
armedWarpWaterName.setValueString(warpBucket.theWater().getName());
|
||||
armedWarpWaterDesc.setValueString(warpBucket.theWater().getDescription());
|
||||
for (WaterCipherHeart heart:warpBucket.theWater().getCipherHearts()) {
|
||||
BãßBȍőnPartʸᴰ<?>[] bases = BasePartFactory.INSTANCE.BãßBuildPartsByBase(heart.getBass());
|
||||
Map<String, BãßBȍőnPartʸᴰ<?>> baseParts = new HashMap<>();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue