MCPcopy Create free account
hub / github.com/careercup/ctci / main

Method main

java/Chapter 17/Question17_10/QuestionOO.java:44–59  ·  view source on GitHub ↗
(String args[])

Source from the content-addressed store, hash-verified

42 }
43
44 public static void main(String args[]) {
45 Element root = new Element("family");
46 Attribute a1 = new Attribute("lastName", "0");
47 Attribute a2 = new Attribute("state", "CA");
48 root.insert(a1);
49 root.insert(a2);
50
51 Element child = new Element("person", "Some Message");
52 Attribute a3 = new Attribute("firstName", "Gayle");
53 child.insert(a3);
54
55 root.insert(child);
56
57 String s = encodeToString(root);
58 System.out.println(s);
59 }
60}

Callers

nothing calls this directly

Calls 2

insertMethod · 0.95
encodeToStringMethod · 0.95

Tested by

no test coverage detected