Converted to BassBone model
This commit is contained in:
parent
efc2bc74a2
commit
01a37a1496
|
@ -55,11 +55,11 @@ public class GroßGetậl6ˢᴰ implements BaseNumberTyte<GroßGetậl6ˢᴰ> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T12PartUncial.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T12PartUncial.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T12PartUncial.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T12PartUncial.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -53,11 +53,11 @@ public class KlompGetậl4ˢᴰ implements BaseNumberTyte<KlompGetậl4ˢᴰ> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T08PartOctal.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T08PartOctal.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T08PartOctal.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T08PartOctal.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -63,7 +63,7 @@ public class Base2Terminator {
|
|||
private List<T08PartOctal> base2ReadOctals(int...values) {
|
||||
List<T08PartOctal> octals = new ArrayList<>();
|
||||
for (int value:values) {
|
||||
T08PartOctal.forEach(v -> octals.add(T08PartOctal.indexOf(v, value)));
|
||||
T08PartOctal.PART_1.staticVoorElk(v -> octals.add(T08PartOctal.indexOf(v, value)));
|
||||
}
|
||||
return octals;
|
||||
}
|
||||
|
|
|
@ -1,11 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneName;
|
||||
|
@ -17,7 +11,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
@BassBoneName("T02PartBinary")
|
||||
public enum T02PartBinary implements BassBone {
|
||||
public enum T02PartBinary implements BassBone<T02PartBinary> {
|
||||
|
||||
PART_1("˧","0", "低", "low"),
|
||||
PART_2("꜔","1", "高", "high"),
|
||||
|
@ -25,34 +19,18 @@ public enum T02PartBinary implements BassBone {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T02PartBinary> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T02PartBinary> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T02PartBinary(String idTone, String idLetter, String chinaKey, String chinaValue) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T02PartBinary> consumer) {
|
||||
for (T02PartBinary value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T02PartBinary valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T02PartBinary valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,11 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneName;
|
||||
|
@ -17,7 +11,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
@BassBoneName("T03PartTrit")
|
||||
public enum T03PartTrit implements BassBone {
|
||||
public enum T03PartTrit implements BassBone<T03PartTrit> {
|
||||
|
||||
PART_1("˦","0","一","1"),
|
||||
PART_2("˧","1","二","2"),
|
||||
|
@ -26,34 +20,18 @@ public enum T03PartTrit implements BassBone {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T03PartTrit> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T03PartTrit> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T03PartTrit(String idTone, String idLetter, String chinaKey, String chinaValue) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T03PartTrit> consumer) {
|
||||
for (T03PartTrit value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T03PartTrit valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T03PartTrit valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,13 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BasePartSplit4;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -21,7 +13,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T04PartQuad")
|
||||
@BassBoneAlt1Info(name="Cardinal direction", website="https://simple.wikipedia.org/wiki/Cardinal_direction")
|
||||
public enum T04PartQuad implements BassBone,BassBoneAlt1,BasePartSplit4 {
|
||||
public enum T04PartQuad implements BassBoneAlt1<T04PartQuad> {
|
||||
|
||||
PART_1("˥","0","北","north","N"),
|
||||
PART_2("꜒","1","東","east", "E"),
|
||||
|
@ -31,17 +23,15 @@ public enum T04PartQuad implements BassBone,BassBoneAlt1,BasePartSplit4 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T04PartQuad> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T04PartQuad> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T04PartQuad(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -49,17 +39,7 @@ public enum T04PartQuad implements BassBone,BassBoneAlt1,BasePartSplit4 {
|
|||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T04PartQuad> consumer) {
|
||||
for (T04PartQuad value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T04PartQuad valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T04PartQuad valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
public T02PartBinary splitPartBinary(T02PartBinary part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2Info;
|
||||
|
@ -22,7 +15,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
@BassBoneName("T05PartPental")
|
||||
@BassBoneAlt1Info(name="Pentagram", website="https://en.wikipedia.org/wiki/Pentagram")
|
||||
@BassBoneAlt2Info(name="Pythagorean Interpretations", website="http://wisdomofhypatia.com/OM/BA/PP.html")
|
||||
public enum T05PartPental implements BassBone,BassBoneAlt2 {
|
||||
public enum T05PartPental implements BassBoneAlt2<T05PartPental> {
|
||||
|
||||
PART_1("˥","0","火","fire", "EI","heile"),
|
||||
PART_2("˦","1","水","water","U", "hudor"),
|
||||
|
@ -33,36 +26,20 @@ public enum T05PartPental implements BassBone,BassBoneAlt2 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T05PartPental> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T05PartPental> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T05PartPental(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value, String alt2Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T05PartPental> consumer) {
|
||||
for (T05PartPental value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T05PartPental valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T05PartPental valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,13 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BasePartSplit6;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -23,7 +15,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T06PartSeximal")
|
||||
@BassBoneAlt1Info(name="ADFGVX cipher", website="https://en.wikipedia.org/wiki/ADFGVX_cipher")
|
||||
public enum T06PartSeximal implements BassBone,BassBoneAlt1,BasePartSplit6 {
|
||||
public enum T06PartSeximal implements BassBoneAlt1<T06PartSeximal> {
|
||||
|
||||
PART_1("˦","0","四","4","A"),
|
||||
PART_2("˨","1","五","5","D"),
|
||||
|
@ -35,17 +27,15 @@ public enum T06PartSeximal implements BassBone,BassBoneAlt1,BasePartSplit6 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T06PartSeximal> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T06PartSeximal> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T06PartSeximal(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -53,17 +43,11 @@ public enum T06PartSeximal implements BassBone,BassBoneAlt1,BasePartSplit6 {
|
|||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T06PartSeximal> consumer) {
|
||||
for (T06PartSeximal value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
public T02PartBinary splitPartBinary() {
|
||||
return T02PartBinary.values()[ordinal() & 1];
|
||||
}
|
||||
|
||||
public static T06PartSeximal valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T06PartSeximal valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
public T03PartTrit splitPartTrit() {
|
||||
return T03PartTrit.values()[ordinal() >> 1];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -20,7 +13,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T07PartPlanIt")
|
||||
@BassBoneAlt1Info(name="Fallen sign", website="https://en.wikipedia.org/wiki/Classical_planet#Western_astrology")
|
||||
public enum T07PartPlanIt implements BassBone,BassBoneAlt1 {
|
||||
public enum T07PartPlanIt implements BassBoneAlt1<T07PartPlanIt> {
|
||||
|
||||
PART_1("˥","0","♎︎","libra","天秤座"),
|
||||
PART_2("꜉","1","♏︎","scorpio","天蠍座"),
|
||||
|
@ -33,35 +26,19 @@ public enum T07PartPlanIt implements BassBone,BassBoneAlt1 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T07PartPlanIt> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T07PartPlanIt> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T07PartPlanIt(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T07PartPlanIt> consumer) {
|
||||
for (T07PartPlanIt value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T07PartPlanIt valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T07PartPlanIt valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,13 +1,6 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BasePartSplit8;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneShiftBits;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2Info;
|
||||
|
@ -23,7 +16,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
@BassBoneName("T08PartOctal")
|
||||
@BassBoneAlt1Info(name="Absolute Tone Sequence", website="https://en.wikipedia.org/wiki/Tone_letter")
|
||||
@BassBoneAlt2Info(name="Relative Tone Sequence", website="https://en.wikipedia.org/wiki/Tone_letter")
|
||||
public enum T08PartOctal implements BassBone,BassBoneAlt2,BasePartSplit8 {
|
||||
public enum T08PartOctal implements BassBoneAlt2<T08PartOctal>,BassBoneShiftBits<T08PartOctal> {
|
||||
|
||||
PART_1("˥","0","心","heart","˧˥˩","˥˩˧", 0),
|
||||
PART_2("˩","1","頭","head", "˧˩˥","˩˥˧", 3),
|
||||
|
@ -39,19 +32,17 @@ public enum T08PartOctal implements BassBone,BassBoneAlt2,BasePartSplit8 {
|
|||
public static int BIT_COUNT = 3;
|
||||
private static final byte BITMASK = 0x07;
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T08PartOctal> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T08PartOctal> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T08PartOctal(String identifierTone, String identifierLetter, String chinaKey, String chinaValue, String alt1Value, String alt2Value, int shiftBits) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, identifierTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, identifierLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.SHIFT_BITS, Integer.valueOf(shiftBits));
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, identifierTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, identifierLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.SHIFT_BITS, Integer.valueOf(shiftBits));
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -63,17 +54,11 @@ public enum T08PartOctal implements BassBone,BassBoneAlt2,BasePartSplit8 {
|
|||
return T08PartOctal.values()[(value >> group.getShiftBits()) & BITMASK];
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T08PartOctal> consumer) {
|
||||
for (T08PartOctal value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
public T02PartBinary splitPartBinary(T03PartTrit part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
|
||||
public static T08PartOctal valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T08PartOctal valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
public int ordinalOf(T08PartOctal group) {
|
||||
return ordinal() << group.getShiftBits();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt3Info;
|
||||
|
@ -26,7 +19,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
@BassBoneAlt2Info(name="Burmese numerals", website="https://en.wikipedia.org/wiki/Burmese_numerals")
|
||||
@BassBoneAlt3Info(name="Bengali numerals", website="https://en.wikipedia.org/wiki/Bengali_numerals")
|
||||
@BassBoneAlt4Info(name="Sinhala Lith Illakkam", website="https://en.wikipedia.org/wiki/Sinhala_numerals#Numerals")
|
||||
public enum T10PartDecimal implements BassBone,BassBoneAlt4 {
|
||||
public enum T10PartDecimal implements BassBoneAlt4<T10PartDecimal> {
|
||||
|
||||
PART_1 ("˥","ō","零","zero", "영","\u1040","০", "෦"),
|
||||
PART_2 ("˦","α","壹","one", "일","\u1041","১", "෧"),
|
||||
|
@ -42,39 +35,23 @@ public enum T10PartDecimal implements BassBone,BassBoneAlt4 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T10PartDecimal> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T10PartDecimal> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T10PartDecimal(String idTone, String idLetter, String chinaKey, String chinaValue,
|
||||
String alt1Value, String alt2Value, String alt3Value, String alt4Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_3_VALUE, alt3Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_4_VALUE, alt4Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_3_VALUE, alt3Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_4_VALUE, alt4Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T10PartDecimal> consumer) {
|
||||
for (T10PartDecimal value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T10PartDecimal valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T10PartDecimal valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -20,7 +13,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T11PartUndecimal")
|
||||
@BassBoneAlt1Info(name="Tamil numerals", website="https://en.wikipedia.org/wiki/Tamil_numerals")
|
||||
public enum T11PartUndecimal implements BassBone,BassBoneAlt1 {
|
||||
public enum T11PartUndecimal implements BassBoneAlt1<T11PartUndecimal> {
|
||||
|
||||
PART_1 ("˥","0","走","walk", "௦"),
|
||||
PART_2 ("꜈","1","跑","run", "௧"),
|
||||
|
@ -37,35 +30,19 @@ public enum T11PartUndecimal implements BassBone,BassBoneAlt1 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T11PartUndecimal> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T11PartUndecimal> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T11PartUndecimal(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T11PartUndecimal> consumer) {
|
||||
for (T11PartUndecimal value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T11PartUndecimal valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T11PartUndecimal valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -20,7 +13,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T12PartUncial")
|
||||
@BassBoneAlt1Info(name="Transdecimal symbols", website="https://en.wikipedia.org/wiki/Duodecimal#Transdecimal_symbols")
|
||||
public enum T12PartUncial implements BassBone,BassBoneAlt1 {
|
||||
public enum T12PartUncial implements BassBoneAlt1<T12PartUncial> {
|
||||
|
||||
PART_1 ("˥","0","日","sun", "0"),
|
||||
PART_2 ("˧","1","月","moon", "1"),
|
||||
|
@ -38,35 +31,19 @@ public enum T12PartUncial implements BassBone,BassBoneAlt1 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T12PartUncial> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T12PartUncial> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T12PartUncial(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BassBoneCoffin getBBC() {
|
||||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T12PartUncial> consumer) {
|
||||
for (T12PartUncial value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T12PartUncial valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T12PartUncial valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,13 +1,5 @@
|
|||
package love.distributedrebirth.numberxd.base2t;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BasePartSplit16;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneCoffin;
|
||||
|
@ -21,7 +13,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
*/
|
||||
@BassBoneName("T16PartHex")
|
||||
@BassBoneAlt1Info(name="Dual-tone multi-frequency signaling", website="https://en.wikipedia.org/wiki/Dual-tone_multi-frequency_signaling")
|
||||
public enum T16PartHex implements BassBone,BassBoneAlt1,BasePartSplit16 {
|
||||
public enum T16PartHex implements BassBoneAlt1<T16PartHex> {
|
||||
|
||||
PART_1 ("˥","0","氫","hydrogen", "1"),
|
||||
PART_2 ("˦","1","氦","helium", "2"),
|
||||
|
@ -43,17 +35,15 @@ public enum T16PartHex implements BassBone,BassBoneAlt1,BasePartSplit16 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T16PartHex> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T16PartHex> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
|
||||
private T16PartHex(String idTone, String idLetter, String chinaKey, String chinaValue, String alt1Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -61,17 +51,7 @@ public enum T16PartHex implements BassBone,BassBoneAlt1,BasePartSplit16 {
|
|||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T16PartHex> consumer) {
|
||||
for (T16PartHex value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T16PartHex valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T16PartHex valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
public T02PartBinary splitPartBinary(T04PartQuad part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,10 +3,8 @@ package love.distributedrebirth.numberxd.base2t;
|
|||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBone;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt1Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt2Info;
|
||||
import love.distributedrebirth.numberxd.base2t.bone.BassBoneAlt3;
|
||||
|
@ -24,7 +22,7 @@ import love.distributedrebirth.numberxd.base2t.bone.BassBoneStoreKey;
|
|||
@BassBoneAlt1Info(name="Vigesimal", website="https://en.wikipedia.org/wiki/Vigesimal#Places")
|
||||
@BassBoneAlt2Info(name="Vigesimal Alternative", website="https://en.wikipedia.org/wiki/Vigesimal#Places")
|
||||
@BassBoneAlt3Info(name="Open Location Code", website="https://en.wikipedia.org/wiki/Open_Location_Code")
|
||||
public enum T20PartScore implements BassBone,BassBoneAlt3 {
|
||||
public enum T20PartScore implements BassBoneAlt3<T20PartScore> {
|
||||
|
||||
PART_1 ("˥","Y", "尧","yotta","0","0","2"),
|
||||
PART_2 ("˦","Z", "泽","zetta","1","1","3"),
|
||||
|
@ -50,22 +48,20 @@ public enum T20PartScore implements BassBone,BassBoneAlt3 {
|
|||
|
||||
public static int LENGTH() { return values().length; };
|
||||
private final BassBoneCoffin bbc = BassBoneCoffin.newInstance();
|
||||
private static final Map<String, T20PartScore> TONE_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
private static final Map<String, T20PartScore> CHINA_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
private static final Map<String, T20PartScore> OPENLC_MAP = Collections.unmodifiableMap(
|
||||
Arrays.asList(values()).stream().collect(Collectors.toMap(v -> v.getAlt3Value(), v -> v)));
|
||||
|
||||
private T20PartScore(String idTone, String idLetter, String chinaKey, String chinaValue,
|
||||
String alt1Value, String alt2Value, String alt3Value) {
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
this.getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
this.getBBC().putInit(BassBoneStoreKey.ALT_3_VALUE, alt3Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_TONE, idTone);
|
||||
getBBC().putInit(BassBoneStoreKey.ID_LETTER, idLetter);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_KEY, chinaKey);
|
||||
getBBC().putInit(BassBoneStoreKey.CHINA_VALUE, chinaValue);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_1_VALUE, alt1Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_2_VALUE, alt2Value);
|
||||
getBBC().putInit(BassBoneStoreKey.ALT_3_VALUE, alt3Value);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -73,21 +69,7 @@ public enum T20PartScore implements BassBone,BassBoneAlt3 {
|
|||
return bbc;
|
||||
}
|
||||
|
||||
public static void forEach(Consumer<T20PartScore> consumer) {
|
||||
for (T20PartScore value:values()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
|
||||
public static T20PartScore valueOfTone(String identifierTone) {
|
||||
return TONE_MAP.get(identifierTone);
|
||||
}
|
||||
|
||||
public static T20PartScore valueOfChina(String chinaKey) {
|
||||
return CHINA_MAP.get(chinaKey);
|
||||
}
|
||||
|
||||
public static T20PartScore valueOfOpenLC(String openLCKey) {
|
||||
public T20PartScore staticValueOfOpenLC(String openLCKey) {
|
||||
return OPENLC_MAP.get(openLCKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -43,6 +43,6 @@ public final class V006Tixte implements BaseNumber<V006Tixte> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@ public final class V009Tyte implements BaseNumberTyte<V009Tyte> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T03PartTrit.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T03PartTrit.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -51,11 +51,11 @@ public final class V012Tord implements BaseNumberTyte<V012Tord> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,11 +48,11 @@ public final class V01BTemvig implements BaseNumberTyte<V01BTemvig> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T03PartTrit.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T03PartTrit.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T03PartTrit.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T03PartTrit.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -57,11 +57,11 @@ public final class V024Teger implements BaseNumberTyte<V024Teger> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -42,6 +42,6 @@ public final class V02ATraw implements BaseNumber<V02ATraw> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T07PartPlanIt.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T07PartPlanIt.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -59,11 +59,11 @@ public final class V048Tong implements BaseNumberTyte<V048Tong> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -73,11 +73,11 @@ public final class V090Tocta implements BaseNumberTyte<V090Tocta> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -43,11 +43,11 @@ public class VCA8Tath implements BaseNumberTyte<VCA8Tath> {
|
|||
|
||||
@Override
|
||||
public void fillOctalsByClone(T08PartOctalBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillOctalsByClone(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillOctalsByClone(appender));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fillTytesByReference(V009TyteBaseAppender appender) {
|
||||
T02PartBinary.forEach(v -> getValue(v).fillTytesByReference(appender));
|
||||
T02PartBinary.PART_1.staticVoorElk(v -> getValue(v).fillTytesByReference(appender));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,16 +0,0 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.T02PartBinary;
|
||||
import love.distributedrebirth.numberxd.base2t.T04PartQuad;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BasePartSplit16 extends BassBone {
|
||||
|
||||
default T02PartBinary splitPartBinary(T04PartQuad part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
}
|
|
@ -1,15 +0,0 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.T02PartBinary;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BasePartSplit4 extends BassBone {
|
||||
|
||||
default T02PartBinary splitPartBinary(T02PartBinary part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.T02PartBinary;
|
||||
import love.distributedrebirth.numberxd.base2t.T03PartTrit;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BasePartSplit6 extends BassBone {
|
||||
|
||||
default T02PartBinary splitPartBinary() {
|
||||
return T02PartBinary.values()[ordinal() & 1];
|
||||
}
|
||||
|
||||
default T03PartTrit splitPartTrit() {
|
||||
return T03PartTrit.values()[ordinal() >> 1];
|
||||
}
|
||||
}
|
|
@ -1,21 +0,0 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import love.distributedrebirth.numberxd.base2t.T02PartBinary;
|
||||
import love.distributedrebirth.numberxd.base2t.T03PartTrit;
|
||||
import love.distributedrebirth.numberxd.base2t.T08PartOctal;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BasePartSplit8 extends BasePartShiftBits {
|
||||
|
||||
default T02PartBinary splitPartBinary(T03PartTrit part) {
|
||||
return T02PartBinary.values()[(ordinal() >> part.ordinal()) & 1];
|
||||
}
|
||||
|
||||
default int ordinalOf(T08PartOctal group) {
|
||||
return ordinal() << group.getShiftBits();
|
||||
}
|
||||
}
|
|
@ -1,17 +1,16 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBone extends BassBoneStore {
|
||||
public interface BassBone<T extends BassBone<T>> extends BassBoneEnum<T>, BassBoneStore {
|
||||
|
||||
String name();
|
||||
|
||||
int ordinal();
|
||||
|
||||
default String staticBoneName() {
|
||||
default String staticBoneNaam() {
|
||||
return getClass().getAnnotation(BassBoneName.class).value();
|
||||
}
|
||||
|
||||
|
@ -30,4 +29,22 @@ public interface BassBone extends BassBoneStore {
|
|||
default String getChinaValue() {
|
||||
return getBBC().getString(BassBoneStoreKey.CHINA_VALUE);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
default T staticValueOfTone(String identifierTone) {
|
||||
Map<String,Object> mapTone = getBBC().getMapObject(BassBoneStoreKey.MAP_TONE);
|
||||
if (mapTone.isEmpty()) {
|
||||
mapTone.putAll(staticInstancesStream().collect(Collectors.toMap(v -> v.getIdentifierTone(), v -> v)));
|
||||
}
|
||||
return (T) mapTone.get(identifierTone);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
default T staticValueOfChina(String chinaKey) {
|
||||
Map<String,Object> mapChina = getBBC().getMapObject(BassBoneStoreKey.MAP_CHINA);
|
||||
if (mapChina.isEmpty()) {
|
||||
mapChina.putAll(staticInstancesStream().collect(Collectors.toMap(v -> v.getChinaKey(), v -> v)));
|
||||
}
|
||||
return (T) mapChina.get(chinaKey);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@ package love.distributedrebirth.numberxd.base2t.bone;
|
|||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBoneAlt1 extends BassBone {
|
||||
public interface BassBoneAlt1<T extends BassBone<T>> extends BassBone<T> {
|
||||
|
||||
default String getAlt1Value() {
|
||||
return getBBC().getString(BassBoneStoreKey.ALT_1_VALUE);
|
||||
|
|
|
@ -5,7 +5,7 @@ package love.distributedrebirth.numberxd.base2t.bone;
|
|||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBoneAlt2 extends BassBoneAlt1 {
|
||||
public interface BassBoneAlt2<T extends BassBone<T>> extends BassBoneAlt1<T> {
|
||||
|
||||
default String getAlt2Value() {
|
||||
return getBBC().getString(BassBoneStoreKey.ALT_2_VALUE);
|
||||
|
|
|
@ -5,7 +5,7 @@ package love.distributedrebirth.numberxd.base2t.bone;
|
|||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBoneAlt3 extends BassBoneAlt2 {
|
||||
public interface BassBoneAlt3<T extends BassBone<T>> extends BassBoneAlt2<T> {
|
||||
|
||||
default String getAlt3Value() {
|
||||
return getBBC().getString(BassBoneStoreKey.ALT_3_VALUE);
|
||||
|
|
|
@ -5,7 +5,7 @@ package love.distributedrebirth.numberxd.base2t.bone;
|
|||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBoneAlt4 extends BassBoneAlt3 {
|
||||
public interface BassBoneAlt4<T extends BassBone<T>> extends BassBoneAlt3<T> {
|
||||
|
||||
default String getAlt4Value() {
|
||||
return getBBC().getString(BassBoneStoreKey.ALT_4_VALUE);
|
||||
|
|
|
@ -25,6 +25,22 @@ public interface BassBoneCoffin {
|
|||
return Boolean.class.cast(get(key));
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
default Map<String,Object> getMapObject(BassBoneStoreKey key) {
|
||||
if (get(key) == null) {
|
||||
putInit(key, new HashMap<>());
|
||||
}
|
||||
return Map.class.cast(get(key));
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
default Map<String,String> getMapString(BassBoneStoreKey key) {
|
||||
if (get(key) == null) {
|
||||
putInit(key, new HashMap<>());
|
||||
}
|
||||
return Map.class.cast(get(key));
|
||||
}
|
||||
|
||||
static BassBoneCoffin newInstance() {
|
||||
return new BassBoneCoffin() {
|
||||
final Map<BassBoneStoreKey,Object> initMap = new HashMap<>();
|
||||
|
|
|
@ -0,0 +1,81 @@
|
|||
package love.distributedrebirth.numberxd.base2t.bone;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.function.Consumer;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BassBoneEnum<T> {
|
||||
|
||||
int ordinal();
|
||||
|
||||
String name();
|
||||
|
||||
default String naam() {
|
||||
return name(); // Deutsche code
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
default T[] staticInstances() {
|
||||
try {
|
||||
Object result = getClass().getMethod("values").invoke(null);
|
||||
return (T[]) result;
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
default List<T> staticInstancesList() {
|
||||
return Arrays.asList(staticInstances());
|
||||
}
|
||||
|
||||
default Iterator<T> staticInstancesIterator() {
|
||||
return staticInstancesList().iterator();
|
||||
}
|
||||
|
||||
default Stream<T> staticInstancesStream() {
|
||||
return staticInstancesList().stream();
|
||||
}
|
||||
|
||||
default T volgende() {
|
||||
T[] values = staticInstances();
|
||||
int resultIndex = 0;
|
||||
for (int i=0;i<values.length;i++) {
|
||||
if (this == values[i]) {
|
||||
resultIndex = i + 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (resultIndex == values.length) {
|
||||
resultIndex = 0;
|
||||
}
|
||||
return values[resultIndex];
|
||||
}
|
||||
|
||||
default T vorige() {
|
||||
T[] values = staticInstances();
|
||||
int resultIndex = 0;
|
||||
for (int i=0;i<values.length;i++) {
|
||||
if (this == values[i]) {
|
||||
resultIndex = i - 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (resultIndex < 0) {
|
||||
resultIndex = values.length - 1;
|
||||
}
|
||||
return values[resultIndex];
|
||||
}
|
||||
|
||||
default void staticVoorElk(Consumer<T> consumer) {
|
||||
for (T value:staticInstances()) {
|
||||
consumer.accept(value);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -5,7 +5,7 @@ package love.distributedrebirth.numberxd.base2t.bone;
|
|||
*
|
||||
* @author willemtsade ©Δ∞ 仙上主天
|
||||
*/
|
||||
public interface BasePartShiftBits extends BassBone {
|
||||
public interface BassBoneShiftBits<T extends BassBone<T>> extends BassBone<T> {
|
||||
|
||||
default Integer getShiftBits() {
|
||||
return getBBC().getInteger(BassBoneStoreKey.SHIFT_BITS);
|
|
@ -13,6 +13,9 @@ public enum BassBoneStoreKey {
|
|||
CHINA_VALUE,
|
||||
SHIFT_BITS,
|
||||
|
||||
MAP_TONE,
|
||||
MAP_CHINA,
|
||||
|
||||
ALT_1_VALUE,
|
||||
ALT_2_VALUE,
|
||||
ALT_3_VALUE,
|
||||
|
|
|
@ -22,13 +22,13 @@ public class T02PartBinaryTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T02PartBinary.PART_1, T02PartBinary.valueOfTone("˧"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_2, T02PartBinary.valueOfTone("꜔"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_1, T02PartBinary.PART_1.staticValueOfTone("˧"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_2, T02PartBinary.PART_1.staticValueOfTone("꜔"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T02PartBinary.PART_1, T02PartBinary.valueOfChina("低"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_2, T02PartBinary.valueOfChina("高"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_1, T02PartBinary.PART_1.staticValueOfChina("低"));
|
||||
Assertions.assertEquals(T02PartBinary.PART_2, T02PartBinary.PART_1.staticValueOfChina("高"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,15 +22,15 @@ public class T03PartTritTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T03PartTrit.PART_1, T03PartTrit.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_2, T03PartTrit.valueOfTone("˧"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_3, T03PartTrit.valueOfTone("˨"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_1, T03PartTrit.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_2, T03PartTrit.PART_1.staticValueOfTone("˧"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_3, T03PartTrit.PART_1.staticValueOfTone("˨"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T03PartTrit.PART_1, T03PartTrit.valueOfChina("一"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_2, T03PartTrit.valueOfChina("二"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_3, T03PartTrit.valueOfChina("三"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_1, T03PartTrit.PART_1.staticValueOfChina("一"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_2, T03PartTrit.PART_1.staticValueOfChina("二"));
|
||||
Assertions.assertEquals(T03PartTrit.PART_3, T03PartTrit.PART_1.staticValueOfChina("三"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,19 +23,35 @@ public class T04PartQuadTest {
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testVolgende() {
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.PART_4.volgende());
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.PART_1.volgende());
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.PART_2.volgende());
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.PART_3.volgende());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testVorige() {
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.PART_2.vorige());
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.PART_3.vorige());
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.PART_4.vorige());
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.PART_1.vorige());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.valueOfTone("꜒"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.valueOfTone("꜖"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.valueOfTone("˩"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.PART_1.staticValueOfTone("꜒"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.PART_1.staticValueOfTone("꜖"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.PART_1.staticValueOfTone("˩"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.valueOfChina("北"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.valueOfChina("東"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.valueOfChina("西"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.valueOfChina("南"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_1, T04PartQuad.PART_1.staticValueOfChina("北"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_2, T04PartQuad.PART_1.staticValueOfChina("東"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_3, T04PartQuad.PART_1.staticValueOfChina("西"));
|
||||
Assertions.assertEquals(T04PartQuad.PART_4, T04PartQuad.PART_1.staticValueOfChina("南"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,19 +22,19 @@ public class T05PartPentalTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T05PartPental.PART_1, T05PartPental.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T05PartPental.PART_2, T05PartPental.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T05PartPental.PART_3, T05PartPental.valueOfTone("˧"));
|
||||
Assertions.assertEquals(T05PartPental.PART_4, T05PartPental.valueOfTone("˨"));
|
||||
Assertions.assertEquals(T05PartPental.PART_5, T05PartPental.valueOfTone("˩"));
|
||||
Assertions.assertEquals(T05PartPental.PART_1, T05PartPental.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T05PartPental.PART_2, T05PartPental.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T05PartPental.PART_3, T05PartPental.PART_1.staticValueOfTone("˧"));
|
||||
Assertions.assertEquals(T05PartPental.PART_4, T05PartPental.PART_1.staticValueOfTone("˨"));
|
||||
Assertions.assertEquals(T05PartPental.PART_5, T05PartPental.PART_1.staticValueOfTone("˩"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T05PartPental.PART_1, T05PartPental.valueOfChina("火"));
|
||||
Assertions.assertEquals(T05PartPental.PART_2, T05PartPental.valueOfChina("水"));
|
||||
Assertions.assertEquals(T05PartPental.PART_3, T05PartPental.valueOfChina("木"));
|
||||
Assertions.assertEquals(T05PartPental.PART_4, T05PartPental.valueOfChina("金"));
|
||||
Assertions.assertEquals(T05PartPental.PART_5, T05PartPental.valueOfChina("土"));
|
||||
Assertions.assertEquals(T05PartPental.PART_1, T05PartPental.PART_1.staticValueOfChina("火"));
|
||||
Assertions.assertEquals(T05PartPental.PART_2, T05PartPental.PART_1.staticValueOfChina("水"));
|
||||
Assertions.assertEquals(T05PartPental.PART_3, T05PartPental.PART_1.staticValueOfChina("木"));
|
||||
Assertions.assertEquals(T05PartPental.PART_4, T05PartPental.PART_1.staticValueOfChina("金"));
|
||||
Assertions.assertEquals(T05PartPental.PART_5, T05PartPental.PART_1.staticValueOfChina("土"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,17 +25,17 @@ public class T06PartSeximalTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T06PartSeximal.PART_1, T06PartSeximal.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_2, T06PartSeximal.valueOfTone("˨"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_5, T06PartSeximal.valueOfTone("꜊"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_6, T06PartSeximal.valueOfTone("꜏"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_1, T06PartSeximal.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_2, T06PartSeximal.PART_1.staticValueOfTone("˨"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_5, T06PartSeximal.PART_1.staticValueOfTone("꜊"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_6, T06PartSeximal.PART_1.staticValueOfTone("꜏"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T06PartSeximal.PART_1, T06PartSeximal.valueOfChina("四"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_2, T06PartSeximal.valueOfChina("五"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_5, T06PartSeximal.valueOfChina("八"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_6, T06PartSeximal.valueOfChina("九"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_1, T06PartSeximal.PART_1.staticValueOfChina("四"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_2, T06PartSeximal.PART_1.staticValueOfChina("五"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_5, T06PartSeximal.PART_1.staticValueOfChina("八"));
|
||||
Assertions.assertEquals(T06PartSeximal.PART_6, T06PartSeximal.PART_1.staticValueOfChina("九"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,17 +25,17 @@ public class T07PartPlanItTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_1, T07PartPlanIt.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_2, T07PartPlanIt.valueOfTone("꜉"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_6, T07PartPlanIt.valueOfTone("꜐"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_7, T07PartPlanIt.valueOfTone("˩"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_1, T07PartPlanIt.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_2, T07PartPlanIt.PART_1.staticValueOfTone("꜉"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_6, T07PartPlanIt.PART_1.staticValueOfTone("꜐"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_7, T07PartPlanIt.PART_1.staticValueOfTone("˩"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_1, T07PartPlanIt.valueOfChina("♎︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_2, T07PartPlanIt.valueOfChina("♏︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_6, T07PartPlanIt.valueOfChina("♑︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_7, T07PartPlanIt.valueOfChina("♈︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_1, T07PartPlanIt.PART_1.staticValueOfChina("♎︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_2, T07PartPlanIt.PART_1.staticValueOfChina("♏︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_6, T07PartPlanIt.PART_1.staticValueOfChina("♑︎"));
|
||||
Assertions.assertEquals(T07PartPlanIt.PART_7, T07PartPlanIt.PART_1.staticValueOfChina("♈︎"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,17 +28,17 @@ public class T08PartOctalTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T08PartOctal.PART_1, T08PartOctal.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_2, T08PartOctal.valueOfTone("˩"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_7, T08PartOctal.valueOfTone("꜍"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_8, T08PartOctal.valueOfTone("꜑"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_1, T08PartOctal.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_2, T08PartOctal.PART_1.staticValueOfTone("˩"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_7, T08PartOctal.PART_1.staticValueOfTone("꜍"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_8, T08PartOctal.PART_1.staticValueOfTone("꜑"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T08PartOctal.PART_1, T08PartOctal.valueOfChina("心"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_2, T08PartOctal.valueOfChina("頭"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_7, T08PartOctal.valueOfChina("肢"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_8, T08PartOctal.valueOfChina("腳"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_1, T08PartOctal.PART_1.staticValueOfChina("心"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_2, T08PartOctal.PART_1.staticValueOfChina("頭"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_7, T08PartOctal.PART_1.staticValueOfChina("肢"));
|
||||
Assertions.assertEquals(T08PartOctal.PART_8, T08PartOctal.PART_1.staticValueOfChina("腳"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,17 +22,17 @@ public class T10PartDecimalTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T10PartDecimal.PART_1, T10PartDecimal.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_2, T10PartDecimal.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_9, T10PartDecimal.valueOfTone("꜕"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_10, T10PartDecimal.valueOfTone("꜖"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_1, T10PartDecimal.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_2, T10PartDecimal.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_9, T10PartDecimal.PART_1.staticValueOfTone("꜕"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_10, T10PartDecimal.PART_1.staticValueOfTone("꜖"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T10PartDecimal.PART_1, T10PartDecimal.valueOfChina("零"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_2, T10PartDecimal.valueOfChina("壹"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_9, T10PartDecimal.valueOfChina("捌"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_10, T10PartDecimal.valueOfChina("玖"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_1, T10PartDecimal.PART_1.staticValueOfChina("零"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_2, T10PartDecimal.PART_1.staticValueOfChina("壹"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_9, T10PartDecimal.PART_1.staticValueOfChina("捌"));
|
||||
Assertions.assertEquals(T10PartDecimal.PART_10, T10PartDecimal.PART_1.staticValueOfChina("玖"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,17 +22,17 @@ public class T11PartUndecimalTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_1, T11PartUndecimal.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_2, T11PartUndecimal.valueOfTone("꜈"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_10, T11PartUndecimal.valueOfTone("꜐"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_11, T11PartUndecimal.valueOfTone("˩"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_1, T11PartUndecimal.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_2, T11PartUndecimal.PART_1.staticValueOfTone("꜈"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_10, T11PartUndecimal.PART_1.staticValueOfTone("꜐"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_11, T11PartUndecimal.PART_1.staticValueOfTone("˩"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_1, T11PartUndecimal.valueOfChina("走"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_2, T11PartUndecimal.valueOfChina("跑"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_10, T11PartUndecimal.valueOfChina("春"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_11, T11PartUndecimal.valueOfChina("耦"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_1, T11PartUndecimal.PART_1.staticValueOfChina("走"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_2, T11PartUndecimal.PART_1.staticValueOfChina("跑"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_10, T11PartUndecimal.PART_1.staticValueOfChina("春"));
|
||||
Assertions.assertEquals(T11PartUndecimal.PART_11, T11PartUndecimal.PART_1.staticValueOfChina("耦"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,17 +25,17 @@ public class T12PartUncialTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T12PartUncial.PART_1, T12PartUncial.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_2, T12PartUncial.valueOfTone("˧"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_11, T12PartUncial.valueOfTone("꜏"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_12, T12PartUncial.valueOfTone("꜑"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_1, T12PartUncial.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_2, T12PartUncial.PART_1.staticValueOfTone("˧"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_11, T12PartUncial.PART_1.staticValueOfTone("꜏"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_12, T12PartUncial.PART_1.staticValueOfTone("꜑"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T12PartUncial.PART_1, T12PartUncial.valueOfChina("日"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_2, T12PartUncial.valueOfChina("月"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_11, T12PartUncial.valueOfChina("黼"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_12, T12PartUncial.valueOfChina("亞"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_1, T12PartUncial.PART_1.staticValueOfChina("日"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_2, T12PartUncial.PART_1.staticValueOfChina("月"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_11, T12PartUncial.PART_1.staticValueOfChina("黼"));
|
||||
Assertions.assertEquals(T12PartUncial.PART_12, T12PartUncial.PART_1.staticValueOfChina("亞"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,17 +25,17 @@ public class T16PartHexTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T16PartHex.PART_1, T16PartHex.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T16PartHex.PART_2, T16PartHex.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T16PartHex.PART_15, T16PartHex.valueOfTone("꜐"));
|
||||
Assertions.assertEquals(T16PartHex.PART_16, T16PartHex.valueOfTone("꜑"));
|
||||
Assertions.assertEquals(T16PartHex.PART_1, T16PartHex.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T16PartHex.PART_2, T16PartHex.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T16PartHex.PART_15, T16PartHex.PART_1.staticValueOfTone("꜐"));
|
||||
Assertions.assertEquals(T16PartHex.PART_16, T16PartHex.PART_1.staticValueOfTone("꜑"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T16PartHex.PART_1, T16PartHex.valueOfChina("氫"));
|
||||
Assertions.assertEquals(T16PartHex.PART_2, T16PartHex.valueOfChina("氦"));
|
||||
Assertions.assertEquals(T16PartHex.PART_15, T16PartHex.valueOfChina("磷"));
|
||||
Assertions.assertEquals(T16PartHex.PART_16, T16PartHex.valueOfChina("硫"));
|
||||
Assertions.assertEquals(T16PartHex.PART_1, T16PartHex.PART_1.staticValueOfChina("氫"));
|
||||
Assertions.assertEquals(T16PartHex.PART_2, T16PartHex.PART_1.staticValueOfChina("氦"));
|
||||
Assertions.assertEquals(T16PartHex.PART_15, T16PartHex.PART_1.staticValueOfChina("磷"));
|
||||
Assertions.assertEquals(T16PartHex.PART_16, T16PartHex.PART_1.staticValueOfChina("硫"));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,25 +25,25 @@ public class T20PartScoreTest {
|
|||
|
||||
@Test
|
||||
public void testToneMap() {
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.valueOfTone("˥"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.valueOfTone("˦"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.valueOfTone("꜐"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.valueOfTone("꜑"));
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.PART_1.staticValueOfTone("˥"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.PART_1.staticValueOfTone("˦"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.PART_1.staticValueOfTone("꜐"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.PART_1.staticValueOfTone("꜑"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testChinaMap() {
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.valueOfChina("尧"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.valueOfChina("泽"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.valueOfChina("仄"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.valueOfChina("幺"));
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.PART_1.staticValueOfChina("尧"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.PART_1.staticValueOfChina("泽"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.PART_1.staticValueOfChina("仄"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.PART_1.staticValueOfChina("幺"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testOpenLCMap() {
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.valueOfOpenLC("2"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.valueOfOpenLC("3"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.valueOfOpenLC("W"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.valueOfOpenLC("X"));
|
||||
Assertions.assertEquals(T20PartScore.PART_1, T20PartScore.PART_1.staticValueOfOpenLC("2"));
|
||||
Assertions.assertEquals(T20PartScore.PART_2, T20PartScore.PART_1.staticValueOfOpenLC("3"));
|
||||
Assertions.assertEquals(T20PartScore.PART_19, T20PartScore.PART_1.staticValueOfOpenLC("W"));
|
||||
Assertions.assertEquals(T20PartScore.PART_20, T20PartScore.PART_1.staticValueOfOpenLC("X"));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue