private Book getBook() {
        Book book = new Book(new DocumentId("id:book:book::0"));
        book.setAuthor("Herman Melville");
        book.setTitle("Moby Dick - Or The Whale");
        book.setIsbn("234-33");
        book.setYear(1815).
          setDescription("A great novel about whaling.");

        Ss1 ss1 = new Book.Ss1();
        Ss0 ss0 = new Book.Ss0();
        ss0.setD0(-238472634.78);
        ss1.setS1("test s1").
          setI1(999).
          setD1(56.777).
          setSs01(ss0);
        book.setMystruct(ss1);

        List<Integer> myArrInt = new ArrayList<>();
        myArrInt.add(10);
        myArrInt.add(20);
        myArrInt.add(30);
        book.setMyarrayint(myArrInt);

        List<Integer> intL = new ArrayList<>(){{add(1);add(2);add(3);}};
        List<Integer> intL2 = new ArrayList<>(){{add(9);add(10);add(11);}};
        List<List<Integer>> doubleIntL = new ArrayList<>();
        doubleIntL.add(intL);
        doubleIntL.add(intL2);
        List<List<List<Integer>>> tripleIntL = new ArrayList<>();
        tripleIntL.add(doubleIntL);
        book.setMytriplearray(tripleIntL);

        Map<String, String> sMap = new HashMap<>();
        sMap.put("Melville", "Moby Dick");
        sMap.put("Bulgakov", "The Master and Margarita");
        sMap.put("Black Debbath", "Tung tung politisk rock");
        book.setStringmap(sMap);

        Map<Integer, Ss1> structMap = new HashMap<>();
        structMap.put(50, ss1);
        structMap.put(60, ss1);
        book.setStructmap(structMap);

        Map<Integer, Integer> ws = new HashMap<>();
        ws.put(1, 100);
        ws.put(2, 200);
        ws.put(3, 300);
        book.setMywsinteger(ws);

        Ss1 arrayedStruct1 = new Ss1().setS1("YEPS").setI1(789);
        Ss1 arrayedStruct2 = new Ss1().setS1("JA").setI1(456);
        List<Ss1> structArray = new ArrayList<>();
        structArray.add(arrayedStruct1);
        structArray.add(arrayedStruct2);
        book.setMysinglestructarray(structArray);
        book.setContent(ByteBuffer.allocate(3).put(new byte[]{3,4,5}));
        book.getContent().position(0);
        return book;
    }
Packs the given doc to Book
@param d doc, never null
@return a Book object or null if input doc isn't a Book
documentgen-test/src/test/java/com/yahoo/vespa/config/DocumentGenPluginTest.java