diff --git a/core/src/love/distributedrebirth/demo4d/screen/HebrewWalletRenderer.java b/core/src/love/distributedrebirth/demo4d/screen/HebrewWalletRenderer.java index d6329b0a..992e828a 100644 --- a/core/src/love/distributedrebirth/demo4d/screen/HebrewWalletRenderer.java +++ b/core/src/love/distributedrebirth/demo4d/screen/HebrewWalletRenderer.java @@ -46,7 +46,7 @@ public class HebrewWalletRenderer extends ImGuiRendererMain { }; for (String data:walletData) { Gê̄ldGetậl geld = new Gê̄ldGetậl(data); - Gê̄ldGetậl geld2 = geld.toClone(); // unit test + Gê̄ldGetậl geld2 = new Gê̄ldGetậl(geld.toTeger().toClone().toClone()); // unit test ImGui.tableNextRow(); ImGui.tableNextColumn(); ImGui.text(data.length()==2||data.length()==3?"OUT":"IN"); diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel0.java b/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel0.java deleted file mode 100644 index 5567999a..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel0.java +++ /dev/null @@ -1,20 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -abstract public class AbstractBaseGetậlLevel0,V extends BaseNumber> implements BaseGetậlLevel0 { - - protected int valueIndex0; - - @Override - public void setValueIndex0(int valueIndex0) { - this.valueIndex0 = valueIndex0; - } - - @Override - public int getValueIndex0() { - return valueIndex0; - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel1.java b/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel1.java deleted file mode 100644 index 65b05751..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel1.java +++ /dev/null @@ -1,20 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -abstract public class AbstractBaseGetậlLevel1,V extends BaseNumber> extends AbstractBaseGetậlLevel0 implements BaseGetậlLevel1 { - - protected int valueIndex1; - - @Override - public void setValueIndex1(int valueIndex1) { - this.valueIndex1 = valueIndex1; - } - - @Override - public int getValueIndex1() { - return valueIndex1; - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel2.java b/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel2.java deleted file mode 100644 index 5312d81d..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractBaseGetậlLevel2.java +++ /dev/null @@ -1,20 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -abstract public class AbstractBaseGetậlLevel2,V extends BaseNumber> extends AbstractBaseGetậlLevel1 implements BaseGetậlLevel2 { - - protected int valueIndex2; - - @Override - public void setValueIndex2(int valueIndex1) { - this.valueIndex1 = valueIndex1; - } - - @Override - public int getValueIndex2() { - return valueIndex1; - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractGroßGetậlŌṁ1ⁿᴰ.java b/numberxd/src/main/love/distributedrebirth/numberxd/AbstractGroßGetậlŌṁ1ⁿᴰ.java deleted file mode 100644 index 36682787..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/AbstractGroßGetậlŌṁ1ⁿᴰ.java +++ /dev/null @@ -1,53 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.numberxd.base2t.BaseIteratorOctal; -import love.distributedrebirth.numberxd.base2t.part.T16PartHex; -import love.distributedrebirth.numberxd.base2t.type.V009Tyte; -import love.distributedrebirth.numberxd.base2t.type.V144Tocta; -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -abstract public class AbstractGroßGetậlŌṁ1ⁿᴰ> extends AbstractBaseGetậlLevel1 { - - private V144Tocta[] values; - private int valuesLength; - private byte fractalLevel; - - public AbstractGroßGetậlŌṁ1ⁿᴰ(byte fractalLevel) { - this.fractalLevel = fractalLevel; - this.valuesLength = resolveFractalLevel(fractalLevel); - this.values = new V144Tocta[valuesLength]; - for (int i=0;i> extends AbstractBaseGetậlLevel2 { - - private V144Tocta[][] values; - private int valuesLength; - private byte fractalLevel; - - public AbstractGroßGetậlŌṁ6ˢᴰ(byte fractalLevel) { - this.fractalLevel = fractalLevel; - this.valuesLength = resolveFractalLevel(fractalLevel); - this.values = new V144Tocta[T12PartUncial.LENGTH()][valuesLength]; - for (int x=0;x> extends BaseNumberTyte { -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseGetậl,V extends BaseNumber> { - V getValue(); - - T toClone(); } diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel0.java b/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel0.java deleted file mode 100644 index 5f35b12c..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel0.java +++ /dev/null @@ -1,14 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseGetậlLevel0,V extends BaseNumber> extends BaseGetậl { - - void setValueIndex0(int valueIndex0); - - int getValueIndex0(); - - int getValueIndex0Length(); -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel1.java b/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel1.java deleted file mode 100644 index b0c2e460..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel1.java +++ /dev/null @@ -1,14 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseGetậlLevel1,V extends BaseNumber> extends BaseGetậlLevel0 { - - void setValueIndex1(int valueIndex1); - - int getValueIndex1(); - - int getValueIndex1Length(); -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel2.java b/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel2.java deleted file mode 100644 index a19f05a5..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel2.java +++ /dev/null @@ -1,14 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseGetậlLevel2,V extends BaseNumber> extends BaseGetậlLevel1 { - - void setValueIndex2(int valueIndex1); - - int getValueIndex2(); - - int getValueIndex2Length(); -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel3.java b/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel3.java deleted file mode 100644 index bf4ff190..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/BaseGetậlLevel3.java +++ /dev/null @@ -1,14 +0,0 @@ -package love.distributedrebirth.numberxd; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.BaseNumber; - -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseGetậlLevel3,V extends BaseNumber> extends BaseGetậlLevel2 { - - void setValueIndex3(int valueIndex1); - - int getValueIndex3(); - - int getValueIndex3Length(); -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậl1ⁿᴰ.java b/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậl1ⁿᴰ.java index 3e1e7cd0..24d06751 100644 --- a/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậl1ⁿᴰ.java +++ b/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậl1ⁿᴰ.java @@ -1,53 +1,101 @@ package love.distributedrebirth.numberxd; -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; +import java.util.ArrayList; +import java.util.List; + +import love.distributedrebirth.numberxd.base2t.BaseAppenderOctal; import love.distributedrebirth.numberxd.base2t.BaseIteratorOctal; +import love.distributedrebirth.numberxd.base2t.BaseAppenderTyte; import love.distributedrebirth.numberxd.base2t.BaseIteratorTyte; -import love.distributedrebirth.numberxd.base2t.part.T16PartHex; import love.distributedrebirth.numberxd.base2t.type.V009Tyte; import love.distributedrebirth.numberxd.base2t.type.V144Tocta; /** * Holds an 144 bit fraction. + * + * @author willemtsade ©Δ∞ 仙上主天 */ -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public class GroßGetậl1ⁿᴰ extends AbstractBaseGetậlLevel0 { +public class GroßGetậl1ⁿᴰ implements BaseGetậl { - //public static int NUMERATOR_SIZE = 7; - //public static int DENOMINATOR_SIZE = 9; - //public static int BIT_COUNT = V144Tocta.BIT_COUNT; - //private final V009Tyte[] numerator = new V009Tyte[NUMERATOR_SIZE]; - //private final V009Tyte[] denominator = new V009Tyte[DENOMINATOR_SIZE]; - private final V144Tocta value; + public static int NUMERATOR_SIZE = 7; + public static int DENOMINATOR_SIZE = 9; + public static int BIT_COUNT = V144Tocta.BIT_COUNT; + private final V009Tyte[] numerator = new V009Tyte[NUMERATOR_SIZE]; + private final V009Tyte[] denominator = new V009Tyte[DENOMINATOR_SIZE]; public GroßGetậl1ⁿᴰ() { - this(new V144Tocta()); + for (int i=0;i tytes = new ArrayList<>(); + tocta.fillTytesByReference(new BaseAppenderTyte(tytes)); + for (int i=0;i { +public class GroßGetậl6ˢᴰ implements BaseNumberTyte { - private final V144Tocta[] values = new V144Tocta[T12PartUncial.LENGTH()]; + public static int BIT_COUNT = GroßGetậl1ⁿᴰ.BIT_COUNT * T12PartUncial.LENGTH(); + private GroßGetậl1ⁿᴰ[] values = new GroßGetậl1ⁿᴰ[T12PartUncial.LENGTH()]; public GroßGetậl6ˢᴰ() { for (int i=0;i getValue(v).fillOctalsByClone(appender)); + } + + @Override + public void fillTytesByReference(BaseAppenderTyte appender) { + T12PartUncial.PART_1.BãßVoorElk(v -> getValue(v).fillTytesByReference(appender)); } } diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậlŌṁ1ⁿᴰ.java b/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậlŌṁ1ⁿᴰ.java new file mode 100644 index 00000000..13545e37 --- /dev/null +++ b/numberxd/src/main/love/distributedrebirth/numberxd/GroßGetậlŌṁ1ⁿᴰ.java @@ -0,0 +1,75 @@ +package love.distributedrebirth.numberxd; + +import love.distributedrebirth.numberxd.base2t.BaseNumber; +import love.distributedrebirth.numberxd.base2t.BaseAppenderOctal; +import love.distributedrebirth.numberxd.base2t.BaseIteratorOctal; + +/** + * Divide GroßGetậl1ⁿᴰ into resolved fractal slices. + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +abstract public class GroßGetậlŌṁ1ⁿᴰ & BaseNumber> implements BaseNumber { + + private GroßGetậl1ⁿᴰ[] values; + private int valuesLength; + private byte fractalLevel; + + public GroßGetậlŌṁ1ⁿᴰ(byte fractalLevel) { + this.fractalLevel = fractalLevel; + this.valuesLength = resolveFractalLevel(fractalLevel); + this.values = new GroßGetậl1ⁿᴰ[valuesLength]; + } + + abstract protected int resolveFractalLevel(byte level); + + public final byte getFractalLevel() { + return fractalLevel; + } + + public final int getValuesLength() { + return valuesLength; + } + + private final int validatePartRequest(int part) { + if (part < 0) { + throw new IllegalArgumentException("Requested part is negative"); + } + if (part > valuesLength) { + throw new IllegalArgumentException("Requested part exceeds fractal storage"); + } + return part; + } + + public final GroßGetậl1ⁿᴰ getValue(int part) { + return values[validatePartRequest(part)]; + } + + public final void setValue(int part, GroßGetậl1ⁿᴰ value) { + values[validatePartRequest(part)] = value; + } + + abstract protected V toCloneFractal(byte level); + + @Override + public final V toClone() { + V result = toCloneFractal(getFractalLevel()); + BaseIteratorOctal clonedOctals = iteratorOctalsByClone(); + for (int i=0;i & BaseNumber> implements BaseNumber { + + private GroßGetậl6ˢᴰ[] values; + private int valuesLength; + private byte fractalLevel; + + public GroßGetậlŌṁ6ˢᴰ(byte fractalLevel) { + this.fractalLevel = fractalLevel; + this.valuesLength = resolveFractalLevel(fractalLevel); + this.values = new GroßGetậl6ˢᴰ[valuesLength]; + } + + abstract protected int resolveFractalLevel(byte level); + + public final byte getFractalLevel() { + return fractalLevel; + } + + public final int getValuesLength() { + return valuesLength; + } + + private final int validatePartRequest(int part) { + if (part < 0) { + throw new IllegalArgumentException("Requested part is negative"); + } + if (part > valuesLength) { + throw new IllegalArgumentException("Requested part exceeds fractal storage"); + } + return part; + } + + public final GroßGetậl6ˢᴰ getValue(int part) { + return values[validatePartRequest(part)]; + } + + public final void setValue(int part, GroßGetậl6ˢᴰ value) { + values[validatePartRequest(part)] = value; + } + + abstract protected V toCloneFractal(byte level); + + @Override + public final V toClone() { + V result = toCloneFractal(getFractalLevel()); + BaseIteratorOctal clonedOctals = iteratorOctalsByClone(); + for (int i=0;i { +/** + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class GroßGetậlŌṁDiamond1ⁿᴰ extends GroßGetậlŌṁ1ⁿᴰ { // 0th = 1 * V144Tocta (1) // 1th = 1+3 * V144Tocta (4) @@ -17,25 +16,13 @@ public class GroßGetậlŌṁDiamond1ⁿᴰ extends AbstractGroßGetậlŌṁ1 super(level); } - public GroßGetậlŌṁDiamond1ⁿᴰ(byte level, BaseIteratorOctal values) { - super(level, values); - } - protected int resolveFractalLevel(byte level) { // TODO return level; } @Override - public GroßGetậlŌṁDiamond1ⁿᴰ toClone() { - BaseIteratorOctalStack cloneStack = new BaseIteratorOctalStack(); - for (int x=0;x { +/** + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class GroßGetậlŌṁDiamond6ˢᴰ extends GroßGetậlŌṁ6ˢᴰ { // 0th = 1 * V144Tocta (1) // 1th = 1+3 * V144Tocta (4) @@ -17,28 +16,13 @@ public class GroßGetậlŌṁDiamond6ˢᴰ extends AbstractGroßGetậlŌṁ6ˢ super(level); } - public GroßGetậlŌṁDiamond6ˢᴰ(byte level, BaseIteratorOctal values) { - super(level, values); - } - protected int resolveFractalLevel(byte level) { // TODO return level; } @Override - public GroßGetậlŌṁDiamond6ˢᴰ toClone() { - BaseIteratorOctalStack cloneStack = new BaseIteratorOctalStack(); - for (int x=0;x { +/** + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class GroßGetậlŌṁHyperStàr1ⁿᴰ extends GroßGetậlŌṁ1ⁿᴰ { // 0th = V144Tocta // 1th = 5 * V144Tocta @@ -16,25 +15,13 @@ public class GroßGetậlŌṁHyperStàr1ⁿᴰ extends AbstractGroßGetậlŌ super(level); } - public GroßGetậlŌṁHyperStàr1ⁿᴰ(byte level, BaseIteratorOctal values) { - super(level, values); - } - protected int resolveFractalLevel(byte level) { // TODO return level; } - + @Override - public GroßGetậlŌṁHyperStàr1ⁿᴰ toClone() { - BaseIteratorOctalStack cloneStack = new BaseIteratorOctalStack(); - for (int x=0;x { +/** + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class GroßGetậlŌṁHyperStàr6ˢᴰ extends GroßGetậlŌṁ6ˢᴰ { // 0th = V144Tocta // 1th = 5 * V144Tocta @@ -16,28 +15,13 @@ public class GroßGetậlŌṁHyperStàr6ˢᴰ extends AbstractGroßGetậlŌṁ super(level); } - public GroßGetậlŌṁHyperStàr6ˢᴰ(byte level, BaseIteratorOctal values) { - super(level, values); - } - protected int resolveFractalLevel(byte level) { // TODO return level; } @Override - public GroßGetậlŌṁHyperStàr6ˢᴰ toClone() { - BaseIteratorOctalStack cloneStack = new BaseIteratorOctalStack(); - for (int x=0;x { +/** + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class Gê̄ldGetậl { - private final V036Teger value; + private final Gê̄ldGetậlÅtHebrew nummerAlphabet; + private final Gê̄ldGetậlÅtHebrew nummerDeelA; + private final Gê̄ldGetậlÅtHebrew nummerDeelB; + private final Gê̄ldGetậlÅtHebrew nummerDeelC; private final double totalDecimalValue; private static final Character LEFT_TO_RIGHT_MARK = 0x200E; private static final Character RIGHT_TO_LEFT_MARK = 0x200F; - public Gê̄ldGetậl(V036Teger value) { - this.value = value; + public Gê̄ldGetậl(V036Teger teger) { + this( + new Gê̄ldGetậlÅtHebrew(teger.getTytePart(T04PartQuad.PART_1)), + new Gê̄ldGetậlÅtHebrew(teger.getTytePart(T04PartQuad.PART_2)), + new Gê̄ldGetậlÅtHebrew(teger.getTytePart(T04PartQuad.PART_3)), + new Gê̄ldGetậlÅtHebrew(teger.getTytePart(T04PartQuad.PART_4)) + ); + } + + public Gê̄ldGetậl(Gê̄ldGetậlÅtHebrew nummerAlphabet, Gê̄ldGetậlÅtHebrew nummerDeelA, Gê̄ldGetậlÅtHebrew nummerDeelB, Gê̄ldGetậlÅtHebrew nummerDeelC) { + this.nummerAlphabet = nummerAlphabet; + this.nummerDeelA = nummerDeelA; + this.nummerDeelB = nummerDeelB; + this.nummerDeelC = nummerDeelC; this.totalDecimalValue = calculateDecimalValue(); } @@ -85,19 +101,14 @@ public class Gê̄ldGetậl extends AbstractBaseGetậlLevel0 { +/** + * Holds an 25920 bit value. (3240 bytes) + * + * 4 * VCA8Tath red + * 4 * VCA8Tath blue + * + * @author willemtsade ©Δ∞ 仙上主天 + */ +public class KlompGetậl4ˢᴰ implements BaseNumberTyte { + public static int BIT_COUNT = V0x000654ˣᴸ.BIT_COUNT * T08PartOctal.LENGTH(); private final V0x000CA8ˣᴸ[] values = new V0x000CA8ˣᴸ[T08PartOctal.LENGTH()]; public KlompGetậl4ˢᴰ() { @@ -23,22 +33,31 @@ public class KlompGetậl4ˢᴰ extends AbstractBaseGetậlLevel0 getValue(v).fillOctalsByClone(appender)); + } + + @Override + public void fillTytesByReference(BaseAppenderTyte appender) { + T08PartOctal.PART_1.BãßVoorElk(v -> getValue(v).fillTytesByReference(appender)); } } diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/KlompÅtŌṁKāassGetậl4ˢᴰ.java b/numberxd/src/main/love/distributedrebirth/numberxd/KlompÅtŌṁKāassGetậl4ˢᴰ.java index 159c2bd9..710138e9 100644 --- a/numberxd/src/main/love/distributedrebirth/numberxd/KlompÅtŌṁKāassGetậl4ˢᴰ.java +++ b/numberxd/src/main/love/distributedrebirth/numberxd/KlompÅtŌṁKāassGetậl4ˢᴰ.java @@ -1,75 +1,73 @@ package love.distributedrebirth.numberxd; +import love.distributedrebirth.numberxd.base2t.BaseNumberTyte; +import love.distributedrebirth.numberxd.base2t.BaseAppenderOctal; import love.distributedrebirth.numberxd.base2t.BaseIteratorOctal; -import love.distributedrebirth.numberxd.base2t.BaseIteratorOctalStack; -import love.distributedrebirth.numberxd.base2t.part.T08PartOctal; -import love.distributedrebirth.numberxd.base2t.typexl.V0x000CA8ˣᴸ; -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; +import love.distributedrebirth.numberxd.base2t.BaseAppenderTyte; /** * Array of ŌṁKlompGetậl4ˢᴰ sliced as cheese. + * + * @author willemtsade ©Δ∞ 仙上主天 */ -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public class KlompÅtŌṁKāassGetậl4ˢᴰ extends AbstractBaseGetậlLevel1 { +public class KlompÅtŌṁKāassGetậl4ˢᴰ implements BaseNumberTyte { - private final V0x000CA8ˣᴸ[][] kaas; + private KlompGetậl4ˢᴰ[] kaas; private final int kaasCuts; public KlompÅtŌṁKāassGetậl4ˢᴰ(int kaasCuts) { - if (kaasCuts < 2) { - throw new IllegalArgumentException("Can't slice cheese into less than one peace."); - } this.kaasCuts = kaasCuts; - this.kaas = new V0x000CA8ˣᴸ[T08PartOctal.LENGTH()][kaasCuts]; - for (int x=0;x kaasCuts) { + throw new IllegalArgumentException("Requested part exceeds kaasCuts storage"); + } + return part; + } + + public final KlompGetậl4ˢᴰ getValue(int part) { + return kaas[validatePartRequest(part)]; + } + + public final void setValue(int part, KlompGetậl4ˢᴰ value) { + kaas[validatePartRequest(part)] = value; } @Override - public int getValueIndex0Length() { - return T08PartOctal.LENGTH(); - } - - @Override - public int getValueIndex1Length() { - return kaasCuts; - } - - @Override - public KlompÅtŌṁKāassGetậl4ˢᴰ toClone() { - BaseIteratorOctalStack cloneStack = new BaseIteratorOctalStack(); - for (int x=0;x { - - private final V0x049D40ˣᴸ[] values = new V0x049D40ˣᴸ[T04PartQuad.LENGTH()]; - - public WaveGetậl1ᑫᴰ() { - for (int i=0;i { - - private final V0x049D40ˣᴸ value; - - public WaveGetậl1ⁿᴰ() { - value = new V0x049D40ˣᴸ(); - } - - public WaveGetậl1ⁿᴰ(BaseIteratorOctal values) { - value = new V0x049D40ˣᴸ(values); - } - - @Override - public V0x049D40ˣᴸ getValue() { - return value; - } - - @Override - public WaveGetậl1ⁿᴰ toClone() { - return new WaveGetậl1ⁿᴰ(getValue().iteratorOctalsByClone()); - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/Base2Terminator.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/Base2Terminator.java index e990f7a1..d357e70d 100644 --- a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/Base2Terminator.java +++ b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/Base2Terminator.java @@ -37,7 +37,7 @@ public enum Base2Terminator implements BãßBȍőnEnumInstanceʸᴰ octals = Bãß2ReadOctals(v0, v1, v2); - output.add(new V072Tong(new BaseIteratorOctalAdapter(octals.iterator()))); + output.add(new V072Tong(new BaseIteratorOctal(octals.iterator()))); totalBytes += BLOCK_TONG_SIZE; } return totalBytes; @@ -56,7 +56,7 @@ public enum Base2Terminator implements BãßBȍőnEnumInstanceʸᴰ octals = Bãß2ReadOctals(v0, v1, v2, v3, v4, v5); - output.add(new V144Tocta(new BaseIteratorOctalAdapter(octals.iterator()))); + output.add(new V144Tocta(new BaseIteratorOctal(octals.iterator()))); totalBytes += BLOCK_TOCTA_SIZE; } return totalBytes; diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctal.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctal.java index aa6061d6..e6744d50 100644 --- a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctal.java +++ b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctal.java @@ -9,7 +9,21 @@ import love.distributedrebirth.numberxd.base2t.part.T08PartOctal; * Iterator model for Octals. */ @BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public interface BaseIteratorOctal extends Iterator { - -} +public final class BaseIteratorOctal implements Iterator { + private final Iterator iterator; + + public BaseIteratorOctal(Iterator iterator) { + this.iterator = iterator; + } + + @Override + public boolean hasNext() { + return iterator.hasNext(); + } + + @Override + public T08PartOctal next() { + return iterator.next(); + } +} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalAdapter.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalAdapter.java deleted file mode 100644 index bd6e4bd7..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalAdapter.java +++ /dev/null @@ -1,29 +0,0 @@ -package love.distributedrebirth.numberxd.base2t; - -import java.util.Iterator; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.part.T08PartOctal; - -/** - * Iterator model for Octals. - */ -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public final class BaseIteratorOctalAdapter implements BaseIteratorOctal { - - private final Iterator iterator; - - public BaseIteratorOctalAdapter(Iterator iterator) { - this.iterator = iterator; - } - - @Override - public boolean hasNext() { - return iterator.hasNext(); - } - - @Override - public T08PartOctal next() { - return iterator.next(); - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalStack.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalStack.java deleted file mode 100644 index d8205724..00000000 --- a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseIteratorOctalStack.java +++ /dev/null @@ -1,45 +0,0 @@ -package love.distributedrebirth.numberxd.base2t; - -import java.util.Stack; - -import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; -import love.distributedrebirth.numberxd.base2t.part.T08PartOctal; - -/** - * Stack model for octal iterators. - */ -@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") -public final class BaseIteratorOctalStack implements BaseIteratorOctal { - - private final Stack stack = new Stack<>(); - - public BaseIteratorOctalStack() { - } - - public void addIterator(BaseIteratorOctal iterator) { - stack.push(iterator); - } - - @Override - public boolean hasNext() { - if (stack.isEmpty()) { - return false; - } - if (stack.peek().hasNext()) { - return true; - } - stack.pop(); - if (stack.isEmpty()) { - return false; - } - return stack.peek().hasNext(); - } - - @Override - public T08PartOctal next() { - if (stack.isEmpty()) { - throw new IllegalStateException("Stack is empty."); - } - return stack.peek().next(); - } -} diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseNumber.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseNumber.java index f15c2b73..f3647fdf 100644 --- a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseNumber.java +++ b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/BaseNumber.java @@ -27,6 +27,6 @@ public interface BaseNumber> { default BaseIteratorOctal iteratorOctalsByClone() { List octals = new ArrayList<>(); fillOctalsByClone(new BaseAppenderOctal(octals)); - return new BaseIteratorOctalAdapter(octals.iterator()); + return new BaseIteratorOctal(octals.iterator()); } } diff --git a/numberxd/src/main/love/distributedrebirth/numberxd/base2t/typexl/V0x006540ˣᴸ.java b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/typexl/V0x006540ˣᴸ.java new file mode 100644 index 00000000..2925bcaf --- /dev/null +++ b/numberxd/src/main/love/distributedrebirth/numberxd/base2t/typexl/V0x006540ˣᴸ.java @@ -0,0 +1,58 @@ +package love.distributedrebirth.numberxd.base2t.typexl; + +import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ; +import love.distributedrebirth.numberxd.base2t.BaseAppenderOctal; +import love.distributedrebirth.numberxd.base2t.BaseAppenderTyte; +import love.distributedrebirth.numberxd.base2t.BaseIteratorOctal; +import love.distributedrebirth.numberxd.base2t.BaseNumberTyteXL; +import love.distributedrebirth.numberxd.base2t.part.T08PartOctal; + +/** + * Holds an 25920 bit value. (3240 bytes) + */ +@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天") +public class V0x006540ˣᴸ implements BaseNumberTyteXL { + + public static int BIT_COUNT = V0x000CA8ˣᴸ.BIT_COUNT * T08PartOctal.LENGTH(); + private V0x000CA8ˣᴸ[] values = new V0x000CA8ˣᴸ[T08PartOctal.LENGTH()]; + + public V0x006540ˣᴸ() { + for (int i=0;i getValue(v).fillOctalsByClone(appender)); + } + + @Override + public void fillTytesByReference(BaseAppenderTyte appender) { + T08PartOctal.PART_1.BãßVoorElk(v -> getValue(v).fillTytesByReference(appender)); + } +}