Class WhitelistConstructor

java.lang.Object
org.opensearch.painless.spi.WhitelistConstructor

public final class WhitelistConstructor
extends java.lang.Object
Constructor represents the equivalent of a Java constructor available as a whitelisted class constructor within Painless. Constructors for Painless classes may be accessed exactly as constructors for Java classes are using the 'new' keyword. Painless classes may have multiple constructors as long as they comply with arity overloading described for WhitelistClass.
  • Field Summary

    Fields 
    Modifier and Type Field Description
    java.util.List<java.lang.String> canonicalTypeNameParameters
    A List of Strings that are the Painless type names for the parameters of the constructor which can be used to look up the Java constructor through reflection.
    java.lang.String origin
    Information about where this constructor was whitelisted from.
    java.util.Map<java.lang.Class<?>,​java.lang.Object> painlessAnnotations
    The Map of annotations for this constructor.
  • Constructor Summary

    Constructors 
    Constructor Description
    WhitelistConstructor​(java.lang.String origin, java.util.List<java.lang.String> canonicalTypeNameParameters, java.util.List<java.lang.Object> painlessAnnotations)
    Standard constructor.
  • Method Summary

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • origin

      public final java.lang.String origin
      Information about where this constructor was whitelisted from.
    • canonicalTypeNameParameters

      public final java.util.List<java.lang.String> canonicalTypeNameParameters
      A List of Strings that are the Painless type names for the parameters of the constructor which can be used to look up the Java constructor through reflection.
    • painlessAnnotations

      public final java.util.Map<java.lang.Class<?>,​java.lang.Object> painlessAnnotations
      The Map of annotations for this constructor.
  • Constructor Details

    • WhitelistConstructor

      public WhitelistConstructor​(java.lang.String origin, java.util.List<java.lang.String> canonicalTypeNameParameters, java.util.List<java.lang.Object> painlessAnnotations)
      Standard constructor. All values must be not null.