APIdia Launch Partner
Top Description Inners Fields Constructors Methods
jdk.javadoc.internal.doclets.toolkit

public Class WorkArounds

extends Object
Class Inheritance
Imports
java.util.Arrays, .HashMap, .List, .Map, .SortedSet, .TreeSet, java.util.stream.Collectors, javax.lang.model.element.AnnotationMirror, .Element, .ExecutableElement, .ModuleElement, .PackageElement, .TypeElement, .VariableElement, javax.lang.model.type.TypeMirror, javax.lang.model.util.Elements, .Types, javax.tools.FileObject, .JavaFileManager.Location, com.sun.source.util.TreePath, com.sun.tools.javac.code.Flags, .Symbol, .Symbol.ClassSymbol, .Symbol.MethodSymbol, .Symbol.ModuleSymbol, .Symbol.PackageSymbol, .Symbol.VarSymbol, com.sun.tools.javac.util.Names, .Options, jdk.javadoc.internal.doclets.toolkit.util.Utils, jdk.javadoc.internal.tool.ToolEnvironment, .DocEnvImpl

A quarantine class to isolate all the workarounds and bridges to a locality. This class should eventually disappear once all the standard APIs support the needed interfaces.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
public final BaseConfiguration
public final Elements
public final Types
private final Map<TypeElement, WorkArounds.NewSerializedForm>
public final ToolEnvironment
public final Types
public final Utils

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public boolean

Returns:

true if access is permitted to internal API
accessInternalAPI
()

Returns whether or not to permit dynamically loaded components to access part of the javadoc internal API.

public boolean
public Map<Element, TreePath>
pack-priv FileObject
public JavaFileManager.Location
public SortedSet<VariableElement>
public SortedSet<ExecutableElement>
private WorkArounds.NewSerializedForm
public boolean
public static boolean
public boolean
public boolean
public boolean
public boolean
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

configurationback to summary
public final BaseConfiguration configuration
elementUtilsback to summary
public final Elements elementUtils
javacTypesback to summary
public final Types javacTypes
serializedFormsback to summary
private final Map<TypeElement, WorkArounds.NewSerializedForm> serializedForms
toolEnvback to summary
public final ToolEnvironment toolEnv
typeUtilsback to summary
public final Types typeUtils
utilsback to summary
public final Utils utils

Constructor Detail

WorkAroundsback to summary
public WorkArounds(BaseConfiguration configuration)

Method Detail

accessInternalAPIback to summary
public boolean accessInternalAPI()

Returns whether or not to permit dynamically loaded components to access part of the javadoc internal API. The flag is the same (hidden) compiler option that allows javac plugins and annotation processors to access javac internal API. As with all workarounds, it is better to consider updating the public API, rather than relying on undocumented features like this, that may be withdrawn at any time, without notice.

Returns:boolean

true if access is permitted to internal API

definesSerializableFieldsback to summary
public boolean definesSerializableFields(TypeElement typeElem)
getElementToTreePathback to summary
public Map<Element, TreePath> getElementToTreePath()
getJavaFileObjectback to summary
pack-priv FileObject getJavaFileObject(PackageElement packageElement)
getLocationForModuleback to summary
public JavaFileManager.Location getLocationForModule(ModuleElement mdle)
getSerializableFieldsback to summary
public SortedSet<VariableElement> getSerializableFields(TypeElement typeElem)
getSerializationMethodsback to summary
public SortedSet<ExecutableElement> getSerializationMethods(TypeElement typeElem)
getSerializedFormback to summary
private WorkArounds.NewSerializedForm getSerializedForm(TypeElement typeElem)
isDeprecated0back to summary
public boolean isDeprecated0(Element e)
isImplicitlyDeclaredClassback to summary
public static boolean isImplicitlyDeclaredClass(Element e)
isMandatedback to summary
public boolean isMandated(AnnotationMirror aDesc)
isPreviewAPIback to summary
public boolean isPreviewAPI(Element el)
isReflectivePreviewAPIback to summary
public boolean isReflectivePreviewAPI(Element el)
isRestrictedAPIback to summary
public boolean isRestrictedAPI(Element el)
jdk.javadoc.internal.doclets.toolkit back to summary

pack-priv Class WorkArounds.NewSerializedForm

extends Object
Class Inheritance
  • java.lang.Object
  • jdk.javadoc.internal.doclets.toolkit.WorkArounds.NewSerializedForm

Field Summary

Modifier and TypeField and Description
pack-priv boolean
pack-priv final Elements
pack-priv final SortedSet<VariableElement>
pack-priv final SortedSet<ExecutableElement>
private static final String
private static final String
private static final String
private static final String
pack-priv final Utils
private static final String
private static final String

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
private void
private void
public ExecutableElement

Returns:

the first MethodDocImpl which matches, null if not found.
findMethod
(TypeElement te, String
the unqualified name to search for.
methodName
,
List<String>
the array of Strings for method parameter types.
paramTypes
)

Find a method in this class scope.

private Symbol.VarSymbol
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

definesSerializableFieldsback to summary
pack-priv boolean definesSerializableFields
elementsback to summary
pack-priv final Elements elements
fieldsback to summary
pack-priv final SortedSet<VariableElement> fields
methodsback to summary
pack-priv final SortedSet<ExecutableElement> methods
READOBJECTback to summary
private static final String READOBJECT
READOBJECTNODATAback to summary
private static final String READOBJECTNODATA
READRESOLVEback to summary
private static final String READRESOLVE
SERIALIZABLE_FIELDSback to summary
private static final String SERIALIZABLE_FIELDS
utilsback to summary
pack-priv final Utils utils
WRITEOBJECTback to summary
private static final String WRITEOBJECT
WRITEREPLACEback to summary
private static final String WRITEREPLACE

Constructor Detail

NewSerializedFormback to summary
pack-priv NewSerializedForm(Utils utils, Elements elements, TypeElement te)

Method Detail

addMethodIfExistback to summary
private void addMethodIfExist(Symbol.ClassSymbol def, String methodName)
computeDefaultSerializableFieldsback to summary
private void computeDefaultSerializableFields(Symbol.ClassSymbol te)
findMethodback to summary
public ExecutableElement findMethod(TypeElement te, String methodName, List<String> paramTypes)

Find a method in this class scope. Search order: this class, interfaces, superclasses, outerclasses. Note that this is not necessarily what the compiler would do!

Parameters
methodName:String

the unqualified name to search for.

paramTypes:List<String>

the array of Strings for method parameter types.

Returns:ExecutableElement

the first MethodDocImpl which matches, null if not found.

getDefinedSerializableFieldsback to summary
private Symbol.VarSymbol getDefinedSerializableFields(Symbol.ClassSymbol def)