Package org.codehaus.groovy.runtime.callsite

# Class MetaClassCallSites

java.lang.Object
org.codehaus.groovy.runtime.callsite.MetaClassCallSites

public final class MetaClassCallSites extends Object
Builds classic (non-indy) call sites for a `MetaClassImpl`.

Logic formerly lived as `create*CallSite` methods on `MetaClassImpl` / `ExpandoMetaClass` / `ClosureMetaClass`. It uses only public MetaClass APIs so this class can live with the rest of the classic call-site runtime without a split-package on `groovy.lang`.

Prefer invokedynamic call sites for new code. Planned for deprecation/removal in a future Groovy version.

Since:
  6.0.0

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static CallSite`
  `createConstructorSite(MetaClassImpl metaClass, CallSite site, Object[] args)`
  Creates a constructor call site for the given metaclass.
  `static CallSite`
  `createPogoCallCurrentSite(MetaClassImpl metaClass, CallSite site, Class sender, Object[] args)`
  Creates a current-scope POGO call site for the given metaclass.
  `static CallSite`
  `createPogoCallSite(MetaClassImpl metaClass, CallSite site, Object[] args)`
  Creates a POGO call site for the given metaclass.
  `static CallSite`
  `createPojoCallSite(MetaClassImpl metaClass, CallSite site, Object receiver, Object[] args)`
  Creates a POJO call site for the given metaclass.
  `static CallSite`
  `createStaticSite(MetaClassImpl metaClass, CallSite site, Object[] args)`
  Creates a static call site for the given metaclass.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### createPojoCallSite

    public static CallSite createPojoCallSite(MetaClassImpl metaClass, CallSite site, Object receiver, Object[] args)
    Creates a POJO call site for the given metaclass.

  - ### createStaticSite

    public static CallSite createStaticSite(MetaClassImpl metaClass, CallSite site, Object[] args)
    Creates a static call site for the given metaclass.

  - ### createPogoCallSite

    public static CallSite createPogoCallSite(MetaClassImpl metaClass, CallSite site, Object[] args)
    Creates a POGO call site for the given metaclass.

  - ### createPogoCallCurrentSite

    public static CallSite createPogoCallCurrentSite(MetaClassImpl metaClass, CallSite site, Class sender, Object[] args)
    Creates a current-scope POGO call site for the given metaclass.

  - ### createConstructorSite

    public static CallSite createConstructorSite(MetaClassImpl metaClass, CallSite site, Object[] args)
    Creates a constructor call site for the given metaclass.