Tabnine Logo
StupidResourceHolder
Code IndexAdd Tabnine to your IDE (free)

How to use
StupidResourceHolder
in
org.apache.druid.collections

Best Java code snippets using org.apache.druid.collections.StupidResourceHolder (Showing top 7 results out of 315)

origin: apache/incubator-druid

 @Test
 public void testCreateAndGet()
 {
  String expected = "String";
  resourceHolder = StupidResourceHolder.create(expected);
  String actual = resourceHolder.get();
  Assert.assertEquals(expected, actual);
  resourceHolder.close();
 }
}
origin: apache/incubator-druid

public static <T> StupidResourceHolder<T> create(T obj)
{
 return new StupidResourceHolder<>(obj);
}
origin: apache/incubator-druid

@Before
public void setUp()
{
 cache = new MemcachedCache(
   Suppliers.ofInstance(
     StupidResourceHolder.create(new MockMemcachedClient())
   ),
   memcachedCacheConfig,
   NOOP_MONITOR
 );
}
origin: apache/incubator-druid

} else {
 clientSupplier = Suppliers.ofInstance(
   StupidResourceHolder.create(new MemcachedClient(connectionFactory, hosts))
 );
origin: apache/incubator-druid

  StupidResourceHolder.create(client)
),
new MemcachedCacheConfig()
origin: org.apache.druid/druid-common

public static <T> StupidResourceHolder<T> create(T obj)
{
 return new StupidResourceHolder<>(obj);
}
origin: org.apache.druid/druid-server

} else {
 clientSupplier = Suppliers.ofInstance(
   StupidResourceHolder.create(new MemcachedClient(connectionFactory, hosts))
 );
org.apache.druid.collectionsStupidResourceHolder

Most used methods

  • create
  • <init>
  • close
  • get

Popular in Java

  • Running tasks concurrently on multiple threads
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • setContentView (Activity)
  • getSharedPreferences (Context)
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now