public class ImportListImpl extends Object implements ImportList
Constructor and Description |
---|
ImportListImpl() |
Modifier and Type | Method and Description |
---|---|
Type |
addImport(String name)
Add a fully-qualified type name to the imports.
|
void |
addImport(Type type) |
boolean |
contains(String name)
Return whether or not this Type is in the imports.
|
boolean |
contains(Type type) |
ImportList |
copy()
Return a copy of this ImportList.
|
List<Pair<String,String>> |
getInOrderList()
Return a list of imports as (packageName,className) pairs.
|
Type |
lookup(String className)
Lookup just the className, without package name.
|
public ImportList copy()
ImportList
copy
in interface ImportList
public Type addImport(String name)
addImport
in interface ImportList
public void addImport(Type type)
addImport
in interface ImportList
public boolean contains(String name)
contains
in interface ImportList
public boolean contains(Type type)
contains
in interface ImportList
public Type lookup(String className)
lookup
in interface ImportList
public List<Pair<String,String>> getInOrderList()
getInOrderList
in interface ImportList
Copyright © 2017 Oracle. All rights reserved.