Top Description Methods
com.github.javaparser.ast.nodeTypes

public Interface NodeWithImplements<N extends Node>

Known Direct Implementers
com.github.javaparser.ast.body.ClassOrInterfaceDeclaration, com.github.javaparser.ast.body.EnumDeclaration
Imports
com.github.javaparser.ast.Node, .NodeList, com.github.javaparser.ast.type.ClassOrInterfaceType

A node that implements other types.

Method Summary

Modifier and TypeMethod and Description
public default N
public default N

Returns:

this
addImplementedType
(String
the name of the type to extends from
name
)

Add an implements to this

public default N

Returns:

this
addImplementedType
(Class<?>
the type to implements from
clazz
)

Add an implements to this and automatically add the import

public default N
addImplements(String name)

Deprecated use addImplementedType instead
public default N
addImplements(Class<?> clazz)

Deprecated use addImplementedType instead
public NodeList<ClassOrInterfaceType>
public default ClassOrInterfaceType
public default N
public N
public void

Method Detail

addImplementedTypeback to summary
public default N addImplementedType(ClassOrInterfaceType implement)
Annotations
@SuppressWarnings:unchecked
addImplementedTypeback to summary
public default N addImplementedType(String name)

Add an implements to this

Parameters
name:String

the name of the type to extends from

Returns:N

this

Annotations
@SuppressWarnings:unchecked
addImplementedTypeback to summary
public default N addImplementedType(Class<?> clazz)

Add an implements to this and automatically add the import

Parameters
clazz:Class<?>

the type to implements from

Returns:N

this

addImplementsback to summary
public default N addImplements(String name)

Deprecated

use addImplementedType instead

addImplementsback to summary
public default N addImplements(Class<?> clazz)

Deprecated

use addImplementedType instead

getImplementedTypesback to summary
public NodeList<ClassOrInterfaceType> getImplementedTypes()
getImplementedTypesback to summary
public default ClassOrInterfaceType getImplementedTypes(int i)
setImplementedTypeback to summary
public default N setImplementedType(int i, ClassOrInterfaceType implement)
Annotations
@SuppressWarnings:unchecked
setImplementedTypesback to summary
public N setImplementedTypes(NodeList<ClassOrInterfaceType> implementsList)
tryAddImportToParentCompilationUnitback to summary
public void tryAddImportToParentCompilationUnit(Class<?> clazz)