"\u203c";
n.my_bonk = new Bonk();
n.my_bonk.type = 31337;
n.my_bonk.message = "I am a bonk... xor!";
HolyMoley hm = new HolyMoley();
hm.big = new ArrayList<OneOfEach>();
hm.contain = new HashSet<List<String>>();
hm.bonks = new HashMap<String,List<Bonk>>();
hm.big.add((OneOfEach)deepCopy(ooe));
hm.big.add((OneOfEach)deepCopy(n.my_ooe));
hm.big.get(0).a_bite = 0x22;
hm.big.get(1).a_bite = 0x33;
List<String> stage1 = new ArrayList<String>();
stage1.add("and a one");
stage1.add("and a two");
hm.contain.add(stage1);
stage1 = new ArrayList<String>();
stage1.add("then a one, two");
stage1.add("three!");
stage1.add("FOUR!!");
hm.contain.add(stage1);
stage1 = new ArrayList<String>();
hm.contain.add(stage1);
List<Bonk> stage2 = new ArrayList<Bonk>();
hm.bonks.put("nothing", stage2);
stage2.add(new Bonk());
stage2.get(0).type = 1;
stage2.get(0).message = "Wait.";
stage2.add(new Bonk());
stage2.get(1).type = 2;
stage2.get(1).message = "What?";
hm.bonks.put("something", stage2);
stage2 = new ArrayList<Bonk>();
stage2.add(new Bonk());
stage2.get(0).type = 3;
stage2.get(0).message = "quoth";
stage2.add(new Bonk());
stage2.get(1).type = 4;
stage2.get(1).message = "the raven";
stage2.add(new Bonk());
stage2.get(2).type = 5;
stage2.get(2).message = "nevermore";
hm.bonks.put("poe", stage2);
OneOfEach ooe2 = new OneOfEach();
binaryDeserializer.deserialize(
ooe2,
binarySerializer.serialize(ooe));
if (!ooe.equals(ooe2)) {
throw new RuntimeException("Failure: ooe (equals)");
}
if (ooe.hashCode() != ooe2.hashCode()) {
throw new RuntimeException("Failure: ooe (hash)");
}
Nesting n2 = new Nesting();
binaryDeserializer.deserialize(
n2,
binarySerializer.serialize(n));
if (!n.equals(n2)) {
throw new RuntimeException("Failure: n (equals)");
}
if (n.hashCode() != n2.hashCode()) {
throw new RuntimeException("Failure: n (hash)");
}
HolyMoley hm2 = new HolyMoley();
binaryDeserializer.deserialize(
hm2,
binarySerializer.serialize(hm));
if (!hm.equals(hm2)) {
throw new RuntimeException("Failure: hm (equals)");
}
if (hm.hashCode() != hm2.hashCode()) {
throw new RuntimeException("Failure: hm (hash)");
}
}