1 package org.opendaylight.controller.sal.restconf.impl.test;
3 import static org.junit.Assert.assertEquals;
4 import static org.junit.Assert.assertFalse;
5 import static org.junit.Assert.assertNotNull;
6 import static org.junit.Assert.assertNull;
7 import static org.junit.Assert.assertTrue;
12 import org.junit.Test;
13 import org.opendaylight.controller.sal.restconf.impl.test.structures.*;
14 import org.opendaylight.yangtools.yang.data.api.*;
15 import org.opendaylight.yangtools.yang.data.impl.NodeFactory;
17 import com.google.gson.stream.*;
19 public class ToJsonBasicYangTypesTest {
22 * Test of json output when as input are specified composite node with empty
26 public void compositeNodeAndYangWithJsonReaderEmptyDataTest() {
27 String jsonOutput = TestUtils.convertCompositeNodeDataAndYangToJson(prepareCompositeNodeWithEmpties(),
28 "/yang-to-json-conversion/simple-yang-types", "/yang-to-json-conversion/simple-yang-types/xml");
29 verifyJsonOutputForEmpty(jsonOutput);
33 * Test of json output when as input are specified xml file (no empty
34 * elements)and YANG file
37 public void xmlAndYangTypesWithJsonReaderTest() {
38 String jsonOutput = TestUtils.convertCompositeNodeDataAndYangToJson(
39 TestUtils.loadCompositeNode("/yang-to-json-conversion/simple-yang-types/xml/data.xml"),
40 "/yang-to-json-conversion/simple-yang-types", "/yang-to-json-conversion/simple-yang-types/xml");
41 verifyJsonOutput(jsonOutput);
44 private void verifyJsonOutputForEmpty(String jsonOutput) {
45 StringReader strReader = new StringReader(jsonOutput);
46 JsonReader jReader = new JsonReader(strReader);
48 String exception = null;
49 Cont dataFromJson = null;
51 dataFromJson = jsonReadCont1(jReader);
52 } catch (IOException e) {
53 exception = e.getMessage();
56 assertNotNull("Data structures from json are missing.", dataFromJson);
57 checkDataFromJsonEmpty(dataFromJson);
59 assertNull("Error during reading Json output: " + exception, exception);
62 private void verifyJsonOutput(String jsonOutput) {
63 StringReader strReader = new StringReader(jsonOutput);
64 JsonReader jReader = new JsonReader(strReader);
66 String exception = null;
67 Cont dataFromJson = null;
69 dataFromJson = jsonReadCont1(jReader);
70 } catch (IOException e) {
71 exception = e.getMessage();
74 assertNotNull("Data structures from json are missing.", dataFromJson);
75 checkDataFromJson(dataFromJson);
77 assertNull("Error during reading Json output: " + exception, exception);
80 private Cont jsonReadCont1(JsonReader jReader) throws IOException {
81 jReader.beginObject();
82 assertNotNull("cont1 is missing.", jReader.hasNext());
84 Cont dataFromJson = new Cont(jReader.nextName());
85 dataFromJson = jsonReadCont1Elements(jReader, dataFromJson);
87 assertFalse("cont shouldn't have other element.", jReader.hasNext());
93 private Cont jsonReadCont1Elements(JsonReader jReader, Cont redData) throws IOException {
94 jReader.beginObject();
95 while (jReader.hasNext()) {
96 String keyName = jReader.nextName();
97 if (keyName.equals("lf11")) {
98 redData.addLf(new Lf(keyName, nextValue(jReader)));
99 } else if (keyName.equals("lflst11")) {
100 LfLst lfLst = new LfLst(keyName);
101 lfLst = jsonReadLflstValues(jReader, lfLst);
102 redData.addLfLst(lfLst);
103 } else if (keyName.equals("lflst12")) {
104 LfLst lfLst = new LfLst(keyName);
105 jsonReadLflstValues(jReader, lfLst);
106 redData.addLfLst(lfLst);
107 } else if (keyName.equals("lst11")) {
108 Lst lst = new Lst(keyName);
109 lst = jsonReadLst11(jReader, lst);
112 assertTrue("Key " + keyName + " doesn't exists in yang file.", false);
120 private Lst jsonReadLst11(JsonReader jReader, Lst lst) throws IOException {
121 jReader.beginArray();
123 while (jReader.hasNext()) {
124 LstItem lstItem = jsonReadLst11Elements(jReader);
125 lst.addLstItem(lstItem);
131 private LstItem jsonReadLst11Elements(JsonReader jReader) throws IOException {
132 LstItem lstItem = new LstItem();
133 jReader.beginObject();
134 while (jReader.hasNext()) {
135 String keyName = jReader.nextName();
136 if (keyName.equals("lf111")) {
137 lstItem.addLf(new Lf(keyName, nextValue(jReader)));
138 } else if (keyName.equals("lf112")) {
139 lstItem.addLf(new Lf(keyName, nextValue(jReader)));
140 } else if (keyName.equals("cont111")) {
141 Cont cont = new Cont(keyName);
142 cont = jsonReadCont111(jReader, cont);
143 lstItem.addCont(cont);
144 } else if (keyName.equals("lst111")) {
145 Lst lst = new Lst(keyName);
146 lst = jsonReadLst111(jReader, lst);
148 } else if (keyName.equals("lst112")) {
149 Lst lst = new Lst(keyName);
150 lst = jsonReadLst112(jReader, lst);
153 assertTrue("Key " + keyName + " doesn't exists in yang file.", false);
160 private Lst jsonReadLst112(JsonReader jReader, Lst lst) throws IOException {
161 jReader.beginArray();
162 while (jReader.hasNext()) {
163 LstItem lstItem = jsonReadLst112Elements(jReader);
164 lst.addLstItem(lstItem);
170 private LstItem jsonReadLst112Elements(JsonReader jReader) throws IOException {
171 LstItem lstItem = new LstItem();
172 jReader.beginObject();
173 if (jReader.hasNext()) {
174 String keyName = jReader.nextName();
175 if (keyName.equals("lf1121")) {
176 lstItem.addLf(new Lf(keyName, nextValue(jReader)));
184 private Lst jsonReadLst111(JsonReader jReader, Lst lst) throws IOException {
185 jReader.beginArray();
186 while (jReader.hasNext()) {
187 LstItem lstItem = jsonReadLst111Elements(jReader);
188 lst.addLstItem(lstItem);
194 private LstItem jsonReadLst111Elements(JsonReader jReader) throws IOException {
195 LstItem lstItem = new LstItem();
196 jReader.beginObject();
197 if (jReader.hasNext()) {
198 String keyName = jReader.nextName();
199 if (keyName.equals("lf1111")) {
200 lstItem.addLf(new Lf(keyName, nextValue(jReader)));
207 private String nextValue(JsonReader jReader) throws IOException {
208 if (jReader.peek().equals(JsonToken.NULL)) {
212 return jReader.nextString();
216 private Cont jsonReadCont111(JsonReader jReader, Cont cont) throws IOException {
217 jReader.beginObject();
218 cont = jsonReadCont111Elements(jReader, cont);
223 private Cont jsonReadCont111Elements(JsonReader jReader, Cont cont) throws IOException {
224 while (jReader.hasNext()) {
225 String keyName = jReader.nextName();
226 if (keyName.equals("lf1111")) {
227 cont.addLf(new Lf(keyName, nextValue(jReader)));
228 } else if (keyName.equals("lflst1111")) {
229 LfLst lfLst = new LfLst(keyName);
230 lfLst = jsonReadLflstValues(jReader, lfLst);
231 cont.addLfLst(lfLst);
232 } else if (keyName.equals("lst1111")) {
233 Lst lst = new Lst(keyName);
234 lst = jsonReadLst1111(jReader, lst);
237 assertTrue("Key " + keyName + " doesn't exists in yang file.", false);
244 private Lst jsonReadLst1111(JsonReader jReader, Lst lst) throws IOException {
245 jReader.beginArray();
246 while (jReader.hasNext()) {
247 LstItem lstItem = jsonReadLst1111Elements(jReader);
248 lst.addLstItem(lstItem);
254 private LstItem jsonReadLst1111Elements(JsonReader jReader) throws IOException {
255 jReader.beginObject();
256 LstItem lstItem = new LstItem();
257 while (jReader.hasNext()) {
258 String keyName = jReader.nextName();
259 if (keyName.equals("lf1111A") || keyName.equals("lf1111B")) {
260 lstItem.addLf(new Lf(keyName, nextValue(jReader)));
267 private LfLst jsonReadLflstValues(JsonReader jReader, LfLst lfLst) throws IOException {
268 jReader.beginArray();
269 while (jReader.hasNext()) {
270 lfLst.addLf(new Lf(nextValue(jReader)));
276 private void checkDataFromJsonEmpty(Cont dataFromJson) {
277 assertTrue(dataFromJson.getLfs().isEmpty());
278 assertTrue(dataFromJson.getLfLsts().isEmpty());
279 assertTrue(dataFromJson.getConts().isEmpty());
281 Map<String, Lst> lsts = dataFromJson.getLsts();
282 assertEquals(1, lsts.size());
283 Lst lst11 = lsts.get("lst11");
284 assertNotNull(lst11);
285 Set<LstItem> lstItems = lst11.getLstItems();
286 assertNotNull(lstItems);
288 LstItem lst11_1 = null;
289 LstItem lst11_2 = null;
290 LstItem lst11_3 = null;
291 for (LstItem lstItem : lstItems) {
292 if (lstItem.getLfs().get("lf111").getValue().equals("1")) {
294 } else if (lstItem.getLfs().get("lf111").getValue().equals("2")) {
296 } else if (lstItem.getLfs().get("lf111").getValue().equals("3")) {
301 assertNotNull(lst11_1);
302 assertNotNull(lst11_2);
303 assertNotNull(lst11_3);
306 assertTrue(lst11_1.getLfLsts().isEmpty());
307 assertEquals(1, lst11_1.getLfs().size());
308 assertEquals(1, lst11_1.getConts().size());
309 assertEquals(1, lst11_1.getLsts().size());
310 assertEquals(lst11_1.getLsts().get("lst111"), new Lst("lst111").addLstItem(new LstItem().addLf("lf1111", "35"))
311 .addLstItem(new LstItem().addLf("lf1111", "34")).addLstItem(new LstItem()).addLstItem(new LstItem()));
312 assertEquals(lst11_1.getConts().get("cont111"), new Cont("cont111"));
316 assertTrue(lst11_2.getLfLsts().isEmpty());
317 assertEquals(1, lst11_2.getLfs().size());
318 assertEquals(1, lst11_2.getConts().size());
319 assertEquals(1, lst11_2.getLsts().size());
321 Cont lst11_2_cont111 = lst11_2.getConts().get("cont111");
324 assertNotNull(lst11_2_cont111);
325 assertTrue(lst11_2_cont111.getLfs().isEmpty());
326 assertEquals(1, lst11_2_cont111.getLfLsts().size());
327 assertEquals(1, lst11_2_cont111.getLsts().size());
328 assertTrue(lst11_2_cont111.getConts().isEmpty());
330 assertEquals(new LfLst("lflst1111").addLf("1024").addLf("4096"), lst11_2_cont111.getLfLsts().get("lflst1111"));
332 new Lst("lst1111").addLstItem(new LstItem().addLf("lf1111B", "4")).addLstItem(
333 new LstItem().addLf("lf1111A", "lf1111A str12")), lst11_2_cont111.getLsts().get("lst1111"));
335 assertEquals(lst11_2.getLsts().get("lst112"), new Lst("lst112").addLstItem(new LstItem()));
339 assertEquals(1, lst11_3.getLfs().size());
340 assertTrue(lst11_3.getLfLsts().isEmpty());
341 assertTrue(lst11_3.getLsts().isEmpty());
342 assertTrue(lst11_3.getLsts().isEmpty());
345 Cont lst11_3_cont111 = lst11_3.getConts().get("cont111");
346 assertEquals(0, lst11_3_cont111.getLfs().size());
347 assertEquals(0, lst11_3_cont111.getLfLsts().size());
348 assertEquals(1, lst11_3_cont111.getLsts().size());
349 assertTrue(lst11_3_cont111.getConts().isEmpty());
351 assertEquals(new Lst("lst1111").addLstItem(new LstItem()).addLstItem(new LstItem()), lst11_3_cont111.getLsts()
358 private void checkDataFromJson(Cont dataFromJson) {
359 assertNotNull(dataFromJson.getLfs().get("lf11"));
360 assertEquals(dataFromJson.getLfs().get("lf11"), new Lf("lf11", "lf"));
362 LfLst lflst11 = null;
363 LfLst lflst12 = null;
365 lflst11 = dataFromJson.getLfLsts().get("lflst11");
366 lflst12 = dataFromJson.getLfLsts().get("lflst12");
368 assertNotNull(lflst11);
369 assertNotNull(lflst12);
371 assertEquals(3, lflst11.getLfs().size());
372 assertTrue(lflst11.getLfs().contains(new Lf("55")));
373 assertTrue(lflst11.getLfs().contains(new Lf("56")));
374 assertTrue(lflst11.getLfs().contains(new Lf("57")));
376 assertEquals(3, lflst12.getLfs().size());
377 assertTrue(lflst12.getLfs().contains(new Lf("lflst12 str1")));
378 assertTrue(lflst12.getLfs().contains(new Lf("lflst12 str2")));
379 assertTrue(lflst12.getLfs().contains(new Lf("lflst12 str3")));
381 assertEquals(1, dataFromJson.getLsts().size());
382 Lst lst11 = dataFromJson.getLsts().get("lst11");
383 assertNotNull(lst11);
384 assertEquals(2, lst11.getLstItems().size());
386 LstItem lst11_1 = null;
387 LstItem lst11_2 = null;
388 for (LstItem lstItem : lst11.getLstItems()) {
389 Lf lf = lstItem.getLfs().get("lf111");
390 if (lf != null && lf.getValue().equals("140")) {
392 } else if (lf != null && lf.getValue().equals("141")) {
397 checkLst11_1(lst11_1);
398 checkLst11_2(lst11_2);
401 private void checkLst11_2(LstItem lst11_2) {
402 assertNotNull(lst11_2);
403 assertEquals(2, lst11_2.getLfs().size());
404 assertEquals(1, lst11_2.getConts().size());
405 assertEquals(2, lst11_2.getLsts().size());
407 assertEquals(lst11_2.getLfs().get("lf112"), new Lf("lf112", "lf112 str2"));
409 Cont lst11_2_cont = lst11_2.getConts().get("cont111");
410 assertEquals(0, lst11_2_cont.getConts().size());
411 assertEquals(1, lst11_2_cont.getLfLsts().size());
412 assertEquals(1, lst11_2_cont.getLfs().size());
413 assertEquals(1, lst11_2_cont.getLsts().size());
416 assertEquals(new Lf("lf1111", "lf1111 str2"), lst11_2_cont.getLfs().get("lf1111"));
417 assertEquals(new LfLst("lflst1111").addLf(new Lf("2049")).addLf(new Lf("1025")).addLf(new Lf("4097")),
418 lst11_2_cont.getLfLsts().get("lflst1111"));
420 assertNotNull(lst11_2_cont.getLsts().get("lst1111"));
421 checkLst1111(lst11_2_cont.getLsts().get("lst1111").getLstItems(), new Lf("lf1111A", "lf1111A str21"), new Lf(
422 "lf1111B", "5"), new Lf("lf1111A", "lf1111A str22"), new Lf("lf1111B", "8"));
424 checkLst11x(lst11_2.getLsts().get("lst111"), new LstItem().addLf(new Lf("lf1111", "55")),
425 new LstItem().addLf(new Lf("lf1111", "56")));
426 checkLst11x(lst11_2.getLsts().get("lst112"), new LstItem().addLf(new Lf("lf1121", "lf1121 str22")),
427 new LstItem().addLf(new Lf("lf1121", "lf1121 str21")));
430 private void checkLst11_1(LstItem lst11_1) {
431 assertNotNull(lst11_1);
433 assertEquals(2, lst11_1.getLfs().size());
434 assertEquals(1, lst11_1.getConts().size());
435 assertEquals(2, lst11_1.getLsts().size());
437 assertEquals(lst11_1.getLfs().get("lf112"), new Lf("lf112", "lf112 str"));
439 Cont lst11_1_cont = lst11_1.getConts().get("cont111");
440 assertEquals(0, lst11_1_cont.getConts().size());
441 assertEquals(1, lst11_1_cont.getLfLsts().size());
442 assertEquals(1, lst11_1_cont.getLfs().size());
443 assertEquals(1, lst11_1_cont.getLsts().size());
446 assertEquals(new Lf("lf1111", "lf1111 str"), lst11_1_cont.getLfs().get("lf1111"));
447 assertEquals(new LfLst("lflst1111").addLf(new Lf("2048")).addLf(new Lf("1024")).addLf(new Lf("4096")),
448 lst11_1_cont.getLfLsts().get("lflst1111"));
450 assertNotNull(lst11_1_cont.getLsts().get("lst1111"));
451 checkLst1111(lst11_1_cont.getLsts().get("lst1111").getLstItems(), new Lf("lf1111A", "lf1111A str11"), new Lf(
452 "lf1111B", "4"), new Lf("lf1111A", "lf1111A str12"), new Lf("lf1111B", "7"));
454 checkLst11x(lst11_1.getLsts().get("lst111"), new LstItem().addLf(new Lf("lf1111", "65")));
455 checkLst11x(lst11_1.getLsts().get("lst112"), new LstItem().addLf(new Lf("lf1121", "lf1121 str11")));
458 private void checkLst11x(Lst lst, LstItem... lstItems) {
461 Lst requiredLst = new Lst(lst.getName());
462 for (LstItem lstItem : lstItems) {
463 requiredLst.addLstItem(lstItem);
466 assertEquals(requiredLst, lst);
470 private void checkLst1111(Set<LstItem> lstItems, Lf lf11, Lf lf12, Lf lf21, Lf lf22) {
471 LstItem lst11_1_cont_lst1111_1 = null;
472 LstItem lst11_1_cont_lst1111_2 = null;
473 for (LstItem lstItem : lstItems) {
474 if (new LstItem().addLf(lf11).addLf(lf12).equals(lstItem)) {
475 lst11_1_cont_lst1111_1 = lstItem;
476 } else if (new LstItem().addLf(lf21).addLf(lf22).equals(lstItem)) {
477 lst11_1_cont_lst1111_2 = lstItem;
481 assertNotNull(lst11_1_cont_lst1111_1);
482 assertNotNull(lst11_1_cont_lst1111_2);
485 private CompositeNode prepareCompositeNodeWithEmpties() {
486 MutableCompositeNode cont1 = NodeFactory.createMutableCompositeNode(
487 TestUtils.buildQName("cont1", "simple:yang:types", "2013-11-5"), null, null, ModifyAction.CREATE, null);
490 MutableCompositeNode lst11_1 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst11"), cont1,
491 null, ModifyAction.CREATE, null);
492 cont1.getChildren().add(lst11_1);
494 MutableSimpleNode<?> lf111_1 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf111"), lst11_1, "1",
495 ModifyAction.CREATE, null);
496 lst11_1.getChildren().add(lf111_1);
499 MutableCompositeNode lst111_1_1 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst111"),
500 lst11_1, null, ModifyAction.CREATE, null);
501 lst11_1.getChildren().add(lst111_1_1);
502 MutableSimpleNode<?> lf1111_1_1 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf1111"),
503 lst111_1_1, "34", ModifyAction.CREATE, null);
504 lst111_1_1.getChildren().add(lf1111_1_1);
509 MutableCompositeNode lst111_1_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst111"),
510 lst11_1, null, ModifyAction.CREATE, null);
511 lst11_1.getChildren().add(lst111_1_2);
512 MutableSimpleNode<?> lf1111_1_2 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf1111"),
513 lst111_1_2, "35", ModifyAction.CREATE, null);
514 lst111_1_2.getChildren().add(lf1111_1_2);
519 MutableCompositeNode lst111_1_3 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst111"),
520 lst11_1, null, ModifyAction.CREATE, null);
521 lst11_1.getChildren().add(lst111_1_3);
526 MutableCompositeNode lst111_1_4 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst111"),
527 lst11_1, null, ModifyAction.CREATE, null);
528 lst11_1.getChildren().add(lst111_1_4);
532 MutableCompositeNode cont111_1 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("cont111"),
533 lst11_1, null, ModifyAction.CREATE, null);
534 lst11_1.getChildren().add(cont111_1);
540 MutableCompositeNode lst11_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst11"), cont1,
541 null, ModifyAction.CREATE, null);
542 cont1.getChildren().add(lst11_2);
544 MutableSimpleNode<?> lf111_2 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf111"), lst11_2, "2",
545 ModifyAction.CREATE, null);
546 lst11_2.getChildren().add(lf111_2);
549 MutableCompositeNode cont111_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("cont111"),
550 lst11_2, null, ModifyAction.CREATE, null);
551 lst11_2.getChildren().add(cont111_2);
553 MutableSimpleNode<?> lflst1111_2_2 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lflst1111"),
554 cont111_2, "1024", ModifyAction.CREATE, null);
555 cont111_2.getChildren().add(lflst1111_2_2);
556 MutableSimpleNode<?> lflst1111_2_3 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lflst1111"),
557 cont111_2, "4096", ModifyAction.CREATE, null);
558 cont111_2.getChildren().add(lflst1111_2_3);
561 MutableCompositeNode lst1111_2_1 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst1111"),
562 cont111_2, null, ModifyAction.CREATE, null);
563 cont111_2.getChildren().add(lst1111_2_1);
564 MutableSimpleNode<?> lf1111B_2_1 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf1111B"),
565 lst1111_2_1, "4", ModifyAction.CREATE, null);
566 lst1111_2_1.getChildren().add(lf1111B_2_1);
569 MutableCompositeNode lst1111_2_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst1111"),
570 cont111_2, null, ModifyAction.CREATE, null);
571 cont111_2.getChildren().add(lst1111_2_2);
572 MutableSimpleNode<?> lf1111B_2_2 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf1111A"),
573 lst1111_2_2, "lf1111A str12", ModifyAction.CREATE, null);
574 lst1111_2_2.getChildren().add(lf1111B_2_2);
581 MutableCompositeNode lst112_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst112"), lst11_2,
582 null, ModifyAction.CREATE, null);
583 lst11_2.getChildren().add(lst112_2);
590 MutableCompositeNode lst11_3 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst11"), cont1,
591 null, ModifyAction.CREATE, null);
592 cont1.getChildren().add(lst11_3);
594 MutableSimpleNode<?> lf111_3 = NodeFactory.createMutableSimpleNode(TestUtils.buildQName("lf111"), lst11_3, "3",
595 ModifyAction.CREATE, null);
596 lst11_3.getChildren().add(lf111_3);
599 MutableCompositeNode cont111_3 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("cont111"),
600 lst11_3, null, ModifyAction.CREATE, null);
601 lst11_3.getChildren().add(cont111_3);
603 MutableCompositeNode lst1111_3_1 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst1111"),
604 cont111_3, null, ModifyAction.CREATE, null);
605 cont111_3.getChildren().add(lst1111_3_1);
608 MutableCompositeNode lst1111_3_2 = NodeFactory.createMutableCompositeNode(TestUtils.buildQName("lst1111"),
609 cont111_3, null, ModifyAction.CREATE, null);
610 cont111_3.getChildren().add(lst1111_3_2);