@Override public org.restlet.Application getApplication() { return wrappedRestlet.getApplication(); }
@Override public Application getApplication() { return wrappedRestlet.getApplication(); }
/** * Creates a new finder instance based on the "targetClass" property. If * none is define, the {@link Application#createFinder(Class)} method is * invoked if available, otherwise the * {@link org.restlet.resource.Finder#createFinder(Class, Class, Context, Logger)} * method is called with the {@link org.restlet.resource.Finder} class as * parameter. * * @param resourceClass * The target {@link org.restlet.resource.ServerResource} class * to find. * @return The new finder instance. * @see org.restlet.resource.Finder#createFinder(Class, Class, Context, * Logger) */ public org.restlet.resource.Finder createFinder( Class<? extends org.restlet.resource.ServerResource> resourceClass) { org.restlet.resource.Finder result = null; if (getFinderClass() != null) { result = org.restlet.resource.Finder.createFinder(resourceClass, getFinderClass(), getContext(), getLogger()); } else if ((getApplication() != null) && (getApplication() != this)) { result = getApplication().createFinder(resourceClass); } else { result = org.restlet.resource.Finder.createFinder(resourceClass, org.restlet.resource.Finder.class, getContext(), getLogger()); } return result; }
/** * Returns the metadata service. If the parent application doesn't exist, a * new instance is created. * * @return The metadata service. */ public MetadataService getMetadataService() { MetadataService result = null; if (getHelped() != null) { org.restlet.Application application = getHelped().getApplication(); if (application != null) { result = application.getMetadataService(); } } if (result == null) { result = new MetadataService(); } return result; }