|
What this is
Other links
The source code/* * Sun Public License Notice * * The contents of this file are subject to the Sun Public License * Version 1.0 (the "License"). You may not use this file except in * compliance with the License. A copy of the License is available at * http://www.sun.com/ * * The Original Code is NetBeans. The Initial Developer of the Original * Code is Sun Microsystems, Inc. Portions Copyright 1997-2002 Sun * Microsystems, Inc. All Rights Reserved. */ package org.netbeans.modules.javacore.jmiimpl.javamodel; import java.util.Arrays; import java.util.List; import org.netbeans.jmi.javamodel.Constructor; import org.netbeans.jmi.javamodel.ConstructorClass; import org.netbeans.jmi.javamodel.JavaDoc; import org.netbeans.jmi.javamodel.StatementBlock; import org.netbeans.mdr.storagemodel.StorableClass; import org.netbeans.modules.javacore.parser.TypeParamRef; /** * Implementation of Constructor class proxy interface. * * @author Martin Matula, Vladimir Hudec */ public abstract class ConstructorClassImpl extends SemiPersistentClass implements ConstructorClass { protected ConstructorClassImpl(StorableClass s) { super(s); } /** * The default factory operation used to create an instance object. * @return The created instance object. */ public Constructor createConstructor() { return create(null, 0, null, null, null, null, null, null, null); } public Constructor createConstructor(java.lang.String name, List annotations, int modifiers, java.lang.String javadocText, JavaDoc javadoc, StatementBlock body, java.lang.String bodyText, List typeArguments, List parameters, List exceptionNames) { return create(annotations, modifiers, javadocText, javadoc, body, bodyText, typeArguments, parameters, exceptionNames); } private Constructor create(List annotations, int modifiers, java.lang.String javadocText, JavaDoc javadoc, StatementBlock body, java.lang.String bodyText, List typeArguments, List parameters, List exceptionNames) { ConstructorImpl result = create(modifiers, null, false); result.setNew(); result.setData(annotations, javadocText, javadoc, body, bodyText, typeArguments, parameters, exceptionNames); return result; } public ConstructorImpl create(int modifiers, TypeParamRef[] exceptions, boolean isTransient) { ConstructorImpl result; if (isTransient) { result = (ConstructorImpl) createTransient(); boolean changes = result.disableChanges; result.disableChanges = true; try { result.setModifiers(modifiers); } finally { result.disableChanges = changes; } } else { result = (ConstructorImpl) super_createConstructor(null, null, modifiers, null, null, null, null, null, null, null); } result.setExceptionRefs(exceptions == null ? null : Arrays.asList(exceptions)); return result; } protected abstract Constructor super_createConstructor(); protected abstract Constructor super_createConstructor(java.lang.String name, List annotations, int modifiers, java.lang.String javadocText, JavaDoc javadoc, StatementBlock body, java.lang.String bodyText, List typeArguments, List parameters, List exceptionNames); } |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.