Class Contexts.WrapContext

  • All Implemented Interfaces:
    Context, Wrapper
    Enclosing class:
    Contexts

    private static class Contexts.WrapContext
    extends java.lang.Object
    implements Context
    Context that wraps an object.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) java.lang.Object target  
    • Constructor Summary

      Constructors 
      Constructor Description
      WrapContext​(java.lang.Object target)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      <T> T unwrap​(java.lang.Class<T> clazz)
      Finds an instance of an interface implemented by this object, or returns null if this object does not support that interface.
      • Methods inherited from class java.lang.Object

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

      • target

        final java.lang.Object target
    • Constructor Detail

      • WrapContext

        WrapContext​(java.lang.Object target)
    • Method Detail

      • unwrap

        public <T> T unwrap​(java.lang.Class<T> clazz)
        Description copied from interface: Wrapper
        Finds an instance of an interface implemented by this object, or returns null if this object does not support that interface.
        Specified by:
        unwrap in interface Wrapper