Just to answer my own question for everyone, it looks to me like the answer is "no". It seems like the code I'm interested in is SlingScriptAdapterFactory, and it doesn't currently look for any sort of property along those lines. Since I've never worked directly on Sling code before (I'm just a user of the code), I'm not sure how involved a patch would be to handle the kind of situation I'm thinking about. It would probably also involve changes to DefaultSlingScript and possibly other classes. I'll forget about this for now.
--David -----Original Message----- From: Levine, David [mailto:lev...@consumer.org] Sent: Friday, May 20, 2011 12:18 PM To: users@sling.apache.org Subject: BindingsValuesProvider I have a BindingsValuesProvider class to add my own objects. I'm using the @scr.property name="javax.script.name" annotation to restrict it to being called only for a specific scripting language. It works great. I've also found no problem in having two BindingsValuesProviders for the same language (both get executed). But is there a way to also restrict the bindings to a specific URL prefix? I'd like to have one provider bind certain objects to scripts run in one subtree in my site, and the other provider bind other objects to scripts run in another subtree. Thanks, --David ** This e-mail message is intended only for the designated recipient(s) named above. The information contained in this e-mail and any attachments may be confidential or legally privileged. If you are not the intended recipient, you may not review, retain, copy, redistribute or use this e-mail or any attachment for any purpose, or disclose all or any part of its contents. If you have received this e-mail in error, please immediately notify the sender by reply e-mail and permanently delete this e-mail and any attachments from your computer system.