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

How to use
ServiceResources
in
org.apache.tapestry5.ioc

Best Java code snippets using org.apache.tapestry5.ioc.ServiceResources (Showing top 20 results out of 315)

origin: org.apache.tapestry/tapestry-ioc

public AbstractMethodInvokingInstrumenter(ModuleBuilderSource moduleSource, Method method,
                     ServiceResources resources, PlasticProxyFactory proxyFactory)
{
  this.moduleSource = moduleSource;
  this.method = method;
  this.resources = resources;
  this.proxyFactory = proxyFactory;
  serviceId = resources.getServiceId();
  resourcesDefaults.put(String.class, serviceId);
  resourcesDefaults.put(ObjectLocator.class, resources);
  resourcesDefaults.put(ServiceResources.class, resources);
  logger = resources.getLogger();
  resourcesDefaults.put(Logger.class, logger);
  serviceInterface = resources.getServiceInterface();
  resourcesDefaults.put(Class.class, serviceInterface);
  resourcesDefaults.put(OperationTracker.class, resources.getTracker());
}
origin: apache/tapestry-5

  public Pingable buildPingable(ServiceResources resources)
  {
    return resources.autobuild(UnbuildablePingable.class);
  }
}
origin: org.apache.tapestry/tapestry-ioc

private Object createProxy(ServiceResources resources, ObjectCreator creator, boolean preventDecoration)
{
  String serviceId = resources.getServiceId();
  Class serviceInterface = resources.getServiceInterface();
  String toString = format("<Proxy for %s(%s)>", serviceId, serviceInterface.getName());
  ServiceProxyToken token = SerializationSupport.createToken(serviceId);
  final Class serviceImplementation = preventDecoration || serviceInterface == TypeCoercer.class ? null : resources.getServiceImplementation();
  return createProxyInstance(creator, token, serviceInterface, serviceImplementation, toString);
}
origin: net.sourceforge.tapestrytestify/tapestry-testify

  @SuppressWarnings("unchecked")
  public Object createService(ServiceResources resources, ObjectCreator creator) {
    ObjectCreator perTestCreator = new PerTestServiceCreator(perTestManager, creator);
    Class<?> serviceInterface = resources.getServiceInterface();
    

    String toString = format("<PerTest Proxy for %s(%s)>", resources.getServiceId(), serviceInterface.getName());
    return proxyFactory.createProxy(serviceInterface, perTestCreator, toString);
  }
}
origin: org.apache.tapestry/tapestry-ioc

resourceMap.put(Logger.class, resources.getLogger());
        resources.getServiceId(), t, parameterType), injectionResources);
      injectionResources, resources.getTracker());
origin: apache/tapestry-5

@Override
public String getServiceId()
{
  return resources.getServiceId();
}
origin: apache/tapestry-5

          OrderedConfiguration configuration)
final OperationTracker tracker = resources.getTracker();
final ApplicationContext context = resources.getService(SERVICE_ID,
    ApplicationContext.class);
origin: org.apache.tapestry/tapestry-ioc

protected final void train_getTracker(ServiceResources resources, OperationTracker tracker)
{
  expect(resources.getTracker()).andReturn(tracker).atLeastOnce();
}
origin: apache/tapestry-5

protected final void train_getServiceInterface(ServiceResources resources, Class serviceInterface)
{
  expect(resources.getServiceInterface()).andReturn(serviceInterface).atLeastOnce();
}
origin: org.apache.tapestry/tapestry-ioc

protected final void train_getLogger(ServiceResources resources, Logger log)
{
  expect(resources.getLogger()).andReturn(log).atLeastOnce();
}
origin: org.apache.tapestry/tapestry-ioc

  @Override
  public Object createService(ServiceResources resources, ObjectCreator creator)
  {
    ObjectCreator perThreadCreator = perthreadManager.createValue(creator);

    Class serviceInterface = resources.getServiceInterface();

    return proxyFactory.createProxy(serviceInterface, perThreadCreator, "<PerThread Proxy for " + resources.getServiceId() + "(" + serviceInterface.getName() + ")>");
  }
}
origin: apache/tapestry-5

