Interface BaseContext

All Superinterfaces:
AutoCloseable, BaseLoader, BaseProvider, io.github.mmm.code.api.CodeContext, io.github.mmm.code.api.CodeLoader, io.github.mmm.code.api.node.CodeNode, io.github.mmm.code.api.CodeProvider, io.github.mmm.code.api.CodeWithContext
All Known Implementing Classes:
AbstractBaseContext, AbstractBaseContextWithCache, BaseContextChild

public interface BaseContext extends io.github.mmm.code.api.CodeContext, BaseProvider
Base interface for CodeContext.
Since:
1.0.0
Author:
Joerg Hohwiller (hohwille at users.sourceforge.net)
  • Method Details

    • getParent

      BaseContext getParent()
      Specified by:
      getParent in interface io.github.mmm.code.api.CodeContext
      Specified by:
      getParent in interface io.github.mmm.code.api.node.CodeNode
    • getRootContext

      default BaseContext getRootContext()
      Returns:
      the root context responsible for the fundamental code (from the SDK like JDK for Java).
    • getSource

      BaseSource getSource(String id)
      Parameters:
      id - the ID of the requested source.
      Returns:
      the existing BaseSource for the given ID or null if not found.
    • getRootType

      BaseType getRootType()
      Specified by:
      getRootType in interface io.github.mmm.code.api.CodeContext
    • getRootEnumerationType

      BaseType getRootEnumerationType()
      Specified by:
      getRootEnumerationType in interface io.github.mmm.code.api.CodeContext
    • getVoidType

      BaseType getVoidType()
      Specified by:
      getVoidType in interface io.github.mmm.code.api.CodeContext
    • getRootExceptionType

      BaseType getRootExceptionType()
      Specified by:
      getRootExceptionType in interface io.github.mmm.code.api.CodeContext
    • getBooleanType

      BaseType getBooleanType(boolean primitive)
      Specified by:
      getBooleanType in interface io.github.mmm.code.api.CodeContext
    • getUnboundedWildcard

      BaseTypeWildcard getUnboundedWildcard()
      Specified by:
      getUnboundedWildcard in interface io.github.mmm.code.api.CodeContext
    • getType

      BaseGenericType getType(Type type, io.github.mmm.code.api.element.CodeElementWithDeclaringType declaringElement)
      Parameters:
      type - the Type to get as CodeGenericType.
      declaringElement - the owning CodeElementWithDeclaringType declaring the Type.
      Returns:
      the existing or otherwise newly created CodeGenericType.
    • getNonPrimitiveType

      BaseType getNonPrimitiveType(BaseType javaType)
      Parameters:
      javaType - the BaseType that might be primitive.
      Returns:
      the corresponding non-primitive type.
    • getFactory

      BaseFactory getFactory()
      Specified by:
      getFactory in interface io.github.mmm.code.api.CodeContext
    • getOrCreateType

      default BaseType getOrCreateType(String qualifiedName, boolean add)
      Specified by:
      getOrCreateType in interface io.github.mmm.code.api.CodeContext
    • createChildContext

      BaseContext createChildContext()
      Specified by:
      createChildContext in interface io.github.mmm.code.api.CodeContext