< prev index next >

src/jdk.xml.bind/share/classes/com/sun/codemodel/internal/package-info.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 33,61 **** * <p> * With CodeModel, you build the java source code by first building AST, * then writing it out as text files that is Java source files. * The AST looks like this: * - * {@DotDiagram - digraph G { - cls1 [label="JDefinedClass"]; - cls2 [label="JDefinedClass"]; - JCodeModel -> cls1 [label="generated class"]; - JCodeModel -> cls2 [label="generated class"]; - - m1 [label="JMethod"]; - m2 [label="JMethod"]; - - cls1 -> m1; - cls1 -> m2; - cls1 -> JField; - - m1 -> JVar [label="method parameter"]; - m1 -> JBlock [label="code"]; - } - * } - * * <p> * You bulid this tree mostly from top-down. So, you first create * a new {@link JDefinedClass} from {@link JCodeModel}, then you * create a {@link JMethod} from {@link JDefinedClass}, and so on. * --- 33,42 ----
*** 105,115 **** * Compared to template-based code generator, the writing operation * is slow, as it needs to traverse each AST node. Consider * pre-encoding tokens (like 'public') to the target encoding, * and consider exploting the subtree equivalence. * - * @ArchitectureDocument */ package com.sun.codemodel.internal; import java.util.List; import java.util.Map; --- 86,95 ----
< prev index next >