resourceMap.put(Logger.class, resources.getLogger());
        resources.getServiceId(), t, parameterType), injectionResources);
      injectionResources, resources.getTracker());
origin: apache/tapestry-5

public ToStringService buildToString(ServiceResources resources)
{
  final String serviceId = resources.getServiceId();
  return new ToStringService()
  {
    @Override
    public String toString()
    {
      return "<ToStringService: " + serviceId + ">";
    }
  };
}
origin: org.apache.tapestry/tapestry-spring

          OrderedConfiguration configuration)
final OperationTracker tracker = resources.getTracker();
final ApplicationContext context = resources.getService(SERVICE_ID,
    ApplicationContext.class);
origin: apache/tapestry-5

protected final void train_getTracker(ServiceResources resources, OperationTracker tracker)
{
  expect(resources.getTracker()).andReturn(tracker).atLeastOnce();
}
origin: org.apache.tapestry/tapestry-ioc

protected final void train_getServiceInterface(ServiceResources resources, Class serviceInterface)
{
  expect(resources.getServiceInterface()).andReturn(serviceInterface).atLeastOnce();
}
origin: apache/tapestry-5

protected final void train_getLogger(ServiceResources resources, Logger log)
{
  expect(resources.getLogger()).andReturn(log).atLeastOnce();
}
origin: apache/tapestry-5

public AbstractMethodInvokingInstrumenter(ModuleBuilderSource moduleSource, Method method,
                     ServiceResources resources, PlasticProxyFactory proxyFactory)
{
  this.moduleSource = moduleSource;
  this.method = method;
  this.resources = resources;
  this.proxyFactory = proxyFactory;
  serviceId = resources.getServiceId();
  resourcesDefaults.put(String.class, serviceId);
  resourcesDefaults.put(ObjectLocator.class, resources);
  resourcesDefaults.put(ServiceResources.class, resources);
  logger = resources.getLogger();
  resourcesDefaults.put(Logger.class, logger);
  serviceInterface = resources.getServiceInterface();
  resourcesDefaults.put(Class.class, serviceInterface);
  resourcesDefaults.put(OperationTracker.class, resources.getTracker());
}
origin: apache/tapestry-5

  @Override
  public Object createService(ServiceResources resources, ObjectCreator creator)
  {
    ObjectCreator perThreadCreator = perthreadManager.createValue(creator);

    Class serviceInterface = resources.getServiceInterface();

    return proxyFactory.createProxy(serviceInterface, perThreadCreator, "<PerThread Proxy for " + resources.getServiceId() + "(" + serviceInterface.getName() + ")>");
  }
}
origin: apache/tapestry-5

private Object createProxy(ServiceResources resources, ObjectCreator creator, boolean preventDecoration)
{
  String serviceId = resources.getServiceId();
  Class serviceInterface = resources.getServiceInterface();
  String toString = format("<Proxy for %s(%s)>", serviceId, serviceInterface.getName());
  ServiceProxyToken token = SerializationSupport.createToken(serviceId);
  final Class serviceImplementation = preventDecoration || serviceInterface == TypeCoercer.class ? null : resources.getServiceImplementation();
  return createProxyInstance(creator, token, serviceInterface, serviceImplementation, toString);
}
org.apache.tapestry5.iocServiceResources

Javadoc

Contains resources that may be provided to a service when it initializes, which includes other services defined in the registry. ServiceResources provides access to other services (it extends org.apache.tapestry5.ioc.ObjectLocator).

Most used methods

  • getServiceId
    Returns the fully qualified id of the service.
  • getServiceInterface
    Returns the service interface implemented by the service.
  • getTracker
    Returns an object that can be used to track operations related to constructing, configuring, decorat
  • autobuild
  • getLogger
    Returns a Logger appropriate for logging messages. This includes debug level messages about the crea
  • getService
  • getServiceImplementation
    Returns the service implementation.

Popular in Java

  • Creating JSON documents from java classes using gson
  • getExternalFilesDir (Context)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • findViewById (Activity)
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
  • Reference (javax.naming)
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Top plugins for WebStorm
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