Class ThreadSafeAnalysis


public class ThreadSafeAnalysis extends Object
Analyzes types for deep thread safety.
  • Constructor Details

  • Method Details

    • checkInvocation

      public ThreadSafety.Violation checkInvocation( methodType, symbol)
    • checkForThreadSafety

      public ThreadSafety.Violation checkForThreadSafety(Optional<com.sun.source.tree.ClassTree> tree,<String> threadSafeTypeParams, type)
      Check that an @ThreadSafe-annotated class:
      • does not declare or inherit any fields which are not thread safe,
      • any threadsafe supertypes are instantiated with threadsafe type arguments as required by their containerOf spec, and
      • any enclosing instances are threadsafe.
      requiring supertypes to be annotated threadsafe would be too restrictive.
    • threadSafeTypeParametersInScope

      public<String> threadSafeTypeParametersInScope( sym)