Tabnine Logo
JDefinedClass.isAnonymous
Code IndexAdd Tabnine to your IDE (free)

How to use
isAnonymous
method
in
com.sun.codemodel.JDefinedClass

Best Java code snippets using com.sun.codemodel.JDefinedClass.isAnonymous (Showing top 6 results out of 315)

origin: com.unquietcode.tools.jcodemodel/codemodel

if (!isAnonymous()) {
  f.nl();
origin: com.sun.codemodel/codemodel

public void generate(JFormatter f) {
  if (isConstructor && type.isArray()) {
    // [RESULT] new T[]{arg1,arg2,arg3,...};
    f.p("new").g(type).p('{');
  } else {
    if (isConstructor)
      f.p("new").g(type).p('(');
    else {
      String name = this.name;
      if(name==null)  name=this.method.name();
      if (object != null)
        f.g(object).p('.').p(name).p('(');
      else
        f.id(name).p('(');
    }
  }
      
  f.g(args);
  if (isConstructor && type.isArray())
    f.p('}');
  else 
    f.p(')');
    
  if( type instanceof JDefinedClass && ((JDefinedClass)type).isAnonymous() ) {
    ((JAnonymousClass)type).declareBody(f);
  }
}
origin: org.glassfish.metro/webservices-tools

public void generate(JFormatter f) {
  if (isConstructor && type.isArray()) {
    // [RESULT] new T[]{arg1,arg2,arg3,...};
    f.p("new").g(type).p('{');
  } else {
    if (isConstructor)
      f.p("new").g(type).p('(');
    else {
      String name = this.name;
      if(name==null)  name=this.method.name();
      if (object != null)
        f.g(object).p('.').p(name).p('(');
      else
        f.id(name).p('(');
    }
  }
      
  f.g(args);
  if (isConstructor && type.isArray())
    f.p('}');
  else 
    f.p(')');
    
  if( type instanceof JDefinedClass && ((JDefinedClass)type).isAnonymous() ) {
    ((JAnonymousClass)type).declareBody(f);
  }
}
origin: javaee/jaxb-v2

public void generate(JFormatter f) {
  if (isConstructor && type.isArray()) {
    // [RESULT] new T[]{arg1,arg2,arg3,...};
    f.p("new").g(type).p('{');
  } else {
    if (isConstructor)
      f.p("new").g(type).p('(');
    else {
      String name = this.name;
      if(name==null)  name=this.method.name();
      if (object != null)
        f.g(object).p('.').p(name).p('(');
      else
        f.id(name).p('(');
    }
  }
      
  f.g(args);
  if (isConstructor && type.isArray())
    f.p('}');
  else 
    f.p(')');
    
  if( type instanceof JDefinedClass && ((JDefinedClass)type).isAnonymous() ) {
    ((JAnonymousClass)type).declareBody(f);
  }
}
origin: sun-jaxb/jaxb-xjc

public void generate(JFormatter f) {
  if (isConstructor && type.isArray()) {
    // [RESULT] new T[]{arg1,arg2,arg3,...};
    f.p("new").g(type).p('{');
  } else {
    if (isConstructor)
      f.p("new").g(type).p('(');
    else {
      String name = this.name;
      if(name==null)  name=this.method.name();
      if (object != null)
        f.g(object).p('.').p(name).p('(');
      else
        f.id(name).p('(');
    }
  }
      
  f.g(args);
  if (isConstructor && type.isArray())
    f.p('}');
  else 
    f.p(')');
    
  if( type instanceof JDefinedClass && ((JDefinedClass)type).isAnonymous() ) {
    ((JAnonymousClass)type).declareBody(f);
  }
}
origin: com.unquietcode.tools.jcodemodel/codemodel

public void generate(JFormatter f) {
  if (isConstructor && type.isArray()) {
    // [RESULT] new T[]{arg1,arg2,arg3,...};
    f.p("new").g(type).p('{');
  } else {
    if (isConstructor)
      f.p("new").g(type).p('(');
    else {
      String name = this.name;
      if(name==null)  name=this.method.name();
      if (object != null)
        f.g(object).p('.').p(name).p('(');
      else
        f.id(name).p('(');
    }
  }
      
  f.g(args);
  if (isConstructor && type.isArray())
    f.p('}');
  else 
    f.p(')');
    
  if( type instanceof JDefinedClass && ((JDefinedClass)type).isAnonymous() ) {
    ((JAnonymousClass)type).declareBody(f);
  }
}
com.sun.codemodelJDefinedClassisAnonymous

Javadoc

Returns true if this is an anonymous class.

Popular methods of JDefinedClass

  • method
  • _extends
  • field
  • _implements
  • name
    JClass name accessor. For example, for java.util.List, this method returns "List""
  • constructor
    Adds a constructor to this class.
  • fields
    Returns all the fields declred in this class. The returned Map is a read-only live view.
  • annotate
    Adding ability to annotate a class
  • fullName
    Gets the fully qualified name of this class.
  • methods
  • owner
  • javadoc
    Creates, if necessary, and returns the class javadoc for this JDefinedClass
  • owner,
  • javadoc,
  • _class,
  • getMethod,
  • _package,
  • dotclass,
  • enumConstant,
  • staticInvoke,
  • staticRef,
  • init

Popular in Java

  • Parsing JSON documents to java classes using gson
  • getExternalFilesDir (Context)
  • getContentResolver (Context)
  • setContentView (Activity)
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • JComboBox (javax.swing)
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now