Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

oracle.ide.model
Class SingletonProvider

java.lang.Object
  extended by oracle.ide.model.SingletonProvider

public class SingletonProvider
extends java.lang.Object


Method Summary
static
<T> T
find(java.lang.Class<T> target)
          Locates a suitable implementation for a target Class.
static
<T> T
findIfAvailable(java.lang.Class<T> target)
          Locates a suitable implementation for a target Class if the singleton instance of that class has already been created.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

find

public static <T> T find(java.lang.Class<T> target)
Locates a suitable implementation for a target Class.

May trigger initialization of an extension if the implementation is found on an extension that has not been initialized yet.

Parameters:
target - an interface or class that identifies the base type to look for.
Returns:
an instance that implements the target interface or extends the target class. May return null if no suitable implementation is found.

findIfAvailable

public static <T> T findIfAvailable(java.lang.Class<T> target)
Locates a suitable implementation for a target Class if the singleton instance of that class has already been created. If an instance of the target class does not already exist null will be returned.

Parameters:
target - an interface or class that identifies the base type to look for.
Returns:
an instance that implements the target interface or extends the target class. May return null if no existing instance is found.

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

Copyright © 1997, 2011, Oracle. All rights reserved.